# Get a simplified result from PDE with NDSolve?

Posted 1 year ago
1337 Views
|
2 Replies
|
0 Total Likes
|
 Hi, I have tried out this command to test the results: op = I*Nest[op, \[CapitalPsi][r, \[Phi]], 3] == 2 \[CapitalPsi][r, \[Phi]]*r^2/Cos[\[Phi]]^5 sol = CapitalPsi[r, Phi] /. NDSolve[{op, CapitalPsi[0, Phi] == 1, Derivative[1, 0][CapitalPsi][0, Phi] == 0, Derivative[2, 0][CapitalPsi][0, Phi] == 10, Derivative[3, 0][CapitalPsi][0, Phi] == 0}, CapitalPsi, {r, 0, 3}, {Phi, 0, 3}, MaxSteps -> Infinity, PrecisionGoal -> 1, AccuracyGoal -> 1, Method -> {"MethodOfLines", "SpatialDiscretization" -> {"TensorProductGrid", "MinPoints" -> 32, "MaxPoints" -> 32, "DifferenceOrder" -> 2}, Method -> {"Adams", "MaxDifferenceOrder" -> 1}}] // Plot3D[sol, {r, 0, 3}, {Phi, 0, 3}, AxesLabel -> Automatic] However, I get a very messy output, with no plot. Is there something missing here?Thanks! Attachments:
 The first line gives already recursion errors In[2]:= op = I*Nest[op, \[CapitalPsi][r, \[Phi]], 3] == 2 \[CapitalPsi][r, \[Phi]]*r^2/Cos[\[Phi]]^5 During evaluation of In[2]:= $RecursionLimit::reclim2: Recursion depth of 1024 exceeded during evaluation of I op[op[op[\[CapitalPsi][r,\[Phi]]]]]. Out[2]= Hold[ I op[op[op[\[CapitalPsi][r, \[Phi]]]]] == 2 r^2 Sec[\[Phi]]^5 \[CapitalPsi][r, \[Phi]]] so NDSolve[] will most probably have been unable to something meaningful with that op. Answer Posted 10 months ago  I will indicate a similar case from which you can get your equation by substituting$x=\ln {r}, y=\ln {\sin( \phi )}\$ x0 = -10; x1 = 1; y0 = -10; y1 = -.01; eq = {\[CapitalPsi]1[x, y] == D[\[CapitalPsi][x, y], x] + D[\[CapitalPsi][x, y], y], \[CapitalPsi]2[x, y] == D[\[CapitalPsi]1[x, y], x] + D[\[CapitalPsi]1[x, y], y], -2* I*\[CapitalPsi][x, y]*Exp[2*x]/(1 - Exp[2*y])^(5/2) == D[\[CapitalPsi]2[x, y], x] + D[\[CapitalPsi]2[x, y], y], \[CapitalPsi][x0, y] == 1, \[CapitalPsi]1[x0, y] == 0, \[CapitalPsi]2[x0, y] == 0, \[CapitalPsi][x1, y] == 1, \[CapitalPsi]1[x1, y] == 0, \[CapitalPsi]2[x1, y] == 0}; sol = NDSolveValue[eq, \[CapitalPsi], {x, x0, x1}, {y, y0, y1}]; {Plot3D[Re[sol[x, y]], {x, x0, Log[3]}, {y, y0, y1}, PlotRange -> All, Mesh -> None, ColorFunction -> Hue, MaxRecursion -> 2, PlotPoints -> 50, AxesLabel -> Automatic, PlotLabel -> "Re\[CapitalPsi]"], Plot3D[Im[sol[x, y]], {x, x0, Log[3]}, {y, y0, y1}, PlotRange -> All, Mesh -> None, ColorFunction -> Hue, MaxRecursion -> 2, PlotPoints -> 50, AxesLabel -> Automatic, PlotLabel -> "Im\[CapitalPsi]"]}