Variational methods in general relativity refers to various mathematical techniques that employ the use of variational calculus in Einstein 's theory of general relativity. The most commonly used tools are Lagrangians and Hamiltonians and are used to derive the Einstein field equations.