MaximaLabs
All guides
Triunfo, Rio Grande do Sul, Brazil

How to simulate ethanol dehydration: reactor + separator written as one custom block

Bio-ethanol to ethylene (C₂H₅OH → C₂H₄ + H₂O), the route behind bio-based polyethylene, modeled as a single user-written custom block with two named inlets and two named outlets. The ethanol vapour feed and a dilution-water feed enter on the feed and water ports; the block's own equations convert 80% of the ethanol (xi = 0.8 * (feed.n_ethanol + water.n_ethanol)), send the ethylene and 10% of the water overhead on gas, and the condensed water with the unreacted ethanol out on liquid — a reactor and its quench separator in one model, which no fixed unit op is. Each outlet is flashed through Peng-Robinson at the temperature the model sets (330 K), and the block reports its mass balance: one mole of ethanol makes two moles of product, so moles are not conserved, but mass is, to round-off (46.07 = 28.05 + 18.02 g/mol). Edit the stoichiometry so it makes twice the ethylene and the block warns that the model creates mass. Notes: the 80% conversion and the 10%/5% overhead splits are stated by the model, not computed from kinetics or vapour-liquid equilibrium — this is a custom model a user writes when they have their own correlation, and it is exactly as good as that correlation.

Ethanol
Dilution
feed
water
gas
liquid
ƒ(x)
Dehyd
Ethylene
Condensate
  1. 1
    Open the ready-made model

    Open the "Ethanol dehydration: reactor + separator written as one custom block" model in the MaximaLabs workspace — no install, no license. It loads live on the canvas, ready to edit and run.

  2. 2
    Confirm the thermodynamics

    This process is modeled with the PENG-ROBINSON property package over ethanol, ethylene, water — already selected, so the phase equilibrium and enthalpy are physically consistent from the first run.

  3. 3
    Review the flowsheet

    The flowsheet chains Dehyd. Every block is a real, solvable unit op you can reconfigure on the canvas.

  4. 4
    Run the simulation

    Click Run. The deterministic solver converges the material and energy balances (recycles included) and fills the live stream table — the AI never invents a number.

  5. 5
    Read the results and iterate

    Inspect the converged streams, tweak a spec, and re-run — or ask the AI copilot to explain a result or diagnose a failed solve in plain English.

What you'll build
Thermodynamics
PENG-ROBINSON
Components
ethanol, ethylene, water
Unit operations
Dehyd
Open this model in the workspace

Opens live on the canvas — free, no install.

Explore the model & flowsheet

Frequently asked questions

What does the Ethanol dehydration: reactor + separator written as one custom block model simulate?
Bio-ethanol to ethylene (C₂H₅OH → C₂H₄ + H₂O), the route behind bio-based polyethylene, modeled as a single user-written custom block with two named inlets and two named outlets. The ethanol vapour feed and a dilution-water feed enter on the feed and water ports; the block's own equations convert 80% of the ethanol (xi = 0.8 * (feed.n_ethanol + water.n_ethanol)), send the ethylene and 10% of the water overhead on gas, and the condensed water with the unreacted ethanol out on liquid — a reactor and its quench separator in one model, which no fixed unit op is. Each outlet is flashed through Peng-Robinson at the temperature the model sets (330 K), and the block reports its mass balance: one mole of ethanol makes two moles of product, so moles are not conserved, but mass is, to round-off (46.07 = 28.05 + 18.02 g/mol). Edit the stoichiometry so it makes twice the ethylene and the block warns that the model creates mass. Notes: the 80% conversion and the 10%/5% overhead splits are stated by the model, not computed from kinetics or vapour-liquid equilibrium — this is a custom model a user writes when they have their own correlation, and it is exactly as good as that correlation.
Which thermodynamic method does it use?
The PENG-ROBINSON property package, over ethanol, ethylene, water — already selected. You can switch the method on the canvas before running.
Which unit operations are in the flowsheet?
It chains Dehyd. Every block is a real, solvable unit operation you can reconfigure, add to, or remove.
Do I need to install software or buy a license?
No. Ethanol dehydration: reactor + separator written as one custom block runs entirely in your browser on MaximaLabs — free, no install, no license. Open the model to load it live and run the deterministic solver.

