Pendulum restrained by a horizontal spring
A light rod of length $L$ hangs from a fixed pivot and carries a mass $m$ at its end. A horizontal spring of stiffness $k$ joins the rod to a wall at a distance $a$ below the pivot. In equilibrium the rod is vertical and the spring is unstretched. Determine the equation of motion, including the small-angle case.
Explanation of Method
Take the rod angle as the generalized coordinate. Write the kinetic and potential energy, apply Lagrange's equation, and linearize for small angles. The simulator shows how the spring attachment and the amplitude change the period.
A one-degree-of-freedom system: a mass on a light rod, pivoted at the top and held by a horizontal spring attached part-way down the rod. The nonlinear equation of motion comes from Lagrange's equation and is checked with the variational indicator. It is then linearized for small angles, built as Simulink models, and run in the simulator to see how the parameters, the amplitude, and the spring attachment change the oscillation.
Problem statement
The mass of the long uniform rod shown in the figure is negligible compared with the mass \(m\) at its end. Determine the equation of motion of the system, and also consider the case of small angles.
- The rod has length \(L\) and hangs from a fixed pivot \(O\) on a horizontal support.
- At distance \(a\) below the support, the rod is connected to a vertical wall by a horizontal spring of stiffness \(k\).
- In the equilibrium position the rod is vertical and the spring is unstretched.
There is no friction and no external input. The system is conservative and has one degree of freedom.
Generalized coordinate and geometry
The rod can only rotate about \(O\), so a single coordinate describes the whole system. The paper chooses the angle \(\theta\) between the rod and the vertical.
Notation: \(x\) is the horizontal displacement of the rod at the spring level, and \(e\) is the spring elongation. For the rod to stay connected to the spring, they must be equal. This is the geometric constraint \(x = e\).
Height of the mass
With \(b\) the vertical distance from the spring level to the displaced mass (Figure 1.3 of the paper), \(a+b = L\cos\theta\) and \(a+b+h = L\). The rise of the mass is therefore
Spring elongation
The paper takes the right triangle formed by the vertical, the spring level and the rod:
This means the spring stays at the fixed depth \(a\) below the support, and its end slides along the rod (like a collar). If instead the spring is fixed to the point of the rod at distance \(a\) from \(O\), that point moves on a circle and \(x = a\sin\theta\). The two readings agree for small angles but not for large ones (see section 8).
Energies of the system
3.1 Repulsive (kinetic) coenergy
The rod is massless, so only the mass \(m\) contributes. It moves on a circle of radius \(L\), so \(v = L\dot\theta\):
The paper writes the intermediate steps as \(\omega = L\dot\theta\) and \(v = L\cdot L\dot\theta\). These are typos: \(\omega=\dot\theta\) and \(v = L\dot\theta\). The final result (1.3) is correct.
3.2 Attractive (potential) energy
The gravitational energy of the mass (zero at the lowest position) plus the energy of the spring:
3.3 Lagrangian
Lagrange equation
There are no non-conservative forces, so the right-hand side is zero:
This is a nonlinear second-order differential equation.
Small angles
For \(\theta\ll1\): \(\sin\theta\approx\theta\) and \(\cos\theta\approx1\), which gives
The two restoring effects add up: gravity alone would give a simple pendulum (\(g/L\)), and the spring adds stiffness \(ka^2\) about the pivot.
Check with the variational indicator
The paper verifies the result with the variational indicator, which has the general form
No forces do work on the variation \(\delta\theta\), so only the first term remains. Using \(\frac{d}{dt}\delta\theta = \delta\dot\theta\):
Integrating the first term by parts, with \(\delta\theta = 0\) at \(t_1\) and \(t_2\):
The indicator must vanish for every admissible variation \(\delta\theta\), so the bracket must be zero. This gives exactly equation (1.16) again, confirming the derivation.
Simulink models
For simulation the equations are solved for the highest derivative:
The paper's reference parameters are \(m = 0.5\) kg, \(L = 10\) m, \(a = 4\) m, \(k = 5\) N/m, \(g = 9.81\) m/s². This gives
The period of 3.91 s matches the paper's first plot (released from \(\theta_0 = 1^\circ\)).
Simulation results from the paper
Reference response
\(\theta_0 = \pi/180\) (1°), released from rest. Undamped oscillation with constant amplitude 0.0175 rad and period ≈ 3.9 s.
Changing m, L, a, k
One parameter changed at a time: \(m\) 0.5→4 kg, \(L\) 10→20 m, \(a\) 4→8 m, \(k\) 5→10 N/m. Only the frequency changes; the amplitude stays equal to the initial angle.
Large initial angle
\(\theta_0 = \pi/4\) (45°) versus 1°. A larger initial angle gives a larger amplitude. The paper's plot also shows a shorter period (≈ 3.1 s) at 45°, a nonlinear effect discussed in section 8.
The paper also compares the nonlinear and linear models for \(\theta_0 = 1^\circ\). The curves are indistinguishable at normal scale, and a strong zoom near \(t\approx6.7\) s is needed to see a time shift of about half a millisecond. It concludes that the approximation error is negligible for small angles. It finally writes the linear model in the form of a second-order inertial block \(T^2\ddot x + 2\xi T\dot x + x = Ku\). There is no \(\dot\theta\) term, so \(\xi = 0\) and the oscillation is undamped.
Critical review
The stated parameter trends contradict the equation
The paper concludes that increasing \(m\), \(L\) or \(a\) increases the frequency, and that increasing \(k\) decreases it. From \(\omega_0^2 = g/L + ka^2/(mL^2)\):
| Change | Period T₀ (from the formula) | Frequency | Paper says |
|---|---|---|---|
| reference | 3.91 s | – | – |
| m: 0.5 → 4 kg | 5.78 s | decreases | increases ✗ |
| L: 10 → 20 m | 6.66 s | decreases | increases ✗ |
| a: 4 → 8 m | 2.31 s | increases | increases ✓ |
| k: 5 → 10 N/m | 3.07 s | increases | decreases ✗ |
In the paper's plots for \(m\) and \(k\), the curve labeled with the changed value has the reference period of 3.9 s, and the other curve has the period predicted for the changed value (5.8 s for \(m=4\), 3.1 s for \(k=10\)). The legend entries appear to be swapped, which led to the wrong conclusions. Intuitively: a heavier mass or a longer rod makes the pendulum slower, and a stiffer spring makes it faster.
Amplitude affects the period in the nonlinear model
The paper states that the amplitude depends only on the initial angle and that the parameters affect only the frequency. This is exact for the linear model. In the nonlinear model the period also depends on the amplitude. With \(x = a\tan\theta\) the spring torque \(ka^2\sin\theta/\cos^3\theta\) grows faster than linearly (a hardening spring), so the 45° oscillation has a period of 3.09 s instead of 3.91 s. This is visible in the paper's own 45° plot, but not commented on.
How the spring is attached matters at large angles
The problem says the spring is attached to the rod "at distance \(a\) from the support". If the attachment point is fixed on the rod, it moves on a circle of radius \(a\). The elongation of a long horizontal spring is then \(x = a\sin\theta\), and the equation becomes
This spring torque grows more slowly than linearly (softening), and at 45° the period becomes 4.38 s. Both models have the same linearization (1.17), so the distinction only matters for large angles. The simulator offers both.
Minor slips: the typos \(\omega = L\dot\theta\) and \(v = L\cdot L\dot\theta\) (section 3); (1.14) labeled \(\partial\mathcal{L}/\partial\dot\theta\) instead of \(\partial\mathcal{L}/\partial\theta\); and the total potential energy described as a "sum of kinetic energies". The units of \(k\) are not stated (N/m).
Interactive simulator
The simulator solves the equation numerically (4th-order Runge–Kutta, 2 ms step). The initial angle is entered in degrees, and plots show radians as in the paper. An optional viscous damping coefficient \(b\) adds a torque \(-b\dot\theta\), so you can see what the paper's last remark about real, damped systems looks like.
Cases
System parameters
Initial conditions
Parameter comparison
The defaults are the paper's values: m = 4, L = 20, a = 8, k = 10.
Results table (every 0.1 s)
Review questions
Why does the system have only one degree of freedom?
The rod is rigid and pivoted at a fixed point, so the mass and the spring end are fully determined by the angle \(\theta\). The spring adds no freedom because of the constraint \(x = e\).
What does the small-angle frequency \(\omega_0^2 = g/L + ka^2/(mL^2)\) tell us?
Gravity and the spring act in parallel as restoring stiffnesses about the pivot: \(mgL\) and \(ka^2\). Both are divided by the moment of inertia \(mL^2\). A heavier mass or a longer rod lowers the frequency; a stiffer spring or a lower attachment point (larger \(a\)) raises it.
Why does the period at 45° differ from the small-angle period?
The restoring torque is no longer proportional to \(\theta\). With \(x = a\tan\theta\) it grows faster (hardening), so the period gets shorter. With \(x = a\sin\theta\), and from gravity's \(\sin\theta\), it grows slower (softening), so the period gets longer.
What does the variational indicator add to the Lagrangian derivation?
It is an independent route from the same energies to the equation of motion, via Hamilton's principle with integration by parts. Getting the same result is a consistency check on the derivatives.
How do you write the linear model as a second-order inertial block?
Divide (1.17) by \(mgL + ka^2\): \(T^2\ddot\theta + \theta = 0\) with \(T = 1/\omega_0\) and \(\xi = 0\). With damping \(b\), the term \(b\dot\theta\) gives \(\xi = b/(2mL^2\omega_0)\).
How could you have caught the wrong parameter trends without a simulation?
From the formula for \(\omega_0\), or from dimensional and physical intuition: a heavier mass is harder to accelerate, so it oscillates more slowly, and a stiffer spring pulls back harder, so it oscillates faster. Checking a plot against such a simple prediction is a good habit, and it also catches swapped legends.