# Sign of potential energy of SHO

1. Dec 27, 2013

### devang2

Suppose the particle is at distance x from mean position and moving away . The standard formula for calculating potential U is U=-w here wis the work w=kxdx when the particle is moving away .On integration U=1/2Kx^2 . When the particle is moving towards mean position w=-kxdx on integration U=-1/2kx^2 thus the sign changes with direction Is it correct

2. Dec 27, 2013

### devang2

sorry i omitted in my previous post that work is calculated by dot product formula

3. Dec 27, 2013

### Tanya Sharma

Suppose there is a spring with its left end attached to a wall and right end having a block of mass m .Now we pull it slowly towards right ,then the work done by external agent is stored as potential energy.

W = ∫ F.dx
= ∫kxdxcos0 (since force is parallel to the displacement )
= [(1/2)kx2]0x
= (1/2)kx2

So , U = (1/2)kx2

4. Dec 28, 2013

### devang2

Thank you for the reply . So you mean that whether the spring is stretched or compressed the potential energy is always positive.While calculating the potential of particle executing simple harmonic oscillations the energy is always positive . I have used basic relation dU=-w to calculate the potential energy which gives opposite signs of potential energy when the particle is moving away or towards the mean position . Please take some trouble to point out where i have gone wrong while using the above formula

5. Dec 28, 2013

### Tanya Sharma

See...understand one thing dU = -dW,if dW is work done by the conservative force,spring force in our spring block example . But dU = dW if dW is work done by external agent .

Do you agree with this ?

6. Dec 28, 2013

### Philip Wood

This is correct. The reason is that a system's potential energy is the work it can do because of configuration (i.e. the relative positions of its parts). So if a system DOES work dW, it loses potential energy dU.

Suppose we consider force and displacement components in the x direction, that is the direction which tends to stretch the spring. If the spring is already extended, Fx will be negative, so for positive dx, dW = Fx dx will be negative and dU will be positive.
If the spring is compressed Fx will be positive, and if we compress it further, dx will be negative, so dW = Fx dx will be negative and dU will (again) be positive.

7. Dec 29, 2013

### devang2

Thank you for the reply .AS you know for oscillator force is always -kx and always directed towards mean position . i calculate the work dw by applying dot product of force and displacement. While dot product formula you know scalar values of force and displacement are used . When the particle is moving away from mean position angle is 180 because force and displacement are in opposite direction hence dw is negative but when particle is moving towards mean position force and displacement are in the same direction hence angle is 0 therefore according to product dw is positive. I shall be very thankful if you point out where i have gone wrong

8. Dec 29, 2013

### Staff: Mentor

The potential energy is at a maximum when the displacement is at a maximum, and it's zero at the mean position. So it's not at all surprising that the sign of $dW$ is different when the displacement is increasing and when the displacement is decreasing; in one case we're putting energy into the spring and in the other case we're taking energy out of it.

9. Dec 29, 2013

### Philip Wood

My method also uses dot product. If two vectors, A and B, have no y or z components, then it is easy to show that A.B = AxBx. The components, Ax and Bx, are scalar, but can be positive or negative.

Suggest you read my post carefully again, with this in mind. Or, if you prefer, use magnitudes (scalar and non-negative) of vectors, and put in the cosine value, +1 or -1, separately as you follow my argument. You'll find it gives the same result as my method each time. The argument shows that the more you deform the spring - either by extending it or compressing it - the more energy it stores. If you repeat the argument, changing the sign of dx, you'll find that if you reduce the deformation - either the extension or the compression - the spring stores less energy.

