I'm new to Mathematica, and have numerically solved two similar functions with the following code;
a = 5.9336*10^-6; ro = 500*10^-6; Do2 = 2*10^-9; f =
2.6835*10^-7; po = 100;
rl = Sqrt[(6*Do2*f*po)/a];
rn = ro (0.5 - Cos[(ArcCos[1 - (2*rl^2)/(ro^2)] - 2*Pi)/3]);
k = 1*10^-6;
sol = NDSolve[{a*C[r] == (C''[r] + (2/r) C'[r]) (C[r] + k),
C[ro] == f*po, C'[rn] == 0}, C, {r, rn, ro}];
solreal = NDSolve[{a == (Creal''[r] + (2/r) Creal'[r]), Creal[ro] == f*po,
Creal'[rn] == 0}, Creal, {r, rn, ro}];
Plot[Evaluate[{(C[r]/f) /. sol, (Creal[r]/f) /. solreal} ], {r, rn,
ro}, PlotRange -> All]
However, I have TWO problems; one is that even though the functions are increasing along the x-axis, the values of the Y-axis are all displaying the exact same number (100). Any idea why this is?
Secondly, can I some how open the array of values for these functions to look at what they are at specific points?
Sorry if these are obvious questions!
PlotRange->All
withPlotRange->{All , {99.999, 100.001}}
and you'll see what I mean. As for the function valuesC[0.00036] /. sol
gives you the value ofC
at0.00036
and so on. – gpap Apr 17 at 10:20