Why Does Planetary Energy Increase in My ODE Simulation?

jmtome2
Messages
67
Reaction score
0

Homework Statement


OK so here goes.

I'm using an ODEsolver in java to plot the total energy over time of a planetary system. So I've been trying to calculate the rate of energy (per unit mass), \frac{E}{m}.

Homework Equations


The equation for total energy (per unit mass) of a planetary system is:
\frac{E}{m}=1/2\cdot v^2-\frac{G\cdot M}{r}

G is the gravitational constant
M is the mass of the sun (constant)
v is the velocity of the planet, v^2=v^{2}_{x}+v^{2}_{y}
r is the distance of the planet from the sun, r^2=x^{2}+y^{2}

Essentially I need help finding \frac{dE}{dt}


The Attempt at a Solution


The answer I got for the rate is:

\frac{dE}{dt}=v\cdot\left(a+\frac{G\cdot M}{r}\right)

where a is the acceleration of the planet, a^2=a^{2}_{x}+a^{2}_{y}

The problem is that everytime I throw this equation into the ODEsolver, I get a plot of ever-increasing energy as time goes on which I know is not correct.

Help anybody?
 
Physics news on Phys.org
Isn't dE/dt = 0 because energy is conserved? Am I missing something here?
 
YES! Of course it is... what was I thinking. But this creates a whole problem... I've got to figure out how to plot E now inside the program without using the ODEsolver, which hasn't been mentioned in the book yet. *sigh*

Thanks for clarifying :)
 
Hello everyone, I’m considering a point charge q that oscillates harmonically about the origin along the z-axis, e.g. $$z_{q}(t)= A\sin(wt)$$ In a strongly simplified / quasi-instantaneous approximation I ignore retardation and take the electric field at the position ##r=(x,y,z)## simply to be the “Coulomb field at the charge’s instantaneous position”: $$E(r,t)=\frac{q}{4\pi\varepsilon_{0}}\frac{r-r_{q}(t)}{||r-r_{q}(t)||^{3}}$$ with $$r_{q}(t)=(0,0,z_{q}(t))$$ (I’m aware this isn’t...
Hi, I had an exam and I completely messed up a problem. Especially one part which was necessary for the rest of the problem. Basically, I have a wormhole metric: $$(ds)^2 = -(dt)^2 + (dr)^2 + (r^2 + b^2)( (d\theta)^2 + sin^2 \theta (d\phi)^2 )$$ Where ##b=1## with an orbit only in the equatorial plane. We also know from the question that the orbit must satisfy this relationship: $$\varepsilon = \frac{1}{2} (\frac{dr}{d\tau})^2 + V_{eff}(r)$$ Ultimately, I was tasked to find the initial...
Back
Top