feos.dft.PhaseEquilibrium.tp_flash¶
- static PhaseEquilibrium.tp_flash(eos, temperature, pressure, feed, initial_state=None, max_iter=None, tol=None, verbosity=None, non_volatile_components=None)¶
Create a liquid and vapor state in equilibrium for given temperature, pressure and feed composition.
Can also be used to calculate liquid liquid phase separation.
- Parameters:
eos (EquationOfState) – The equation of state.
temperature (SINumber) – The system temperature.
pressure (SINumber) – The system pressure.
feed (SIArray1) – Feed composition (units of amount of substance).
initial_state (PhaseEquilibrium, optional) – A phase equilibrium used as initial guess. Can speed up convergence.
max_iter (int, optional) – The maximum number of iterations.
tol (float, optional) – The solution tolerance.
verbosity (Verbosity, optional) – The verbosity.
- Return type:
- Raises:
RuntimeError – When pressure iteration fails or no phase equilibrium is found.