It is remarkable that Cartan's magic formula leads to a dynamic realization of the first law of thermodynamics.
L(V)A = W + dU = Q
From classical thermodynamics, a process is irreversible if the heat 1-form Q
does not admit an integrating factor.
But Q does not admit an integration factor id Q^dQ <>0.
Hence, given a physical system A, just solve for those processes V such that Q^dQ <> 0 and you know that the process is thermodynamically irreversible.
In the download below, details are given. It would appear that irreversibility
is an artifact of 4 dimensions or more.