Hello I am new to Lagrange's dynamics and have some doubts regarding derivation of equation of motion given in a text :
Deriving Equation of motion for a free body(no-external forces) ,in one dimension
$L=T-V=(1/2)m \dot q^2(Since V=0)$
Euler-Lagrange equation :
$\frac{\partial L}{\partial q}-\frac{d}{dt}(\frac{\partial L}{\partial \dot q})=0$
$\frac{\partial (\frac{1}{2}m \dot q^2)}{\partial q}-\frac{d}{dt}(\frac{\partial (\frac{1}{2}m \dot q^2)}{\partial \dot q})=0$
Now in the text it was given that $\frac{\partial (\frac{1}{2}m \dot q^2)}{q}=0$. Therefore
$\frac{d}{dt}(\frac{\partial (\frac{1}{2}m \dot q^2)}{\partial \dot q})=0$
$\frac{d}{dt}(m \dot q)=0$
Therefore
$m \ddot q=0\;\;$. Which is the euqation of motion.
What I want to know is how $\frac{\partial (\frac{1}{2}m \dot q^2)}{q}=0$. Are the variables $q,\dot q$ in a Lagrange always independent or is it just in this one case . So that basic question is weather in a Lagrange are the variables $q,\dot q$ always independent and just when there is no external force is $\frac{\partial (\frac{1}{2}m \dot q^2)}{q}$ always zero.