Find potential energy function and show that it is proportional to displacement

Join the discussion
Registration is free. Start your own thread to ask a follow-up.
1 reply · 3K views
uph0
Messages
3
Reaction score
0

Homework Statement


Find the potential energy function for a spring if the origin is placed at the wall and the unstretched length of the spring is L. Show that with a suitable choice of the constant, this potential function is proportional to the square of the amount that the spring is stretched or compressed.

Homework Equations


F = d(h(x))/dx (F = force function)
U(x) = -h(x) (U(x) is potential energy function)

The Attempt at a Solution



Force of the spring
F = -kx

I integrated F and made the result negative to get the potential energy function
kx2/2 + C

But the Textbook solution is:
kx2/2 - kLx + C

How do I get -kLx? Also, I'm not sure about how I should start the second part of the problem.
 
Physics news on Phys.org
x is the distance from the wall, so the force is -k(x-L).