# Derivation of Lagrange Equations from Newton's Second Law for a Non-holonomic System of Particles

I am interested to write down a derivation of Lagrange equations from Newton's second law for a non-holonomic system of particles. Here, I mention my derivation where I am stuck right at the last step.

Consider a system of $N$ particles where their position vectors are written as

$$\mathbf{r}_i=\mathscr{R}_i(q_1(t),\dots,q_M(t),t),\quad i=1,\dots,N\,,\tag{1}$$

where the functions $q_i:\mathbb{R}\to\mathbb{R}$ are called the generalized coordinates which are subjected to holonomic and non-holonomic constraints as below

where $C_h$ and $C_n$ are the number of holonomic and non-holonomic constraints, respectively. Also, if the degree of freedom of the system is $n$ then $n=M-C\ge1$ where $C=C_n+C_h$ is the total number of constraints. Using the chain rule of differentiation we have

\begin{align*} \mathscr{\dot R}_i := \mathbf{v}_i &= \mathbf{v}^*_i+\frac{\partial\mathscr{R}_i}{\partial t},\quad i=1,\dots,N\,, \\ \mathbf{v}^*_i&:=\sum_{j=1}^{M}\frac{\partial \mathscr{R}_i}{\partial q_j}\dot q_j\,,\tag{3} \end{align*}

where we defined the virtual velocity of a particle by $\mathbf{v}^*_i$. Also, from Newton's second law we have

$$\mathbf{F}_i=m \mathbf{a}_i\tag{4},\quad i=1,\dots,N\,.$$

Multiplying both sides of $(4)$ by $\mathbf{v}^*_i$, summing over the number of particles $N$ and interchanging the the order of summations we get

$$\sum_{j=1}^{M}\sum_{i=1}^{N}(\mathbf{F}_i-m\mathbf{a}_i)\cdot\frac{\partial \mathscr{R}_i}{\partial q_j}\dot q_j=0\,.\tag{5}$$

Then using the following definitions and identities

\begin{align*} Q_j&:=\sum_{i=1}^{N}\mathbf{F}_i\cdot\frac{\partial \mathscr{R}_i}{\partial q_j},\quad j=1,\dots,M\,, \\ S_j&:=\sum_{i=1}^{N}m\mathbf{a}_i\cdot\frac{\partial \mathscr{R}_i}{\partial q_j}=\frac{d}{dt}\frac{\partial T}{\partial \dot q_j}-\frac{\partial T}{\partial q_j},\quad j=1,\dots,M\,, \\ T&:=\sum_{i=1}^{N}\frac{1}{2}m\mathbf{v}_i\cdot\mathbf{v}_i\,, \tag{6} \end{align*}

Eq. $(5)$ reduces to

$$\sum_{j=1}^{M}(Q_j-S_j)\dot q_j=0.\tag{7}$$

If there were no constraint equations at all, either holonomic or non-holonomic as mentioned in Eq.$(2)$, then the functions $q_i$ were linearly independent and from this we could conclude that the functions $\dot q_i$ are also linearly independent. Then Eq.$(7)$ would result in the well known form of Lagrange equations $S_j=Q_j$. But here is my question, what if there are constraint equations like Eq.$(2)$. Note that sometimes we are inclined not to eliminate the holomonic constraints by using a transformation. So I am insisting to have both holonomic and non-holonomic constraints at the same time.

As the functions $\dot q_i$ are not (linearly) independent in this case, I am wondering that how the last step works here?

If the non-holonomic constraints are linear in terms of generalized velocities

\begin{align*} &g_i(q_1(t),\dots,q_M(t),\dot q_1(t),\dots,\dot q_M(t),t)=\\ &\sum_{j=1}^{M}a_{ij}(q_1(t),\dots,q_M(t),t)\dot q_j(t)+b_i(q_1(t),\dots,q_M(t),t)=0,\quad \tag{8} \end{align*}

then we call them quasi non-holonomic. In this case, I know that the final result should be

