In mechanics, we obtain the equations of motion (Euler-Lagrange equations) via Hamilton's principle by considering stationary points of the action $$ S = \int_{t_i}^{t_f} L ~ dt $$ where we have $L=T-V$, the difference between kinetic and potential energy. The usual derivation sets the first variation to zero and integrates by parts, to yield the requirement $$ \delta S = \int_{t_i}^{t_f} \left[ \frac{\partial L}{\partial q} - \frac{d}{dt}\left( \frac{\partial L}{\partial \dot{q}} \right) \right] \delta q ~ dt + \frac{\partial L}{\partial \dot{q}}(t_f) ~ \delta q (t_f) - \frac{\partial L}{\partial \dot{q}}(t_i) ~ \delta q (t_i) = 0 $$ where $q$ denotes the generalised coordinates and $\dot{q}$ the corresponding velocities.
At this point, most textbook derivations eliminate the second and third terms by claiming $\delta q (t_i) = 0$ and $\delta q (t_f)=0$. The first of these is intuitive, because in practice we normally consider initial value problems in which the initial positions are known. But, a priori, we don't typically know $q (t_f)$ for an arbitrary time $t_f$, so why do we set $\delta q (t_f)=0$?
For some other variational principles, it is intuitive to assume the coordinates at both endpoints are known and fixed, for example Fermat's principle to work out the path of a light ray between two points. Is there an intuitive explanation of why the final coordinates are considered fixed when applying Hamilton's principle, or a derivation of the mechanical Euler-Lagrange equations without this assumption?
In considering the problem myself, I tried to obtain the same conditions in another way: if we instead take the final position $q (t_f)$ as free but with $t_f$ fixed, then, in addition to the Euler-Lagrange equation, we get the extra requirement for stationarity $$\frac{\partial L}{\partial \dot{q}}(t_f) = 0$$ but it seems that this does not hold in general. If we consider a harmonic oscillator, for example, this condition implies that the kinetic energy is minimised at the (arbitrary) fixed time $t_f$. I haven't yet considered the necessary conditions if we also consider $t_f$ as free, as I'm not totally sure of how to carry out the analysis without incorporating elements from optimal control theory (e.g. Pontryagin's principle or the HJB equation).
Do you have a reference or some justification for 2. ? My original thinking was that perhaps a variational formulation is possible for an IVP by allowing the final time to be free or infinite.
– JayMFleming Apr 19 '18 at 12:42