"Mike Hansen" <[EMAIL PROTECTED]> writes:

[...]

| When trying to construct an object corresponding to 'Polynomial
| Fraction Integer' in Sage, you first want to construct the argument in
| Sage, and then make the polynomial ring over that.  Currently, I'm
| just doing some simple string processing to extract the argument.  It
| seems that all the data need to reconstruct a domain within FriCAS is
| present in its string representation; is this generally true?

In all AXIOM-based systems, the arguments used to instantiate a domain
are part of the domain object; you just need a function to access
them.  In OpenAxiom, you use reify the domain object (a vector) into
a ConstructorCall and ask for the arguments.

| 
| > In Aldor, Polynomial would be just any function, i.e., a first class object.
| > In FriCAS it's not, and it's on top of my whishlist to change that.
| > Unfortunately, I have no idea how to do it.
| >
| > Again, do you have a use case?  Maybe there is a workaround.
| 
| It'd be nice to be able to test given a random type if the "outermost"
| constructor is Polynomial.  I'm just doing string stuff to work around
| it now, but perhaps there is another way to do this.

In OpenAxiom, constructorName gives you the name of the 'outermost',
e.g. the name (as a Symbol) of the constructor constructor.  For
example, I have

(2) -> constructorName reify Polynomial Integer
   (2)  Polynomial
                                                                 Type: Symbol

-- Gaby

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
open-axiom-devel mailing list
open-axiom-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/open-axiom-devel

Reply via email to