function dtofpsdt3
import ThermoSysPro;
extends Modelica.Icons.Function;
input Units.SI.Pressure p "pressure";
input Units.SI.SpecificEntropy s "specific entropy";
input Units.SI.Density dguess "guess density, e.g. from adjacent volume";
input Units.SI.Temperature Tguess "guess temperature, e.g. from adjacent volume";
input Units.SI.Pressure delp "iteration accuracy";
input Units.SI.SpecificEntropy dels "iteration accuracy";
output Units.SI.Density d "density";
output Units.SI.Temperature T "temperature (K)";
output Integer error "error flag: iteration failed if different from 0";
end dtofpsdt3;