Renewable-Powered Desalination Membrane (2D)
Interactive 2D reverse-osmosis lab: watch salt ions and water molecules meet a membrane whose flux is set by real van't Hoff osmotic pressure and a solution-diffusion rejection model — then dial down the solar/wind supply and see the pump run out of pressure before the salt does.
The 3D version of this sim visualizes reverse osmosis as a generic binding-and-release process; this 2D companion instead drives it with the actual textbook physics of a solar/wind-powered desalination plant. Osmotic pressure is computed from feed salinity through the van't Hoff approximation (Δπ ≈ 0.78 bar per g/L for seawater), and permeate flux follows the solution-diffusion model Jw = A·(ΔP − Δπ) — so if the applied pressure can't clear the osmotic pressure, no water crosses no matter how long you wait. Salt rejection is derived the same way real membranes behave: R = Jw/(Jw + B), meaning rejection collapses toward zero at low flux because diffusion carries salt through regardless of water flow, and only climbs toward 100% once flux is strong. The renewable-power-availability slider is the twist — it caps the maximum pressure your pump can reach, so a cloudy, calm day can leave a perfectly good membrane starved of the pressure it needs, visibly flagged as "power-limited" rather than "membrane failure."
2D reverse-osmosis lab driven by van't Hoff osmotic pressure and a solution-diffusion salt-rejection model, with a solar/wind availability dial that caps the pump pressure the plant can actually deliver.
2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install
Flux only becomes positive once the applied pressure clears the feed's osmotic pressure (ΔP > Δπ). Below that threshold, the pump is pushing but the concentration gradient is pushing back harder, so net flux is zero — raise pressure, or lower salinity, to restart production.
It means your requested applied pressure exceeds what the renewable supply can deliver right now (availability × the pump's 80 bar ceiling). The membrane isn't broken — the plant just doesn't have enough solar/wind power to reach the pressure you asked for.
This uses the solution-diffusion rejection formula R = Jw/(Jw + B): at low water flux, slow salt diffusion through the membrane matters more relative to water flow, so a larger fraction of the permeate is salty. High flux "outruns" the salt diffusion, pushing rejection toward 100%.