How do I know if the Hamiltonian is constant?

  • Context: Graduate 
  • Thread starter Thread starter komodekork
  • Start date Start date
  • Tags Tags
    Constant Hamiltonian
Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
9 replies · 7K views
komodekork
Messages
17
Reaction score
0
Lets say [tex]H = \frac{m}{2} (\dot{Q}^2 - \omega^2 Q^2 )[/tex]
where Q is the generalized coordinate.
It doesn't explicitly depend on time, but the Q and the [tex]\dot{Q}[/tex] does.
If i differentiate it with respect to time it should be zero if it's constant, right?
So i guess my question is should i treat the Q's as constants or as functions depending on time when i differentiate?
 
Last edited:
Physics news on Phys.org
komodekork said:
Lets say [tex]H = \frac{m}{2} (\dot{Q}^2 - \omega^2 Q^2 )[/tex]
where Q is the generalized coordinate.
It doesn't explicitly depend on time, but the Q and the [tex]\dot{Q}[/tex] does.
If i differentiate it with respect to time it should be zero if it's constant, right?
So i guess my question is should i treat the Q's as constants or as functions depending on time when i differentiate?

If you want to view it like that, then if the Hamiltonian is explicitly independent of time, then it just comes from equality of mixed partials.

[tex]\dot{H}=\frac{\partial H}{\partial q}\dot{q}+\frac{\partial H}{\partial p}\dot{p} =<br /> \frac{\partial H}{\partial q} \left(\frac{\partial H}{\partial p}\right)+<br /> \frac{\partial H}{\partial p}\left(-\frac{\partial H}{\partial q}\right)<br /> =0[/tex]
 
Last edited:
RedX said:
If you want to view it like that, then if the Hamiltonian is explicitly independent of time, then it just comes from equality of mixed partials.
I don't understand what you mean, could you please explain?
 
komodekork said:
I don't understand what you mean, could you please explain?

oops, you're right. it's not equality of mixed partials, but comes from Hamilton's equations.

so take H=.5(p2+q2)

Then dH/dp=p and dH/dq=q
But p.=-q and q.=p

So H.=p(-q)+q(p)=0
 
Hm...
I don't know if I see what you are getting at. I'm not sure if you are telling me that what you did is right or wrong.

Should it be [tex]\frac{d}{dt}(H) = m ( \dot{Q} \ddot{Q} - \omega^2 Q \dot{Q} )[/tex]

or just

[tex]\frac{d}{dt}(H) = 0[/tex]
 
komodekork said:
Hm...
I don't know if I see what you are getting at. I'm not sure if you are telling me that what you did is right or wrong.

Should it be [tex]\frac{d}{dt}(H) = m ( \dot{Q} \ddot{Q} - \omega^2 Q \dot{Q} )[/tex]

or just

[tex]\frac{d}{dt}(H) = 0[/tex]

oops, sorry. First of all, your Hamiltonian doesn't represent an oscillator. If it does, then the second term should be + rather than -:
[tex] H = \frac{m}{2} (\dot{Q}^2 + \omega^2 Q^2 )[/tex]

So as you say: [tex] \frac{d}{dt}(H) = m ( \dot{Q} \ddot{Q} + \omega^2 Q \dot{Q} ) [/tex]

Now from the equations of motion of an oscillator, [tex]\ddot{Q}=-\omega^2 Q[/tex]. PLugging that in should get you zero.
 
I don't know what my Hamilton represents. I may have done something wrong.

I all i got is this lagrangian [tex]L = \frac{m}{2} (\dot{q}^2 sin^2(\omega t) + \dot{q} q \omega sin(2\omega t) + \omega^2 q^2)[/tex]
and this new coordinate [tex]Q = q sin(\omega t)[/tex]

after this substitution i get [tex]L = \frac{m}{2} (\dot{Q}^2 + \omega^2 Q^2)[/tex]

then i make the Hamiltonian [tex]H = p\dot{Q} - L[/tex]

and get [tex]H = \frac{m}{2}(\dot{Q}^2 - \omega^2 Q^2)[/tex]



Then the question is, is the Hamiltonian constant?

Thanks for helping me out btw.
 
But forget all of that, just in a genreal case,
if [tex]H=H( \dot{q},q)[/tex] is it constant just because it's not [tex]H=H(p,q,t)[/tex]?
Or because it cancels out?
 
Last edited:
you need to write your Hamiltonian in terms of p and q not in terms of q and q-dot,
and THEN if time doesn't appear explicitly it's conserved.
 
komodekork said:
I don't know what my Hamilton represents. I may have done something wrong.

I all i got is this lagrangian [tex]L = \frac{m}{2} (\dot{q}^2 sin^2(\omega t) + \dot{q} q \omega sin(2\omega t) + \omega^2 q^2)[/tex]
and this new coordinate [tex]Q = q sin(\omega t)[/tex]

after this substitution i get [tex]L = \frac{m}{2} (\dot{Q}^2 + \omega^2 Q^2)[/tex]

then i make the Hamiltonian [tex]H = p\dot{Q} - L[/tex]

and get [tex]H = \frac{m}{2}(\dot{Q}^2 - \omega^2 Q^2)[/tex]



Then the question is, is the Hamiltonian constant?

Thanks for helping me out btw.

Can't you just plug in [tex] Q = q sin(\omega t)[/tex] into your Hamiltonian [tex]H = \frac{m}{2}(\dot{Q}^2 - \omega^2 Q^2)[/tex], and see if the time-dependence vanishes?