Re: Unable to obtain value from interpolation function integration
- To: mathgroup at smc.vnet.net
- Subject: [mg59605] Re: Unable to obtain value from interpolation function integration
- From: rknapp at wolfram.com
- Date: Sat, 13 Aug 2005 03:26:44 -0400 (EDT)
- References: <ddhjqj$h7q$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
A good way to get an integral of a derived function at little
additional cost is to include it in the differential equations.
add the equation
y12int'[t] == (y1[t]* λr)V2*((DCFI*br + DCFE)) + (y2[t]*DCFG*
λr)/PCUArea
to the differential equations. Then with
solution = NDSolve[..., {y1, y2, y12int}, {t,0,90000}]
Then the plot could be done with
Plot[Evaluate[y12int'[t] /. solution], {t, 0, 100000. }])
and the integrated value would be
DInt[t_] = y12int[t] /. First[solution]
I can't actually run the example because you did not include values for
all or
the parameters
Rob Knapp
Wolfram Research