Variational principles for relativistic smoothed particle hydrodynamics | Synapse