Python Forum

Full Version: plotting from 3 differential equations
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,
I do not know how to get x-z plot from the equations below. I tried many ways but I could not achieve it. This is very important for my research. Thank you

dtheta/dt = -(1/2)*(cos(x)*cos(z)+sin(theta)/0.1)
dx/dt = 20*x/sin(theta) - (1/2)*cos(x)*sin(z)
dz/dt = 20*z/cos(theta) + (1/2)*sin(x)*cos(z)

t(time) spans between 0,2000

initial conditions:
theta0=pi/4
x0=-pi/2
z0=-pi/2
grknkilicaslan Wrote:I tried many ways but I could not achieve it
What have you tried? You could use scipy.integrate.solve_ivp()