Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
NCTM or The Math Forum.



Re: system of differential equations mathematica help
Posted:
Jan 10, 2013 2:19 AM


Hi,
Your equations admit 2 first integrals: a[x]*u[x]=C1 u[x]^2/2+C2=p[x] With the help of the boundary conditions one gets C1=0.1 and C2=0.995. You may eliminate u and p and end up with a single equation: 50a''0.005a^(2)+2a^(3/2)=2.005 (Please check its correctness yourself. I did it fast and may have introduced minor errors). This one is more easy to solve. Even with this equation, however, NDSolve reports problems:
s = NDSolve[{a''[x]  0.005*a[x]^2 + 2*a[x]^(3/2) == 2.005, a[0] == 1, a[10] == 1}, a[x], {x, 0, 10}]
Power::infy: Infinite expression 1/0.^2 encountered. >>
Power::infy: Infinite expression 1/0.^(3/2) encountered. >>
Infinity::indet: Indeterminate expression 2.005 +ComplexInfinity+ComplexInfinity encountered. >>
Here one way is to try to regularize it so that one has no infinity at a>0:
s = NDSolve[{a''[x]  0.005*(a[x]^2 + 0.001)^1 + 2*(a[x]^2 + 0.001)^(3/4) == 2.005, a[0] == 1, a[10] == 1}, a[x], {x, 0, 10}] This is already better, as you may see by evaluating this:
Plot[a[x] /. s, {x, 0, 10}]
But there are still warnings:
FindRoot::cvmit: Failed to converge to the requested accuracy or precision within 100 iterations. >>
NDSolve::berr: There are significant errors {0.95868,0.852012} in the boundary value residuals. Returning the best solution found. >>
But in this point you may already look for some appropriate method to get a better solution. Try to go through the tutorials: Menu/Help/ tutorial/IntroductionToNumericalDifferentialEquations Menu/Help/ tutorial/NumericalSolutionOfDifferentialEquations And Menu/Help/ tutorial/NDSolveOverview
There you will find several approaches to apply in difficult cases as yours.
Have fun, Alexei
Alexei BOULBITCH, Dr., habil. IEE S.A. ZAE Weiergewan, 11, rue Edmond Reuter, L5326 Contern, LUXEMBOURG
Office phone : +35224542566 Office fax: +35224543566 mobile phone: +49 151 52 40 66 44
email: alexei.boulbitch@iee.lu



