# DSolve Doesn't Return a Solution or Error

DSolve is not returning anything other than the original expression on

DSolve[{z''[s] +
2/(R^2 - z[s]^2 - y[s]^2) (z[s]*z'[s]^2 + 2*y[s]*y'[s] z'[s] -
z[s] y'[s]^2) == 0,
y''[s] + 2/(R^2 - z[s]^2 - y[s]^2)*(y[s]*y'[s]^2 +
2*z[s]*z'[s]*y'[s] - y[s]*z'[s]^2) == 0}, {z[s], y[s]}, s]


Am I doing something wrong or is this differential equation too difficult?

• When Mathematica returns DSolve or Integrate unevaluated, then it is too difficult. You may try this: assign a number to R, specify initial conditions, and apply NDSolve instead. – Henrik Schumacher May 20 '19 at 20:37
• Is there a way to restrict (z[s]^2 + y[s]^2) <= R^2 in an effort to make it easier? – user65710 May 20 '19 at 20:54
• You could try the Assumptions options, e.g. Assumptions -> R^2 > z[s]^2 + y[s]^2. But that won't help. – Henrik Schumacher May 20 '19 at 21:02
• Thank you for your help! – user65710 May 20 '19 at 21:04
• You're welcome. – Henrik Schumacher May 20 '19 at 21:11

We can change {z, y} to polar coordinates {r, t} and reduce the order of the t differential equation of the resulting system. After that, DSolve can handle it.

ClearAll[z, y, r, t, u, s];
syszy = {                    (* OP system *)
z''[s] + 2/(R^2 - z[s]^2 - y[s]^2) (z[s]*z'[s]^2 + 2*y[s]*y'[s] z'[s] -
z[s] y'[s]^2) == 0,
y''[s] + 2/(R^2 - z[s]^2 - y[s]^2)*(y[s]*y'[s]^2 + 2*z[s]*z'[s]*y'[s] -
y[s]*z'[s]^2) == 0};
sysrt = syszy /. {           (* to polar coordinates *)
z -> Function[s, r[s] Cos[t[s]]],
y -> Function[s, r[s] Sin[t[s]]]} // Simplify;
sysrt = Equal @@@            (* put in form  r''[s] ==.., t''[s] ==.. *)
First@Solve[sysrt, {r''[s], t''[s]}];
sysru = sysrt /. t -> Derivative[-1][u] (* reduce order *) There are eight solutions returned for the reduced system sysru. Like a miracle, the solution for u can be integrated to give t in all eight.

dsolru = DSolve[sysru, {r, u}, s];  (* solve reduced system *)

kk = 1;                             (* Length@dsolru == 8 sols *)
dsolrt = {dsolru[[kk, 1]],          (* k-th sol, r, t -> Integrate[u] *)
t -> Function @@ {s, Integrate[u[s] /. dsolru[[kk]], s] + C}};
dsolzy = Thread[{z, y} ->           (* polar to  {z, y} solution *)
(Function[s, #] & /@
Simplify[{r[s] Cos[t[s]], r[s] Sin[t[s]]} /. dsolrt])] I spot checked it and the other seven solutions (kk = 2..8) with the following:

syszy /. Equal -> Subtract /. dsolzy /. {R -> 4} /. {C -> 1/2,
C -> 1/3, C -> 1/4, C -> 1} /. s -> 1.24
(*  {0.*10^-17 + 0.*10^-17 I, 0.*10^-17 + 0.*10^-17 I}  *)


I tried checking it also with the following, but it didn't finish within ten minutes:

syszy /. dsolzy //
Quiet@Simplify[#, TimeConstraint -> 0.1] & // AbsoluteTiming


Further numerical verification:

syszy /. Equal -> Subtract /. dsolzy /. {R -> 4} /. {C -> 1/2,
C -> 1/3, C -> 1/4, C -> 1} /.
s -> RandomReal[{-1, 2}, 100, WorkingPrecision -> 32] // Abs // Max
(*  0.*10^-18  *)
`