Consider a pendulum with a variable string length $l=f(\theta)$. The Lagrangian is:

$L = \frac{m}{2}(\dot{l} ^ 2 + l^2 \dot{\theta} ^ 2) + mgl\cos\theta$.

Using Lagrange multipliers for the holonomic constraint $l = f(\theta)$ we get an expanded Lagrangian $L\rightarrow L + \lambda (l - f(\theta))$ and equations of motion

$l$: $\frac{d}{dt}(m\dot{l}) - ml\dot{\theta}^2 - mg\cos\theta - \lambda = 0$

$\theta$: $\frac{d}{dt}(ml^2\dot{\theta}) + mgl\sin\theta + \lambda f'(\theta)= 0$

$\lambda$: $l - f(\theta) = 0$

However, if I try to obtain the equations of motion with a Newtonian formulation (polar coordinates with polar axis pointing down along gravity), I get

$l$: $\frac{d}{dt}(m\dot{l}) - ml\dot{\theta}^2 - mg\cos\theta - T = 0$

$\theta$: $\frac{d}{dt}(ml^2\dot{\theta}) + mgl\sin\theta= 0$

where $T$ is the tension on the pendulum string. Clearly, the tension should be identified with the Lagrange multiplier $\lambda$ from the Lagrangian formulation. However, there is a term missing in Newton's $\theta$ equation and I fail to see what force this arises from.


2 Answers 2


there is a term missing in Newton's 𝜃 equation and I fail to see what force this arises from

Your Lagrangian analysis is correct.

In the Newtonian analysis you made the assumption that the force on the mass from the variable length rod is purely in the $\hat r$ direction. The Lagrangian analysis did not make that assumption. The additional term gives the force from the rod in the $\hat \theta$ direction, so your Newtonian analysis is only valid when this term is 0.

  • $\begingroup$ Thanks for taking time to think about this. Yes, I was trying to consider a situation like the one you mention. I don't see physically why the rod would exert a non-radial force. Also, the Lagrangian formulation suggests that this non-radial force is of a very particular form: proportional to the tension T that acts radially and from a Newtonian perspective I don't quite see why this is so. $\endgroup$
    – lmyt
    Apr 9 at 16:26

there is a term missing in Newton's 𝜃 equation and I fail to see what force this arises from

your Newton equations should be

$l$: $\frac{d}{dt}(m\dot{l}) - ml\dot{\theta}^2 - mg\cos\theta - T_l = 0$

$\theta$: $\frac{d}{dt}(ml^2\dot{\theta}) + mgl\sin\theta-T_\theta= 0$

and additional the constraint equation


with \begin{align*} &\dot z=\dot l-f'(\theta)\dot\theta=\underbrace{\begin{bmatrix} 1 & f'(\theta) \\ \end{bmatrix}}_{\mathbf{C}_B}\,\begin{bmatrix} \dot{l} \\ \dot{\theta} \\ \end{bmatrix}=0 \end{align*}

from the theory the constraint forces $~T_l~,T_\theta~$ transformed to generalized constraint forces with this equation

\begin{align*} & \begin{bmatrix} T_l \\ T_\theta \\ \end{bmatrix}=\mathbf{C}_B^T\,\lambda=\begin{bmatrix} 1 \\ f'(\theta) \\ \end{bmatrix}\,\lambda \end{align*}

where $~\lambda~$ is the generalized constraint force

so you obtain the correct results

why $~\mathbf C_B^T$

Pendulum equation of motion with Newton approach

you start with the free body diagram

\begin{align*} &m\,\frac{d}{dt}{\begin{bmatrix} \dot{x} \\ \dot{y} \\ \end{bmatrix}}={\begin{bmatrix} 0 \\ -m\,g \\ \end{bmatrix}}+ {\begin{bmatrix} F_x \\ F_y \\ \end{bmatrix}}\tag 1 \end{align*}

and the constraint equation \begin{align*} &z=\frac{1}{2}\left(x^2+y^2-l^2\right)=0\quad\Rightarrow\quad \dot{z}=\underbrace{\begin{bmatrix} x & y \\ \end{bmatrix}}_{\mathbf{C}_B} \begin{bmatrix} \dot{x} \\ \dot{y} \\ \end{bmatrix}=0 \end{align*} where $~F_x~,F_y~$ are the constraint forces at the pivot

thus with (Ansatz) \begin{align*} &{\begin{bmatrix} F_x \\ F_y \\ \end{bmatrix}}=\mathbf{C}^T_B\lambda \end{align*} equation (1) map to

\begin{align*} &m\,\frac{d}{dt}{\begin{bmatrix} \dot{x} \\ \dot{y} \\ \end{bmatrix}}={\begin{bmatrix} 0 \\ -m\,g \\ \end{bmatrix}} +\begin{bmatrix} x \\ y \\ \end{bmatrix}\lambda \tag 2 \end{align*}

if you choose now for example the generalized coordinate $~x~$, you obtain from the constraint equation that $~y=\sqrt{l^2-x^2}~$ thus equation (2)

\begin{align*} &m\,\frac{d}{dt}\underbrace{\left[ \begin {array}{c} 1\\ -{\frac {x}{\sqrt {{l} ^{2}-{x}^{2}}}}\end {array} \right]}_{\mathbf{J}} \dot{x}={\begin{bmatrix} 0 \\ -m\,g \\ \end{bmatrix}} +\underbrace{\begin{bmatrix} x \\ \sqrt{l^2-x^2} \\ \end{bmatrix}}_{\mathbf{C}^T_B}\lambda \tag 3 \end{align*}

to eliminate the $~\lambda~$ from the equation (3), you multiply from the left equation (3) with $~\mathbf{J}^T~$ (d'Alambert Prinzip)

\begin{align*} &\mathbf{J}^T\,\mathbf{C}^T_B=\left[ \begin {array}{cc} 1&-{\frac {x}{\sqrt {{l}^{2}-{x}^{2}}}} \end {array} \right] \,\begin{bmatrix} x \\ \sqrt{l^2-x^2} \\ \end{bmatrix}=0~\surd \end{align*}

the equation of motion with for the generalized coordinate $~x~$ is now

\begin{align*} & m\,\mathbf{J}^T\,\frac{d}{dt}\left(\,\mathbf{J}\,\dot{x}\right)=\mathbf{J}^T\,\begin{bmatrix} 0 \\ -m\,g \\ \end{bmatrix} \end{align*}

of course you can use equation (2) and the constraint equation $ ~z$

  • $\begingroup$ Thanks, Eli. Can you recommend a reference for the transformation $C^\top$ \lambda$? $\endgroup$
    – lmyt
    Apr 9 at 21:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.