Entropy-based relativistic smoothed particle hydrodynamics