$$\frac{d}{dt}\frac{\partial T}{\partial \dot q_j}-\frac{\partial T}{\partial q_j}=Q_j+\sum_{i=1}^{C_h}\lambda_i\frac{\partial f_i}{\partial q_j}+\sum_{i=1}^{C_n}\mu_i\frac{\partial g_i}{\partial \dot q_j},\quad j=1,\dots,M\,,\tag{9}$$

where $\lambda_i$ and $\mu_i$ are some functions of time which are called Lagrange multipliers.

A simple observation is that every holonomic constraint can be written in the form of a quasi non-holonomic constraint, that is

\begin{align*} &\\ &\sum_{j=1}^{M}\frac{\partial f_i}{\partial q_j}(q_1(t),\dots,q_M(t),t)\dot q_j(t)+\frac{\partial f_i}{\partial t}(q_1(t),\dots,q_M(t),t)=0.\quad \tag{10} \end{align*}

At the first step, it seems reasonable to establish an argument when all of the constraints are quasi non-holonomic. I have posted a related mathematical question on Mathematics SE in this regard. Interested reader can take a look at it.

• You don't get the constraints back when you take the partial derivative wrt the lagrange multipliers ...? Why is what you wrote the correct equation? – Emil Aug 9 '17 at 21:41
• @Emil: I didn't get you sorry! :) I haven't heard such a thing ever. Anyway, I am sure that the final answer is true. See e.g. equations (2.23) and (2.27) of Goldstein on pages 46 and 47. – H. R. Aug 9 '17 at 21:50
• Goldstein uses variational calculus to take in account the non-holonomic constraints, aren't you missing the equivalent to the Euler-Lagrange equations applied to the equations (2) in your final result? Because that's the trick. – David Leonardo Ramos Aug 10 '17 at 14:36
• @DavidLeonardoRamos: Thanks for the attention. :) Here, I don't want to use variational calculus but I want to derive the result directly from Newton's second law. :) I didn't get your last comment about the "trick". – H. R. Aug 10 '17 at 14:39
• Literally adding the Euler-Lagrange equations for each constrain you have in equation (2) (or at least the non-holonomic) times its correspondent Lagrange multiplier (supposing the Lagrange multiplier itself doesn't change with time). Check equation (2.25) of Goldstein's third edition. – David Leonardo Ramos Aug 10 '17 at 14:54

The full question (v13) is rather broad, but here are some comments/feedback:

1. Traditionally virtual displacements are frozen in time $t$. The $t$-differentiations in eqs. (3) & (5) are misleading at best (depending on what the notation $t$ is supposed to represent).

2. Eq. (4) is Newton's 2nd law if ${\bf F}_i$ denotes the total force on the $i$th point particle, i.e. a sum of "applied" and constraint forces. One of the main points is to try to eliminate the constraint forces from the formalism, at least for the holonomic constraints. OP seems to have made no progress in this.

3. It should be noted that a $\partial g / \partial \dot q_j$-term in OP's final eq. (8) is not appropriate for a general non-holonomic constraint $g$, but only for a so-called semi-holonomic constraint, $$g(q,\dot{q},t)~\equiv~\sum_j a_j(q,t)\dot{q}^j+a_t(q,t)~\approx~0,$$ which by definition is an affine function of $\dot{q}^j$.

4. In case OP is following Ref. 1, note that the treatment of Lagrange equations for non-holonomic constraints in Ref. 1 is inconsistent with Newton's laws, and has been retracted on the errata homepage for Ref. 1. See Ref. 2 for details.

5. In case OP is following Ref. 3, note that Ref. 3 only deals with holonomic constraints in Chapter 2. (This is explicitly mentioned on the middle of p. 50.) Ref. 3 tentatively introduces non-holonomic constraints in the beginning of Section 3.1.2, only to later rejects the approach as unphysical.

References:

1. H. Goldstein, Classical Mechanics; 3rd ed; Section 2.4. Errata homepage. (Note that this criticism only concerns the treatment in the 3rd edition; the results in the 2nd edition are correct.)

2. M.R. Flannery, The enigma of nonholonomic constraints, Am. J. Phys. 73 (2005) 265.

3. J.V. Jose & E.J. Saletan, Classical Dynamics: A Contemporary Approach, 1998; Sections 2.1.1, 2.2.1 & 3.1.2.

• According to page 47, eq. (2.24) and the paragraph above it, semi-holonomic constraints have the form $g(q_1(t),\dots,q_M(t),\dot q_1(t),\dots,\dot q_M(t),t)=0$. The form you mentioned is usually referred to as restricted form or Pfaffian form. – H. R. Sep 12 '17 at 11:53
• Not all constraints of the form $g(q,\dot{q},t) \approx 0$ are semi-holonomic. (Be aware that Section 2.4 of the 3rd edition of Goldstein is wrong/not very lucid.) – Qmechanic Sep 12 '17 at 12:05
• This work of M.R. Flannery can also be of interest. – H. R. Sep 13 '17 at 10:41
• About Eqs. (3) and (5), I think the traditional approach is totally ambiguous while this one has a clear mathematical meaning! Here I have not used anything such as virtual displacement but I introduced something called virtual velocity which appear so naturally while computing the velocity for each particle. – H. R. Sep 14 '17 at 5:15

The problem is that you can't rearrange the formulae defining momenta to express the $\dot{q}_i$ in terms of them and the $q_j$, because of phase space constraints of the form $f(q,\,p)=0$. The trick is to identify these functions and add multiples of them to the Hamiltonian, viz. https://en.wikipedia.org/wiki/Dirac_bracket

• Thanks for the attention. :) Sorry but I didn't get you. Did I say anything about the Hamiltonian in the question? Also, another question, why the trick you mentioned should work? I am looking for the reasons in the background. ;) – H. R. Aug 9 '17 at 12:15

