# Problem in getting correct coefficients of frictional forces in the Lagrangian equation

I am getting correct equations on using the Lagrangian method in Systems with no non conservative forces, but when I use it in Systems with friction, sometimes I get correct equations, and sometimes I do not. Most of the equations have some problem with the coefficients of the frictional forces.
For example, let us take a look at this system........

Here $f_1,f_2$ are the frictional forces(and not the coefficients of friction)

Now, let the bolock with mass $m_2$ move through a distance $x$ to ward the right.

now, when we apply Newton's second law, we see that this is wrong and the coefficient of $f_1$ should have been $2$.
Why is the problem?....on the right hand side I have written the generalized force and the the two Lagrangian terms on the left hand side. Please help me out.

(Please do not down vote or close my question.....if there is a problem, please put a comment)

EDIT(Someone told me to add this):

Let $a$ be the acceleration of $m_2$ towards right. So we get the equations
$$m_1 g-T-f_1=2m_1a$$ and $$2T-f_2=m_2a$$ from FBDs for blocks with masses $m_1$ and $m_2$ respectively.
From here, we get
$$a=\frac{2m_1g-2f_1-f_2}{4m_1+m_2}$$

• @sammygerbil how can this question be interpreted as a homework question? The System that I gave here was just an example. I am getting incorrect coefficients of frictional forces and my question was how can I get rid of this problem. This question does not deal with a single problem taken from a book, then how can you remove a very important tag-"Classical Mechanics" and add the homework and exercises tag? – SeaDog Apr 11 '18 at 14:48
• @sammygerbil Now I think I have made myself clear. – SeaDog Apr 11 '18 at 15:13
• The tag reads homework-and-EXERCISES. Your question is an exercise. Newtonian Mechanics is a sub-topic of Classical Mechanics, so the latter tag is superfluous. A maximum of 5 tags is allowed, so 1 had to be removed for the homework-and-exercises tag. – sammy gerbil Apr 11 '18 at 18:06

Your solution using Newton's 2nd Law is correct. Your mistake is incorrectly writing the generalised force corresponding to $f_1$.
$$Q_j = \sum\limits_{i=1}^N F_i \bullet (\frac{\partial r_i}{\partial q_j})$$
$F_i \bullet \delta r_i$ is the work done during a change $\delta q_j$ in the co-ordinate $q_j$. Here $r_1, r_2$ are the displacements of $m_1, m_2$. You have defined $q_j=r_2=x$ so $r_1=2x$. The missing coefficient of 2 in the Lagrange Equation follows from this.