How mehdiansari-cfd/cfdsolver works
Euler Laboratory is a browser-based playground for 1D shock tubes, quasi-1D nozzles, and 2D Cartesian Euler flows. Users open a page, select a preset and solver options, run or replay a simulation, and inspect plots or field views against analytical references where available. The numerical solvers are DOM-free; the shared UI handles time-budgeted computation and playback. The README and excerpts support the main solver relationships, but the page source was not sampled, so page-to-UI wiring is shown only where documented.
Main entry points: index.html 1D lab page · nozzle.js Nozzle evolution · index2d.html 2D lab page · labui.js Plots and probes
Components 15
Browser experience
- 1D lab page
index.html - 2D lab page
index2d.html - Solve and playback
labui.js - Plots and probes
labui.js
Shock tube
- Tube presets and state
solver.js - 1D fluxes and update
solver.js - Exact Riemann reference
solver.js
Nozzle flow
- Area and nozzle state
nozzle.js - Reservoir and exit bounds
nozzle.js - Nozzle evolution
nozzle.js - Isentropic reference
nozzle.js
2D flow
- 2D presets and state
solver2d.js - 2D fluxes and update
solver2d.js - Field extraction
solver2d.js
Other components
- Learner / researcher
Connections 18
- Learner / researcher → 1D lab page: opens 1D lab
README.md - Learner / researcher → 2D lab page: opens 2D lab
README.md - 1D lab page → Solve and playback: runs simulations
- 2D lab page → Solve and playback: runs simulations
- 1D lab page → Tube presets and state: selects preset
- 1D lab page → Area and nozzle state: selects nozzle
- 2D lab page → 2D presets and state: selects preset
- Solve and playback → Plots and probes: drives views
labui.js - Tube presets and state → 1D fluxes and update: initializes state
solver.js - 1D fluxes and update → Exact Riemann reference: compares solution
README.md - Area and nozzle state → Nozzle evolution: initializes state
nozzle.js - Nozzle evolution → Reservoir and exit bounds: applies boundaries
nozzle.js - Nozzle evolution → 1D fluxes and update: reuses flux update
nozzle.js - Nozzle evolution → Isentropic reference: compares solution
README.md - 2D presets and state → 2D fluxes and update: initializes state
solver2d.js - 2D fluxes and update → Field extraction: extracts fields
solver2d.js - Plots and probes → Exact Riemann reference: shows overlay
README.md - Plots and probes → Isentropic reference: shows theory
README.md