Backwards, and with boring rectilinear coordinates:

$$\begin{eqnarray}\frac{\partial \mathcal L}{\partial x_i} &=& \frac{d}{dt} \frac{\partial \mathcal L}{\partial \dot x_i} \\ \mathcal L = T - U &=& \frac{m}{2} \sum_i \dot x_i^2- \int_C \mathbf F \cdot d \mathbf x \\ \frac{\partial \mathcal L}{d x_i} = - \frac{\partial U}{\partial x_i} = - \frac{\partial}{\partial x_i} \int_C \mathbf F \cdot d\mathbf x &=& \frac{d}{dt} \frac{\partial \mathcal L}{\partial \dot x_i} = \frac{d}{dt} \frac{\partial T}{\partial \dot x_i} = \frac{d}{dt} m \dot x_i \\ \mathbf F &=& m \mathbf{\ddot x} \end{eqnarray}$$

If you're so inclined, the forwards derivation flows the opposite direction and the least intuitive steps are from $m \mathbf{\ddot x}$ back to the derivatives of $T$ term, but all the steps are valid.

Generalized coordinates are formally equivalent to rectilinear coordinates even if quirky terms like effective potentials arise (when the kinetic energy has derivatives with respect to position in addition to velocities). If you want to be explicit about it, Wikipedia does a good job.

It sounds like you're also looking for information about non-conservative systems. Please examine this link. It also sounds like you're curious about the constraints, see here.

After a while, I noticed that I have thought so badly due to the bad books that I have read and bad explanation that I have been given.

Let me start by deriving the Lagrange equations for the motion of a single particle. First choose a set of generalized coordinates. For example, consider a particle moving on a spherical surface whose radius is varing with time. You can choose the generalized coordinates to be just the usual Cartesian coordinates $(x,y,z)$ subjected to the holonomic constraint $$f(x(t),y(t),z(t),t)=x(t)^2+y(t)^2+z(t)^2-R^2(t)=0,$$ where $R(t)$ is the radius of sphere. Another way is to choose the spherical coordinates $(r,\theta,\phi)$ as the generalized coordinates \begin{align*} x&=r\sin\theta\cos\phi \\ y&=r\sin\theta\sin\phi \\ z&=r\cos\theta \tag{1} \end{align*} subjected to the constraint $r=R(t)$, or we may just choose $(\theta,\phi)$ as the generalized coordinates with $r$ being replaced by $R(t)$ in $(1)$. You can also choose cylindrical coordinates $(\rho,\phi,z)$ as the generalized coordinates subjected to the constraint $\rho^2+z^2=R^2(t)$. These were just simple examples of what the equation $$\mathbf{r}=\mathscr{R}(q_1(t),\dots,q_M(t),t), \tag{2}$$ means. It is wise to pick that number of generalized coordinates which does not exceed the maximum degree of freedom that the particle can have so $M\le3$. Note, that we do not care about the fact that system is constrained or not when we choose our generalized coordinates. After choosing the generalized coordinates, we seek what the governing constraints are. It is natural to choose those generalized coordinates, which make our description of motion and the solution of the problem easy. That's all.

