[69] in mathematical software users group
Solving non-linear ODE's in Maple
daemon@ATHENA.MIT.EDU (Reid M. Pinchback)
Fri Feb 19 16:39:20 1993
To: msug@Athena.MIT.EDU
Date: Fri, 19 Feb 93 16:37:11 EST
From: "Reid M. Pinchback" <reidmp@Athena.MIT.EDU>
Just as an interesting note for anybody whoever tried to solve
non-linear ODE's in Maple (and was frustrated).
Since the "D" operator notation is nice and compact, I've fiddled with
trying to use it to specify diffeqs properly. Something that wasn't
obvious to me in the previous release of Maple became clear when I
started playing with Release 2, and that is that you need to be quite
specific in how you specify function composition, or dsolve won't
understand the equation.
For instance, lets say you want to solve D sin(y) = y for y(t). What
I used to try and do (and didn't work), were things like:
dsolve( D(sin(y(t))), y(t) );
or:
dsolve( D(sin(y))(t), y(t) );
neither of which worked. What *does* work is:
dsolve( D(sin@y)(t), y(t) );
D is expecting a univariate function, so it doesn't know to apply the
the chain rule until it recognizes that it is dealing with function
composition. By using the composition operator "@", it realizes that
both "sin" and "y" are functions... otherwise it thinks just "sin" is
the function, and "y" is an independent variable.
The reason that I finally figured this out is that now under Release 2
the "D" operator gives an error message when applied in ways like I
attempted to use it in the first two cases.
Live and learn. May others benefit from my mistakes. :-)
-----------
Reid M. Pinchback
Faculty Liaison
Academic Computing Services, MIT