# How to plot the solutions to the following differential equation

I have the following set of differential equations:

\begin{align*} \ddot{\theta}(s) & = \Gamma_{\varphi \varphi}^\theta\dot{\varphi}(s)^2 = \frac{\sin\theta \dot{\varphi}(s)^2}{(2+\cos\theta)},\\ \ddot{\varphi}(s) & = 2\Gamma_{\theta \varphi}^\varphi\dot{\varphi}(s)\dot{\theta}(s) = -\frac{2\sin \theta \dot{\varphi}(s)\dot{\theta}(s)}{(2+\cos\theta)}. \end{align*}

where $$s \in [0,1]$$. How can I plot the solutions to this system?

Hint.

First you need initial/boundary conditions. After observing the odes, the last

one can be rearranged as

$$\frac{\ddot{\varphi}(s)}{\dot{\varphi}(s)}=-\frac{2\sin \theta \dot{\theta}(s)}{(2+\cos\theta)}$$

or

$$\ln(\dot{\varphi}) = 2\ln(2+\cos(\theta))+C$$

or

$$\dot{\varphi}= C_0e^{2\ln(2+\cos(\theta))}$$

etc.

sol = NDSolve[{theta''[s] == Sin[theta[s]] psi'[s]^2/(2 + Cos[theta[s]]),
psi''[s] == -2 Sin[theta[s]] psi'[s]/(2 + Cos[theta[s]]),
theta[0] == psi[0] == psi'[0] == 0, theta'[0] == 1}, {theta, psi}, {s, 0, 1}][[1]];
Plot[Evaluate[{theta[s], psi[s]} /. sol], {s, 0, 1}]


Note that with $$\varphi(0)=\varphi'(0)=0$$ we have $$\varphi(s)=0$$ so remains $$\theta(s) = c_1 + c_2 s$$

• That was nice, I didn't notice! Unfortunately, substituting that $\dot{\varphi}$ in $\ddot{\theta} = C_0^2\sin\theta (2 + \cos\theta)^3$ doesn't yield something useful? For the initial conditions we can assume that $\theta(0) = \varphi(0) = 0$ and $\dot{\theta} = 1$ and $\dot{\varphi} = 0$. I guess this is possible? Feb 5 at 17:45
{"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 1, "mathjax_display_tex": 0, "mathjax_asciimath": 1, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 8, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0}