Matched Asymptotic Expansion Compared with the Numerical Solution

The following equation is "too difficult" for Mathematica to find an analytical solution:

ε y'' + 2 y' matched_pert_1.gif=0
with y(0)=0 and y(1)=0.

When something is too difficult, Mathematica returns the command that was typed (after saying "running" in the top bar of the window for about 20 seconds).

So we solve the equation by a discrete numerical method, and by a method of matched asymptotic expansions.  The ODE is a two-point boundary-value problem, which we solve using a shooting scheme.

matched_pert_2.gif

matched_pert_3.gif

matched_pert_4.gif

matched_pert_5.gif

matched_pert_6.gif

So we take out pencil and paper and find the following solution using matched asymptotic expansions:

matched_pert_7.gif

matched_pert_8.gif

matched_pert_9.gif

matched_pert_10.gif

Note the following property of our approximate solution.  This information will be needed when we attempt to find a numerical solution.

matched_pert_11.gif

matched_pert_12.gif

To check our solution, we find a numerical solution for a particular value of ε.  Mathematica solves ODE's by marching from initial conditions specified at a starting point.  So we need to iterate to satisfy the condition y[1]=1/2 using what is called a "shooting method": we use matched_pert_13.gif where we expect s will be a number near 1.

matched_pert_14.gif

matched_pert_15.gif

matched_pert_16.gif

matched_pert_17.gif

Let's try to use that InterpolatingFunction thing.  The replacement rule for y is in a nested list.  Let's evaluate it at t=0.3

matched_pert_18.gif

matched_pert_19.gif

matched_pert_20.gif

matched_pert_21.gif

matched_pert_22.gif

As seen above, with s=1, our shooting scheme missed the boundary condition matched_pert_23.gif.  So we need to find the correct value of s.

matched_pert_24.gif

matched_pert_25.gif

matched_pert_26.gif

matched_pert_27.gif

matched_pert_28.gif

matched_pert_29.gif

matched_pert_30.gif

matched_pert_31.gif

matched_pert_32.gif

matched_pert_33.gif

matched_pert_34.gif

matched_pert_35.gif

So we see that we have a numerical solution that satisfies both boundary conditions. Let's plot it out and compare it with our approximate solution.

matched_pert_36.gif

matched_pert_37.gif

matched_pert_38.gif

matched_pert_39.gif

matched_pert_40.gif

matched_pert_41.gif

Next we plot both the numerical and the perturbation solution together.  They very nearly overlap:

matched_pert_42.gif

matched_pert_43.gif

matched_pert_44.gif

matched_pert_45.gif

matched_pert_46.gif

matched_pert_47.gif

matched_pert_48.gif

matched_pert_49.gif

matched_pert_50.gif

Spikey Created with Wolfram Mathematica 8.0