I have solved and plotted a system of differential equations, shown below, using Mathematica's NDSolve function. Now I would like to take the derivative of one the resulting interpolating functions and evaluate it at a point in the domain.
Pbub = 1.00002
kl = 2.09015;
ccl20 = 0.00206957
cc2h4eq = 0.000301892
Dc2h4 = 1.48*10^(-5);
Dcl2 = 2.90*10^(-9);
t = 183.0 + 273.15;
k1 = 11493.0*Exp[-2156.58/t];
k2 = 8.517*10^9*Exp[-7282.21/t];
\[Delta] = Dc2h4/kl;
eqn1 = Dc2h4*aa''[x] == k1*aa[x]*b[x] + k2*aa[x]*b[x]^2;
eqn2 = Dcl2*b''[x] == k1*aa[x]*b[x] + 2*k2*aa[x]*b[x]^2;
eqn3 = Dcl2*c''[x] == -k1*aa[x]*b[x];
eqn4 = Dcl2*d''[x] == -2*k2*aa[x]*b[x]^2;
eqn5 = Dcl2*ee''[x] == -2*k2*aa[x]*b[x]^2;
bc1 = aa[0] == cc2h4eq;
bc2 = aa[\[Delta]] == 0;
bc3 = b'[0] == 0;
bc4 = b[\[Delta]] == ccl20;
bc5 = c'[0] == 0;
bc6 = c[\[Delta]] == 1.253/98.95;
bc7 = d[0] == 0;
bc8 = d[\[Delta]] == 0.0001;
bc9 = ee[0] == 0;
bc10 = ee[\[Delta]] == 0.0001;
soln = NDSolve[{eqn1, eqn2, eqn3, eqn4, eqn5, bc1, bc2, bc3, bc4, bc5,
bc6, bc7, bc8, bc9, bc10}, {aa[x], b[x], c[x], d[x], ee[x]}, {x,
0, 4*\[Delta]}]
Specifically, I would like to determine: aa'[0]. I've tried various methods using assignment operators, evaluate, etc ... However, none of them have worked thus far. How should I proceed?
NDSolve::ndsv: Cannot find starting value for the variable aa^\[Prime].
You should make sure code posted runs without errors. You do not havePbub
defined. $\endgroup$D
(see documentation) also toInterpolatingFunction
s. $\endgroup$aa'[0]
in your list of functions to be solved for. $\endgroup$