## Friday, 9 October 2020

### Plotting geodesics numerically

Geodesic equations are sets of second order differential equations and are usually somewhere between hard and impossible to solve analytically. The following are the geodesic equations for the surface of a sphere (S²):
$$\frac{d^2\theta}{d\lambda^2}-\sin{\theta}\cos{\theta}\left(\frac{d\phi}{d\lambda}\right)^2=0$$
$$\frac{d^2\phi}{d\lambda^2}+2\cot{\theta}\frac{d\phi}{d\lambda}\frac{d\theta}{d\lambda}=0$$They are about the simplest you can get and I still don't know if it's possible to solve them. When you have the solution you will be able to plot the geodesic curves as on the graph above.

This road block is very annoying and I have finally busted through it. It only took a couple of days! I started with some very simple examples to test that what I was doing was correct and tested the theory on said S² which I had explored in March 2019. It all works and the general procedure for constructing geodesics is quite straightforward really! What a nice surprise.😀

Read all about it here Plotting a differential equation.pdf (8 pages with lots of picture). It's a short instruction manual on how to do it yourself.