What do you mean by "automatic"? Using 'simiplfy' I get

...
eq1:=subst(%,z = 1/(2*n));


                                          Type: Equation(Expression(Integer))
s1:=solve(%,f1);


                                    Type: List(Equation(Expression(Integer)))
simplify eval(f1,s1)


                 e1
   (13)  ------------------
           2    2    2    2
         (n  + m  + l )%pi
                                                    Type: Expression(Integer)
(14) ->


Is this what you expect?

Regards,
Bill Page.

On Fri, Aug 14, 2009 at 11:42 AM, Dan Hatton<[email protected]> wrote:
>
> Dear All,
>
> Appended below is an Axiom input script whose last two lines (the
> subst() and solve()) produce output involving cos(%pi/2), sin(%pi/2),
> and sin(%pi), which I'd naively expect to be automatically simplfied
> to 0, 1, and 0 respectively.  How can I get this automatic
> simplification to happen, please?
>
> Thanks,
>
> Dan
>
> l:Union(Variable l,Integer)
> m:Union(Variable m,Integer)
> n:Union(Variable n,Integer)
>
> A :=  a*sin(l*%pi*x)*cos(m*%pi*y)*cos(n*%pi*z)
> B :=  b*cos(l*%pi*x)*sin(m*%pi*y)*cos(n*%pi*z)
> C :=  c*cos(l*%pi*x)*cos(m*%pi*y)*sin(n*%pi*z)
> D :=  d*cos(l*%pi*x)*cos(m*%pi*y)*sin(n*%pi*z)
>
> E :=
>  e1*cos(l*%pi*x)*cos(m*%pi*y)*sin(n*%pi*z)+(e2+e3*cos(2*l*%pi*x)+e4*cos(2*m*%pi*y))*sin(2*n*%pi*z)
> F :=
>  f1*cos(l*%pi*x)*cos(m*%pi*y)*sin(n*%pi*z)+(f2+f3*cos(2*l*%pi*x)+f4*cos(2*m*%pi*y))*sin(2*n*%pi*z)
>
> A*differentiate(D,x)+B*differentiate(D,y)+C*differentiate(D,z)-E-differentiate(F,x,2)-differentiate(F,y,2)-differentiate(F,z,2)
>  = 0
>
> subst(%,z = 1/(2*n))
>
> solve(%,f1)
>


_______________________________________________
Axiom-mail mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/axiom-mail

Reply via email to