Thermodynamic basis of the principle of least action | doi.page