Now, write down the Newton's second law for the particle and multiply both sides with the vector $\frac{\partial \mathscr{R}}{\partial q_j}$ to obtain

$$(\mathbf{F}-m\mathbf{a})\cdot \frac{\partial \mathscr{R}}{\partial q_j}=0\,.\tag{3}$$

Using the definitions and identities mentioned in Eq.$(6)$ of the above question this simply turns out to be

$$Q_j-S_j=0.\tag{4}$$

But, there is still an important question. How many linearly independent equations do we get!? A close look at $(3)$ reveals that this depends on how many linearly independent vectors $\frac{\partial \mathscr{R}}{\partial q_j}$ we have. This serves as a motivation to require that the generalized coordinated be chosen such that all of the vectors $\frac{\partial \mathscr{R}}{\partial q_j}$ be linearly independent. In the aforementioned example of the moving particle over sphere, if we choose spherical coordinates then these vectors are simply parallel to basis vectors of spherical coordinates, which are indeed linearly independent. Keeping this in mind, we shall get $M$ linearly independent equations.

Note that our discussion never depends on whether the motion is constrained or not. It is just another story. The corresponding forces of kinematical constraints show them-selves in $Q_j$. For the case of holonomic constraints, one can show that if a set of generalized coordinates is chosen such that the holonomic constraint is satisfied identically then the contribution of its corresponding forces to $Q_j$ vanishes. This corresponds to our choice $(\theta,\phi)$ in the above example. In conclusion, depending on the choice of generalized coordinates, the corresponding constraint forces may or may not enter the Lagrange equations.

With slight modifications of the procedure in the above question, you can derive the Lagrange's equations for a system of particles. At the first step you get $$\sum_{i=1}^{N}(\mathbf{F}_i-m\mathbf{a}_i)\cdot\frac{\partial \mathscr{R}_i}{\partial q_j}=0,$$ which is again equivalent to $Q_j-S_j=0$. Note that no summation on $j$ is really needed! The tricky point is to understand that how many linearly independent equations you are left with, which I leave as an exercise for you.

Note that this method tells us that Lagrange's equations are just well-chosen linear combinations of the original equations of motion obtained by Newton's second law and nothing more! It is well-chosen as it eliminates some forces which we are not interested to know about.

Here is a nice reference which I strongly recommend for interested readers.

Classical Dynamics: A Contemporary Approach By Jorge V. José and‎ Eugene J. Saletan.

Disclaimer. These were my understanding of the subject and it may contain some mistakes. So, I would appreciate any helpful and detailed criticism.

• This answer (v2) seems to conflate virtual displacements and $t$-differentiation. – Qmechanic Nov 25 '17 at 11:39
• @Qmechanic: Take a look at chapter two and specifically section 2.2 and the equation above Eq. (2.21). – H. R. Nov 25 '17 at 11:47
• @Qmechanic: Also, see equation E of the answer to this post by Valter Moretti and the explanations below that. – H. R. Nov 25 '17 at 12:01
• $\uparrow$ The mentioned links in above 2 comments only deals with holononic constraints. – Qmechanic Mar 26 '18 at 14:39
• @Qmechanic: This method has nothing to do with the type of constraints. You have just stuck in your old point of view. – H. R. Mar 27 '18 at 17:01