What I found confusing in your last post - and it may have some bearing on your own difficulty - is what you mean by 'displacement'. Are you using it to mean displacement of the mass from its equilibrium position (that's the usual meaning) or are you using it to mean the incremental displacement, dx?

Last edited: Dec 29, 2013
10. Dec 30, 2013

### devang2

Thank you for the trouble you have taken for the clarification . By displacement i mean the distance of the mass of the particle from the mean position executing harmonic oscillation.
suppose spring is stretched by certain distance , the work involved is w(!) and when the spring is released to restore the equilibrium original position work involved is W(2) because spring is in original state no net work is done therefore w(!)+w(2)=0 which leads to the conclusion the sign of work during stretching and decompressing are opposite .Similarly when the particle executing harmonic oscillation is moving away from mean position it is like stretching and when it is moving towards mean position it is like decompressing hence sign of work when it is moving away from mean position is negative and when it moves towards mean position it is positive which finally leads to the conclusion that sign of potential energy when particle is moving away is positive and it is negative when motion of particle is towards mean position I shall be very thankful if you let me know if i am right or wrog

11. Dec 30, 2013

### Philip Wood

Yes, that's right. The work done BY the spring is negative when it is being compressed or extended, and positive when being decompressed or de-extended. But, since I can see you like precision, I'll point out that your last sentence isn't quite correct...

What you should say is that the sign of the CHANGE in potential energy when particle is moving away is positive and it is negative when the motion of the particle is towards the mean position. [The potential energy itself is always positive (or zero) if we adopt the usual convention of assigning zero to the potential energy when the spring is undeformed.]

12. Dec 30, 2013

### vanhees71

I don't understand the problem. It's pretty simple. The potential of a force (if it exists!) is defined by
$$\vec{F}(\vec{r})=-\vec{\nabla} V(\vec{r}).$$
Given that, for the isotropic harmonic oscillator,
$$\vec{F}(\vec{r})=- m \omega^2 \vec{r},$$
you find by simple integration or taking the appropriate line integral (e.g., a straight line from the origin to $\vec{r}$) you get
$$V(\vec{r})=\frac{m \omega^2}{2} \vec{r}^2.$$
You easily check that indeed this is the potential, i.e., that $\vec{F}$ is indeed a conservative field.

Of course it also satisfies the local condition
$$\vec{\nabla} \times \vec{F}=0,$$
and since it is defined and analytic everywhere in $\mathbb{R}^3$ there must exist a potential.

13. Dec 31, 2013

### devang2

thank you for the analytical reply. My problem is very basic and simple ,it is about the sign of potential which changes sign with change in direction of motion of the particle executing harmonic oscillation though magnitude remains same .There is change in sign if potential is calculated by applying the basic formula ,dU=-W u is the potential and w is the work which i calcule by using dot product. Please calculate the potential by using this method , you will will see that sign of potential is positive when particle is moving away from mean position while it is negative when particle is moving towards mean position.Please pay attention to the sign. I shall be very thankful if you let me know your views about the change in sign .All the text books assign positive sign yo the potential disregarding the change in direction of motion .You know when mass is shifted to infinity from earth against gravity potential is positive but it is negative when it is brought from infinity moving in the direction of gravity thus it is seen that there is change in sign with the direction so same thing is applicable to motion of particle executing harmonic scillation because it is continusuosly changing direction of motion

14. Dec 31, 2013

### Philip Wood

You're still making the mistake that I pointed out in my last post! It's not the potential energy, but the CHANGE in potential energy which is positive when the particle is moving away from the mean position and negative when the particle is moving towards the mean position. The potential energy itself is always positive (if we assign zero to it at the mean position, when the spring is unstretched). It is more positive the more the spring is stretched.

Say if you're still not clear.

[PS: You've started to write 'potential' instead of 'potential energy'. Stick with potential energy!]

Last edited: Dec 31, 2013
15. Jan 1, 2014

### devang2

Thank you very much indeed for the clarification and pointing out ther mistake from which it can be concluded that work is negative when the particle is moving away from mean posiytion whereas it is positive whan the particle is moving towards mean position .

16. Jan 1, 2014

### Philip Wood

That's right: work done by the spring (or other body responsible for the restoring force) is negative when the particle moves away from the mean position, so the spring gains potential energy (dU = -dW). If we stretch the spring by X, then potential energy stored is

$$U = \int_{x = 0}^{X}{dU} = -\int_{x =0}^{X}{dW} = -\int_{0}^{X}{-kx dx} =\frac{1}{2}k X^2$$

You won't find it done quite like this in the textbooks. I'm using dW to mean an increment of work done BY the spring, following - I hope - what you were doing. If you consider the work done ON the spring as it is stretched, you can dispense with the minus signs in the above derivation.

Last edited: Jan 1, 2014
17. Jan 2, 2014

### devang2

Your way of expressing makes it easy for me to understand the problem.If the particle is moving towards the mean position,applying the method as adopted when the particle is moving away from mean position potential energy of the particle in SHO is negative that is -1/2kx^2. I shall be very thankful if you can clarify it . My contention is that the potential energy changes sign with change in direction of motion

18. Jan 2, 2014

### vanhees71

No, it doesn't. It doesn't even depend on the velocity. The potential is $V(\vec{r})=k \vec{r}^2/2$ and thus independent on the direction of the position vector and doesn't depend on velocity at all. It's the force, which is
$$\vec{F}=-k \vec{r}$$
that changes it's direction with the position vector, not the potential!

19. Jan 2, 2014

### Philip Wood

deVang2. Same mistake AGAIN ! When the particle is moving TOWARDS the mean position, the CHANGE in potential energy is negative, so the spring is LOSING the potential energy that it had when it had a greater displacement. By the time it has got back to x = 0 it has lost ALL the potential energy. So at x = 0, it has zero potential energy, not a negative potential energy. Its potential energy never goes negative.

20. Jan 2, 2014

### Philip Wood

Same mistake AGAIN ! As the particle moves towards the mean position the CHANGE in potential energy is negative, so the spring is losing the potential energy which it had at displacement X. When it has got back to the mean position it has lost ALL the potential energy. Its potential energy is now zero. The potential energy is never negative.