[Maxima] How do I obtain an object's properties?

Barton Willis willisb at unk.edu
Wed Sep 9 18:49:55 CDT 2009


Does ratp do what you want?

(%i2) (modulus:97, a:rat(2), b:2)$

(%i5) map('ratp,[a,b,a^10,b^10]);
(%o5) [true,false,true,false]

Barton

-----maxima-bounces at math.utexas.edu wrote: -----

>To: maxima list <maxima at math.utexas.edu>
>From: Alasdair McAndrew <amca01 at gmail.com>
>Sent by: maxima-bounces at math.utexas.edu
>Date: 09/09/2009 06:41PM
>Subject: [Maxima] How do I obtain an object's properties?
>
>For example:
>
>(%i1) modulus:97;
>(\%o1)                     97
>(%i2) a:rat(2);
>(\%o2)                       2
>(%i3) b:2;
>(\%o3)                       2
>(%i4) a^10;
>(\%o4)                    -43
>(%i5) b^10;
>(\%o5)                 1024
>
>Here a and b are clearly different types of objects, even though they
>look the same.  How can Maxima tell me their properties - and is there
>a way to have those properties automatically shown?
>
>Thanks,
>Alasdair
>_______________________________________________
>Maxima mailing list
>Maxima at math.utexas.edu
>http://www.math.utexas.edu/mailman/listinfo/maxima




More information about the Maxima mailing list