Message Boards Message Boards

0
|
2768 Views
|
1 Reply
|
1 Total Likes
View groups...
Share
Share this post:

Extrapolation from the InterpolatingFunction produced by NDSolve

 Clear["Global'*"];
 nut = 46; khi = 16; ro2 = 3400; kmrs = 4; kisu = 1.5; kmp = .5; kres \
 = 25;
 kccc1 = 38; k23 = 16; kvp = .04; kc = 21; nc = 5; km1 = 24; nm1 = 3;
 km2 = 45; nm2 = 4; kv1 = 17; nv1 = 6; kv2 = 200; nv2 = 4; k32 = 18; \
 n32 = 9; a = .5;
 odec = -(a c[t]) - (
    kccc1 c[t] (1 - 1/((c[t]/kv1)^nv1 + 1)))/((f3[t]/kv2)^nv2 + 1) - (
    kmrs c[t])/((fm[t]/km2)^nm2 + 1) + (khi nut)/((c[t]/kc)^nc + 1);
odefm = -(a fm[t]) + (kmrs c[t])/((fm[t]/km2)^nm2 + 1) - kisu fm[t] -
   kmp fm[t] o2[t];
odefs = kisu fm[t] - a fs[t];
odemp = kmp fm[t] o2[t] - a mp[t];
odeo2 = -(kmp fm[t] o2[t]) - kres fs[t] o2[t] +
   ro2/((o2[t]/245)^9 + 1);
odef2 = -(a f2[t]) - k23 f2[t] (1 - 1/((c[t]/k32)^n32 + 1)) + (
   kccc1 c[t] (1 - 1/((c[t]/kv1)^nv1 + 1)))/((f3[t]/kv2)^nv2 + 1);
odef3 = -(a f3[t]) + k23 f2[t] (1 - 1/((c[t]/k32)^n32 + 1)) -
   kvp f3[t];
odevp = kvp f3[t] - a vp[t];
vars = {c[t], f2[t], f3[t], fm[t], fs[t], mp[t], o2[t], vp[t]};
solution =
  NDSolve[{Derivative[1][c][t] == odec, Derivative[1][f2][t] == odef2,
     Derivative[1][f3][t] == odef3, Derivative[1][fm][t] == odefm,
    Derivative[1][fs][t] == odefs, Derivative[1][mp][t] == odemp,
    Derivative[1][o2][t] == odeo2, Derivative[1][vp][t] == odevp,
    c[0] == 30, f2[0] == 100, f3[0] == 100, fm[0] == 50, fs[0] == 50,
    mp[0] == 0, o2[0] == 100, vp[0] == 100}, vars, {t, 0, 31}];
vars
vars /. solution /. t -> 500
I am curious about the extrapolation "error" that is produced when I go  beyond the range of the interpolating function window. When I stay within the interpolating function, (expanding the window from {t, 0, 31} to say 1000) and go out to the limit of the window I produce the same values at the plateau around t=30. Are the extrapolated values I am getting from the interpolation function solutions viable? Is there a way to evaluate the error on these values?
POSTED BY: Josh Wofford
The answer to this was originally given by Gilbert and Sullivan in "The pirates of Penzance":

Chorus.What, never?
Captain.No, never!
Chorus.What, never?
Captain.Hardly ever!


See

http://youtu.be/jcwwFzZn-8I

The general answer is that, once you go beyond the range of the InterpolationFunction there is no way to estimate the error incurred except in very special cases.
NDSolve is generating a set of data points in the interval in which ti is called using whatever numerical method is chosen.  Outside of that interval nothing is known about the exact functional solution of the equatoin.  Once those data points are obtained, then Interpolation is called on that data (using the given value of the InterpolationOrder option -- which is by default Automatic) to create the InterpolationFunciton object. If, for a simple example, the InterpolationOrder is 1, then straight lines are drawn between the adjacent data points. If  the InterpolationOrder is 2, then a quadratic curve is drawn between sets of 3 data points, etc...  Only under very special circumstances will the result of the InterpolatinFunctions have anything to do with the actual functions' values beyond the limits of the InterpolationFunction.

--David
http://scientificarts.com
POSTED BY: David Reiss
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract