I am new to Python so at this moment in time, I can only very basic problems.

How do I numerically solve an ODE in Python?

Consider

\ddot{u}(\phi) = -u + \sqrt{u}

with the following conditions

u(0) = 1.49907

and

\dot{u}(0) = 0

with the constraint

0 <= \phi <= 7\pi.

Then finally I want to produce a parametric plot where the x and y coordinates are generated as a function of u.

The problem is I need to run odeint twice since this is a second order differential equation.
I tried having it run again after the first time but it comes back with a Jacobian error. There must be away to run the twice all at once.

Here is the error:

odepack.error: The function and its Jacobian must be callable functions

which the code below generates. The line in question is the sol = odeint.

Edit: You have to get your derivative to first order to use numerical integration. This you can achieve by setting e.g. z1=u and z2=du/dt, after which you have dz1/dt = z2 and dz2/dt = d^2u/dt^2. Substitute these into your original equation, and simply iterate over the vector dZ/dt, which is first order.

The code from your other question is really close to what you want. Two changes are needed:

You were solving a different ODE (because you changed two signs inside function deriv)

The y component of your desired plot comes from the solution values, not from the values of the first derivative of the solution, so you need to replace u[:,0] (function values) for u[:, 1] (derivatives).