I want to make a 3D plot of E1 and E2 ( notice) they are depends of four parameters w, w1, t1 ,and t2, as shown
E1 = -(2/w) Log[0.2] (1/w - t1) ((w^3 Log[1 - 1/w^3] - w^-3 + 1) - w^2) E2 = w1/2 (w1/2 - (w1) (t2)),
to evaluate t1 and t2 I need to solve the ode:
h1=7.6; s1 = ParametricNDSolveValue[{x''[r] + x'[r] == 5.403298039593166`*^-6 Cosh[x[r]], x[\[Epsilon]] == x0, x'[\[Epsilon]] == 0, WhenEvent[r == 0.1, x'[r] -> x'[r] + h1]}, {x, x'}, {r, \[Epsilon], 1}, {x0}, Method -> {"StiffnessSwitching"}, AccuracyGoal -> 5, PrecisionGoal -> 40, WorkingPrecision -> 40]; ff = Quiet@ FindRoot[Last[s1[x0]][1], {x0, -12, 1}, Evaluated -> False][[1, 2]]; t1 = 0.0003783822156577846` NIntegrate[r Exp[-First[s1[ff]][r]], {r, 0, 0.1}]
and
h2=12.6; s2 = ParametricNDSolveValue[{x''[r] + x'[r] == 5.403298039593166`*^-6 Cosh[x[r]], x[\[Epsilon]] == x0, x'[\[Epsilon]] == 0, WhenEvent[r == 0.1, x'[r] -> x'[r] + h2]}, {x, x'}, {r, \[Epsilon], 1}, {x0}, Method -> {"StiffnessSwitching"}, AccuracyGoal -> 5, PrecisionGoal -> 40, WorkingPrecision -> 40]; fff = Quiet@ FindRoot[Last[s2[x0]][1], {x0, -12, 1}, Evaluated -> False][[1, 2]]; t2 = 0.0003783822156577846` NIntegrate[ r Exp[-First[s2[fff]][r]], {r, 0, 0.1}]
then combine them into
Plot3D[{E1, E2}, {w, 2, 20}, {w1, 2, 20}]
I can solve for single values of h1 and h2, but I need to vary h1 and h2 by table or nest Do loop so that t1 and t2 changing as well as the curve of E1 and E2 as function of w1 and w2. Please help.
The post How to do 3D plot using ParametricNDSolve with do loop? appeared first on 100% Private Proxies - Fast, Anonymous, Quality, Unlimited USA Private Proxy!.