channel2d
2D incompressible flow by the lattice Boltzmann method (D2Q9, BGK). mode=cylinder: flow past a cylinder, vortex street, Strouhal number, vorticity.png, probe.csv and scene.glb (the vorticity as a 3D surface). mode=poiseuille: channel flow checked against the exact parabola, profile.csv. All lengths in lattice cells, velocities in lattice units.
- Field
- Mechanics, CAD and finite elements
- Version
- 0.1.0
- Runs as
- Compiled (Rust)
- Typical run
- 60 s
Compiled from source: run sh packs/install.sh once before admitting it.
Known answers it must pass
r0001Poiseuille channel: peak speed within 1% of g H^2 / 8 nupassed
rel_error≤ 0.010.000518023lockedinside the rangeprofile_rms_error≤ 0.010.000514512lockedinside the ranger0002Cylinder at Re 100, periodic sides, 20% blockage: a vortex street with St in 0.16-0.22 (unbounded 0.164; blockage raises it)passed
strouhal0.16 to 0.220.200708lockedinside the rangeshedding_periods≥ 34lockedinside the rangeprobe_amplitude_over_U≥ 0.10.702465lockedinside the range
Each line is one reading the kernel checked. The bright band is the tolerance; the needle is the value the instrument actually returned when it was admitted. A needle near the centre line used little of its tolerance.
Inputs
| Name | Unit | Default | Meaning |
|---|---|---|---|
mode | cylinder | ||
Re | 1 | 100 | Reynolds number U D / nu (cylinder mode). |
nx | 1 | 400 | |
ny | 1 | 100 | |
diameter_cells | 1 | 20 | |
u_lattice | 1 | 0.08 | Inflow speed (cylinder) or target peak speed (poiseuille), lattice units. Keep it under 0.1 so the flow stays nearly incompressible. |
tau | 1 | 0.8 | Relaxation time (poiseuille mode; cylinder mode derives it from Re). |
steps | 20000 |
Readings
| Name | Unit | Meaning |
|---|---|---|
strouhal | 1 | |
u_max, u_max_exact, rel_error | ||
vorticity.png | ||
probe.csv | ||
profile.csv |
Try the call
Change a value and the command updates. Nothing runs here; paste it into your terminal or give it to your agent.