1 (load("contrib_ode"),0);
4 /* Test cases for ode1_lie functions */
6 /* Some exact equations from rtestode */
8 /* ode2(x^2*cos(x*y)*'diff(y,x) + (sin(x*y)+x*y*(cos(x*y)))=0, y, x); */
9 sym:ode1_a(phi:(sin(x*y)+x*y*(cos(x*y)))/(x^2*cos(x*y)),y,x);
11 symtest(phi,sym[1],sym[2],y,x);
14 /* ode2( (2*x*y-exp(-2*y))*'diff(y,x)+y=0, y, x); */
15 /* sym:ode1_a(phi:-y/(2*x*y-exp(-2*y)),y,x); BAD */
17 /* ode2( 'diff(y,x)=(y/x)^2+2*(y/x), y, x); */
18 sym:ode1_a(phi:(y/x)^2+2*(y/x), y, x); /* %psi_yyy=0 in ode1_a */
20 symtest(phi,xi:sym[1],eta:sym[2],y,x);
22 mu:lie_integrating_factor(phi,xi,eta);
24 lie_exact(phi,mu,y,x);
26 /* and the whole process */
27 ans:ode1_lie(phi,y,x);
29 ode_check('diff(y,x)=phi,first(solve(ans,y)));