More guides like this

Distributed pipeline cool-down (indexed equation model)

A hot gas cools along a buried pipeline — modeled as a custom unit op whose internals are a distributed 1-D indexed equation system, the gPROMS-style array + indexed-equation modeling capability solved by the sandboxed equation engine. Twenty axial segments compute the full temperature profile T[0..20] (the inlet drives the boundary T[0]; each segment loses heat toward the ground temperature); the outlet temperature is the end of that profile. Demonstrates writing a distributed model as one indexed template rather than 20 hand-written equations.

Methanol synthesis reactor duty (Python Script Mode, LHHW kinetics)

A CO/H₂ syngas feed enters a custom block written in real, sandboxed Python (flowsim/sandbox/) rather than the AST-restricted equation grammar — the case equation mode structurally can't express: a Langmuir-Hinshelwood-Hougen-Watson rate law (a forward kinetic term over a competitive-adsorption denominator, each term Arrhenius/ van't-Hoff temperature-dependent) evaluated inside a real Python loop over the adsorbing species, driving the exothermic reactor's temperature rise. Partial pressures are computed from the real inlet pressure (pinned via inputs) and representative mole fractions (script_params — composition itself can't be pinned into a script, only flow/T/P, so the fractions are illustrative constants, not read from the flowsheet's actual feed). The kinetic/adsorption/heat-of-reaction constants are likewise illustrative (chosen for a physically plausible rate and duty, not fit to a specific published dataset) — the point is the execution model, not a validated methanol-synthesis kinetic scheme.

Ludwigshafen, Germany

Polymerization reactor comparison: CSTR cascade vs. tubular (PFR)

The same monomer feed, split 50/50 into two trains at equal total reactor volume: a 3-stage CSTR cascade (each stage blending its own new polymer with the MWD already carried by the stream from the stage before it) versus a single tubular (PFR) reactor. Both converge to a real, different Mn/Mw/PDI — the PFR reaches higher conversion at the same total volume, but its cumulative polydispersity is measurably broader than the cascade's, because chain length drifts continuously with conversion along the tube while each CSTR stage makes its own local production under one fixed monomer concentration. See the 'Polymerization Reactors' docs page for the full reasoning.

Amarillo, Texas, USA

Helium liquefaction (Linde-Hampson cycle)

A Joule-Thomson liquefaction loop: helium is compressed, aftercooled, precooled well below its ~40-51 K JT-inversion temperature, then throttled through a valve into a flash drum that draws off liquid helium while the cold vapor recycles back to the compressor suction — the same JT-cycle physics as the platform's LNG/refrigeration loops, run on a fluid whose inversion curve makes precooling mandatory before the throttle can cool it at all.

Brevik, Norway (Heidelberg Materials Norcem — first full-scale cement CCS)

Cement kiln calcination + CO2 liquefaction

Preheated limestone (CaCO₃) enters an indirectly-heated rotary kiln that calcines it toward CaO, releasing a CO₂-rich off-gas; the gas passes a knockout drum, then is compressed and cooled to liquefy the CO₂ for transport/storage.

Mont Belvieu NGL fractionation complex, Texas, USA

NGL fractionation: single-shell Petlyuk dividing-wall column

A natural-gas-liquids cut (ethane / propane / n-butane) split into three on-spec products by ONE thermally-coupled dividing-wall column instead of two columns in series. This uses the native Petlyuk unit op: a prefractionator whose reflux and boilup are supplied by the main column (the single condenser + single reboiler), solved by an outer Wegstein loop that converges the bidirectional vapor/liquid coupling to self-consistency — the coupling legacy sequential-modular solvers approximate with two connected columns whose recycle fails to converge.

Stop fighting legacy software. Build your first flowsheet in 60 seconds.