Approximation methods for LDE solutions Copyright © 2004-2012 DigiArea, Inc. . All rights reserved. Description: This worksheet illustrates ©LdeApprox ©package capability of doing polynomial approximation of solution of simple LDE. First of all we load LdeApprox package and define simple IVP. Then we use ApproxSol procedure to find 7-th degree polynomial approximation for the IVP solution on interval x = [-h,h]. After that we find exact solution by Maple™ procedure dsolve . Finally we compare exact and approximate results using Maple™ procedures plot ©and plot3d . This loads the package. restart: Examples: This is simple IVP with parameter ivp:={diff(y(x),x,x)+xi*y(x)=0,y(0)=0,D(y)(0)=1};
Finding polynomial approximation of the IVP solution on interval [-h, h]. apr:=ApproxSol(ivp,y(x),x=-h..h,7);
Finding exact solution of the IVP using Maple™ ©function dsolve . sol:=dsolve(ivp,y(x));
Comparing exact and approximate results for plot(subs({h=Pi/8,xi=1/4},subs(sol,y(x))-subs(apr,y(x))),x=-Pi/8..Pi/8);
Comparing exact and approximate results for plot3d(subs({h=Pi/8},subs(sol,y(x))-subs(apr,y(x))),xi=1/16..2,x=-Pi/8..Pi/8,axes=boxed);
Comparing exact and approximate results for plot3d(subs({xi=1/4},subs(sol,y(x))-subs(apr,y(x))),x=-h..h,h=-Pi/4..Pi/4,axes=boxed);
Note: This trivial example is just for Web. You can try more complex examples in your computer. |




©and 
![[Maple Plot]](Maple/LdeApprox/examples/images/simple10.gif)
©using Maple™ ©function plot3d![[Maple Plot]](Maple/LdeApprox/examples/images/simple12.gif)
©©using Maple™ ©function plot3d .![[Maple Plot]](Maple/LdeApprox/examples/images/simple14.gif)