Lagrangian mechanics and time derivative on general coordinates I am reading a book on analytical mechanics on Lagrangian. I get a bit idea on the method: we can use any coordinates and write down the kinetic energy $T$ and potential $V$ in terms of the general coordinates, so the Lagrangian is given as $L=T-U$. For one example, let says the Lagrangian is 
$$
  L = \frac{m}{2}\dot{x}^2 + mb\dot{\phi}\dot{x}\cos\phi
$$
here $m$ is the mass, $b$ is constant, $x$ and $\phi$ are the general coordinates. As told in the text, to write the equation of motion, we have to calculate $\partial L / \partial x$. My question is: if we plug in the $L$ and calculate the derivative of $x$ on $L$, should we got zero? i.e. 
$$
  \frac{\partial\dot{x}^2}{\partial x} = 0 ?
$$
if it is not zero, what is that? and what's the physical significance of $\frac{\partial\dot{x}}{\partial x}$ ?
 A: Your confusion really just comes down to understanding the notation that is widely used for partial derivatives.
For simplicity, I'll restrict the discussion to a system with one coordinate degree of freedom $x$.  In this case, the Lagrangian is a real valued function of two real variables which we suggestively label by the symbols $x$ and $\dot x$.  Mathematically, we would write $L:U\to\mathbb R$ where $U\subset \mathbb R^2$.  Let's consider the simple example
$$
  L(x, \dot x) = ax^2+b\dot x^2
$$
When we write the expression
$$
  \frac{\partial L}{\partial \dot x}(x, \dot x)
$$
this is an instruction to differentiate the function $L$ with respect to its second argument (because we labeled the second argument $\dot x$) and then to evaluate the resulting function on the pair $(x, \dot x)$.  But we just as well could have written
$$
  \partial_2L(x, \dot x)
$$
To represent the same expression.  Both of these expressions simply mean that we imagine holding the first argument of the function constant, and we take the derivative of the resulting function with respect to what remains.  In the case above, this therefore means that
$$
  \frac{\partial L}{\partial\dot x}(x, \dot x) = 2b\dot x
$$
because $x$ labels the first argument, and taking a partial derivative with respect to the second argument means that we treat $x$ like a constant whose derivative is therefore $0$.  It it in this sense that the partial of $x^2$ with respect to $\dot x$ is zero.
So to recap, when we are taking these derivatives, we just keep in mind that the symbols $x$ and $\dot x$ are just labels for the different arguments of the Lagrangian.
You might ask, however, "if $x$ and $\dot x$ are just labels, then what relation do they have to position and velocity?"  The answer is that after we have treated them as labels for the arguments of $L$ in order to take the appropriate derivatives, we then evaluate the resulting expressions on a $(x(t), \dot x(t))$, the position and velocity of a curve at time $t$, to obtain equations of motion.
For example, if you take the example of $L$ that I started with, we get
$$
  \frac{\partial L}{\partial x}(x, \dot x) = 2 ax, \qquad \frac{\partial L}{\partial \dot x}(x, \dot x) = 2b\dot x
$$
now we evaluate these expressions on $(x(t), \dot x(t))$ to obtain
$$
  \frac{\partial L}{\partial x}(x(t), \dot x(t)) = 2 ax(t), \qquad \frac{\partial L}{\partial \dot x}(x(t), \dot x(t)) = 2b\dot x(t)
$$
so that the Euler-Lagrange equations become
$$
  0=\frac{d}{dt}\left[\frac{\partial L}{\partial \dot x}(x(t), \dot x(t))\right] - \frac{\partial L}{\partial x}(x(t), \dot x(t))
=\frac{d}{dt}(2b\dot x(t)) - 2ax(t)
$$
which gives
$$
  b\ddot x(t) = a x(t)
$$
Once you understand all of this, you can (and should) dispense with the long-winded notation I used here for illustrative purposes, and you should make no error in using the abbreviated notation in your original post.
A: This is a somewhat unintuitive step in the Lagrangian formalism and the Euler-Lagrange equations. Note that you are taking the partial derivative of the Lagrangian with respect to some coordinate. Strictly speaking, when you take a partial derivative you should specify what you are holding constant.
Although we usually think of a coordinate and its time derivative as being related, when applying the Euler-Lagrange formalism we vary the generalized coordinates and velocities independently. This means that $$\frac{\partial \dot q}{\partial q} = 0, \ \ \frac{\partial q}{\partial \dot q} =0,$$ for any generalized coordinate $q$. 
So, in your example, $\big(\frac{\partial L}{\partial x}\big)_{\dot x} = 0$, in fact. Here, I am using the parentheses to note explicitly that $\dot x$ is held constant.
A: I'll just add a general comment on the confusion regarding independent variables.
A Lagrangian is a function of two sets of independent variables - generalized coordinates and generalized velocities. When the solution (i.e., the motion) is given under a given set of initial conditions, of course, a relation is established between them - the generalized velocity is known when the generalized coordinate is given. But that does not mean these two are not independent variables. They are as independent as two independent variables $x,y$ satisfying a pair of linear simultaneous equations. When you look at one of the equations, of course, you express $x$ as a function of $y$, but that doesn't mean that $x$ and $y$ are not independent variables. Similarly, when you solve them you know the numerical values for both $x$ and $y$, that doesn't mean $x$ and $y$ are not variables, but numbers.
Here, in this case, $x$ and $\dot{x}$ are independent in the same sense - in principle, a particle can be at any $x$, completely independent of its velocity, and vise versa - in general, they are not dependent on each other (unlike $x$ and $x^2$, say). But of course, when we solve for them and get a motion $x(t)$,$\dot{x}(t)$ for a particular case, they become related.
A: Use the Euler-Lagrange equation of motion!  
