Sub topic 10
Work Done by a Spring: \(W = \frac{1}{2}kx^2\)
Assume you know Newton’s second law, basic vectors, and definite integrals. You should also know that work is energy transferred by a force through a displacement. This chapter focuses on an ideal spring, whose force changes as the spring stretches or compresses.
Hooke’s law and spring force
An ideal spring obeys Hooke’s law:
\[ F_{\text{spring}}=-kx \]
Here:
- \(F_{\text{spring}}\) is the force exerted by the spring, in newtons.
- \(k\) is the spring constant, in newtons per meter.
- \(x\) is the displacement from the spring’s relaxed length, in meters.
- The minus sign means that the spring force points toward the relaxed position.
A spring stretched to the right pulls to the left. A spring compressed to the left pushes to the right. The spring force is therefore not constant: its magnitude increases as \(|x|\) increases.
The spring constant \(k\) measures stiffness. A large \(k\) means that a large force is needed for a given stretch.
| Quantity | Meaning | SI unit |
|---|---|---|
| \(k\) | Spring stiffness | N/m |
| \(x\) | Stretch or compression from equilibrium | m |
| \(F\) | Spring-force magnitude | N |
| \(W\) | Work or energy transfer | J |
Deriving the spring-work formula
For a variable force, work is calculated with an integral:
\[ W=\int{xi}^{x_f} F(x)\,dx \]
Suppose a spring moves from \(x=0\) to \(x=x{\max}\). The spring force is \(F{\text{spring}}=-kx\), so the work done by the spring is
\[ W{\text{spring}} =\int0^{x{\max}}(-kx)\,dx =-\frac{1}{2}kx{\max}^2 \]
The negative sign is expected. During stretching, the spring force points opposite the displacement.
If an external agent stretches the spring slowly, the external force points in the same direction as the displacement:
\[ F_{\text{external}}=kx \]
Therefore, the work done by the external agent is
\[ W{\text{external}} =\int0^{x{\max}}kx\,dx =\frac{1}{2}kx{\max}^2 \]
This is the commonly stated spring-work formula:
\[ \boxed{W=\frac{1}{2}kx^2} \]
In this form, \(W\) is the positive energy transferred into the spring. That energy is stored as elastic potential energy:
\[ U_s=\frac{1}{2}kx^2 \]
The spring can later transfer this energy to another object.
Example: stretching a spring
A spring has \(k=200\ \text{N/m}\) and is stretched \(0.10\ \text{m}\). The energy stored is
\[ U_s=\frac{1}{2}(200)(0.10)^2 \]
\[ U_s=1.0\ \text{J} \]
The external agent does \(+1.0\ \text{J}\) of work on the spring. The spring does \(-1.0\ \text{J}\) of work during the stretch.
The force-versus-position graph is a straight line from zero force to \(kx\). The work is the triangular area under that graph:
\[ W=\frac{1}{2}(\text{base})(\text{height}) =\frac{1}{2}x(kx) =\frac{1}{2}kx^2 \]
General limits and signs
If the spring moves between arbitrary positions \(xi\) and \(xf\), the work done by the spring is
\[ W{\text{spring}} =\int{xi}^{xf}-kx\,dx =\frac{1}{2}kxi^2-\frac{1}{2}kxf^2 \]
This is also
\[ W{\text{spring}}=-\Delta Us \]
The spring does positive work when its stored energy decreases. For example, as a stretched spring returns toward \(x=0\), the spring force and displacement point in the same direction. The spring then transfers energy to the attached object.
The spring does negative work when its stored energy increases. This occurs while an external agent stretches or compresses it.
For an ideal spring, the energy depends on \(x^2\), so stretching by \(0.10\ \text{m}\) and compressing by \(0.10\ \text{m}\) store the same amount of energy. Real springs may stop obeying Hooke’s law at large deformations, so this formula has a limited range of validity.
def spring_energy(k, x):
"""Return the elastic energy stored in an ideal spring, in joules."""
return 0.5 * k * x**2
k = 200.0 # N/m
stretch = 0.10 # m
print(round(spring_energy(k, stretch), 3)) # 1.0Exercise
A spring with k = 500 N/m is compressed by 0.20 m. How much elastic potential energy does it store, and what is the work done by the spring during the compression?
Show answer
The stored energy is ½(500)(0.20)² = 10 J. The work done by the spring is −10 J because the spring force opposes the compression displacement.