[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Axiom-math] Re: expand

From: Richard B. Kreckel
Subject: [Axiom-math] Re: expand
Date: Wed, 19 Nov 2003 21:41:12 +0100 (CET)

Dear Tim,

On Mon, 17 Nov 2003, root wrote:
> (1) -> a:=(x+y+z)^2-x^2-y^2-z^2
>    (1)  (2y + 2x)z + 2x y
>                                                      Type: Polynomial Integer
> (2) -> c:DMP([x,y,z],FRAC(INT)):=a
>    (2)  2x y + 2x z + 2y z
>             Type: DistributedMultivariatePolynomial([x,y,z],Fraction Integer)
> The issue is the type chosen. The result (1) is a polynomial in z of the
> form a * z + b where a == (2y + 2x) and b == 2xy
> If you want x and y to also be variables you need the second form where
> you explicitly request that x, y, and z are variable.
> The display of an equation is intimately bound to its type.

Sorry, Tim, but how on earth does it occur to Axiom that the original
polynomial was in z?  Why not in x?  Or y?  It simply says "Polynomial
Integer"!  How does it deduce the type?  Where can I read about this?!?

I know about the power of types and the pain of proper coercion and all
that.  But this is not intuitive.  This is daunting.  Sorry.  How can it
be improved?

Richard B. Kreckel

reply via email to

[Prev in Thread] Current Thread [Next in Thread]