H2 recovery from purge gas by gas-permeation membrane — a PENG-ROBINSON process flowsheet
A real technology gap MaximaLabs had no unit op for at all: gas-phase membrane separation (the existing membrane op is liquid-phase reverse osmosis, not gas permeation). Built here as a new gas_membrane unit op — solution-diffusion transport (real textbook model), solved as the coupled fixed point it actually is (both outlet compositions depend on every component's flux, which depends on both outlet compositions) via a proper Newton-type root-find rather than naive fixed-point substitution, which was tried first and found to genuinely oscillate for a stiff permeance*area product — see the unit op's own module docstring. Demonstrates the textbook H₂-recovery application: a high-pressure purge/off-gas (H₂/CH₄/N₂, e.g. from an ammonia loop or hydroprocessing unit) crosses a polyimide-class membrane, H₂ permeating far faster than the other species.
Modeling assumptions & limitations
- 1The permeance values used are representative order-of-magnitude figures for a polyimide-class membrane's real H₂/CH₄/N₂ selectivity pattern (H₂ permeates markedly faster than either), not digits pinned to one specific cited membrane material/thickness — disclosed as representative rather than presenting invented precision, the same posture used elsewhere in MaximaLabs when an exact source isn't confidently pinnable. The single-stage recovery shown (~32% of the feed H₂, at ~96% permeate purity) is a real, honest limitation of one membrane stage — real plants cascade multiple stages for higher overall recovery, not modeled here.
202 views 1 forks
- Rigorous PENG-ROBINSON thermodynamics, solved by the same engine every simulation runs on.
- 1 unit operations modeled: Membrane.
- Focus areas: Gas membrane, H2 recovery, Solution-diffusion, Purge gas.
- Thermodynamics
- PENG-ROBINSON
- Components
- h2, methane, n2
- Unit operations
- Membrane
Opens in a new tab, loaded straight into the app — no setup.
Read the step-by-step guideReproduce this exact result from Python — the real client.get_example() → run_and_wait() path, not a mockup.
from flowsim.sdk import FlowSimClient
client = FlowSimClient()
example = client.get_example("h2-recovery-gas-membrane")
sim = client.create_simulation(example["title"], example["flowsheet"])
result = client.run_and_wait(sim["id"])
print(result["status"]) # "converged"
streams = client.streams(sim["id"])Related models
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.
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.
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.
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.
Ethanol–water distillation
An 8-stage column concentrating ethanol overhead toward the azeotrope (the headline demo).
Corn wet milling: starch to high-fructose corn syrup
The sweetener train of a corn wet mill, end to end on the new sugar thermo package. A 35 wt% starch slurry off the mill is saccharified to glucose (glucoamylase, Michaelis-Menten), part-isomerised to fructose, enriched by simulated moving-bed chromatography, and concentrated to syrup in a two-effect evaporator. Three results are worth reading rather than assumed. The isomerase lands at 42% fructose — the real equilibrium of glucose isomerase, which is precisely why an SMB exists downstream: the reaction cannot reach HFCS-55 on its own. The SMB then splits on the cited Ca²⁺-resin affinities (fructose H=0.69 vs glucose H=0.26), sending fructose to the extract and recycling glucose in the raffinate. The evaporator finishes at 77 wt% solids, commercial HFCS syrup spec. That last number is only reachable because of boiling-point elevation. Modelled as inert solids the sugars give no BPE feedback and the evaporator is bimodal — it either does not boil or boils to dry sugar, with nothing in between. The sugar package (Norrish) supplies the real elevation, and syrup concentration becomes a smooth, controllable function of steam (42 → 77 wt% over the sweep range). Starch itself is carried as an involatile pseudo-component: it has no boiling point to characterise, so none is invented.