VLE / Flash computes vapor–liquid phase equilibrium for mixtures of up to eight components: how a feed splits between vapor and liquid, the bubble and dew points, and Txy or Pxy diagrams for binaries. For gas-phase chemical equilibrium, use Cantera instead. It runs on CPU with the open-source thermo and chemicals libraries.
How it works
It uses a gamma–phi model: an activity-coefficient model for the liquid and a cubic equation of state for the vapor.
eos:peng-robinson(default) orsrk, built from each component's critical temperature, critical pressure, and acentric factor.activity_model:unifac(default) ornrtl. NRTL uses ChemSep interaction parameters unless you supplybinary_params, fitted values of τᵢⱼ = a + b/T and α, usually from VLE Parameter Regression. Pairs you don't supply fall back to ChemSep.
mode | Needs | Finds |
|---|---|---|
tp_flash | temperature_k, pressure_pa | Phase split and compositions |
ph_flash | pressure_pa, enthalpy_j_mol | Temperature and phase split |
bubble_t / dew_t | pressure_pa | Bubble or dew temperature |
bubble_p / dew_p | temperature_k | Bubble or dew pressure |
txy | pressure_pa | Isobaric diagram for a binary |
pxy | temperature_k | Isothermal diagram for a binary |
Inputs
components: up to 8, each with anameand mole fractionz(the fractions must sum to 1). Names (or CAS numbers) are looked up in thechemicalsdatabase; for anything it doesn't know, givetc_k,pc_pa, andomegatogether. A component table can come from an earlier step, such as Group-Contribution Properties estimates.modeand the conditions it needs, from the table above.diagram_points: grid size fortxyandpxy(default 21, up to 51).binary_params(NRTL only): rows ofcomponent_i,component_j,tau_a,tau_b, andalpha, for both directions of each pair.
Outputs
| File | Contents |
|---|---|
result.json | The equilibrium result: conditions, phase fractions, and the model used |
compositions.csv | phase, component, z, x, y: the overall, liquid, and vapor compositions |
diagram.csv | The Txy or Pxy diagram (diagram modes only) |
Not covered
- Chemical equilibrium (use Cantera) and process flowsheets.
- PC-SAFT and other non-cubic equations of state.
Related tools
VLE Thermodynamic Consistency Checker to audit measured data, VLE Parameter Regression to fit NRTL parameters to it, and CoolProp for pure-fluid properties.