Djinious
Fluid dynamicsProcess & water

Computational fluid dynamics

Solving a partial differential equation on a grid — a velocity field over space and time. A self-contained Lattice-Boltzmann solver reproduces the most iconic result in fluid dynamics: the von Kármán vortex street shed by flow past a cylinder, validated on channel flow, the Strouhal number, drag and lift, and a lid-driven cavity.

DjiniousLab
A vorticity field showing alternating red and blue vortices shedding off a cylinder into a von Kármán street
channel-flow error vs analytic
0.27%channel-flow error vs analytic
Strouhal number (shedding frequency)
0.20Strouhal number (shedding frequency)
cylinder drag coefficient
0.94cylinder drag coefficient
drag oscillates at twice the lift frequency
2×drag oscillates at twice the lift frequency
design notebooks
10design notebooks
requirements PASS
5 / 5requirements PASS

A whole velocity field, not a handful of states.

Every other model in this portfolio tracks a few variables in time. Fluid flow is different: it's a field — velocity and pressure at every point in space, coupled by a partial differential equation, evolving together. Solving it on a grid is computational fluid dynamics, the domain of COMSOL and ANSYS Fluent. This program builds a self-contained solver from scratch and uses it to reproduce the single most recognizable result in the field — the vortex street that peels off a cylinder in a flowing stream — then validates it against textbook benchmarks.

Get the physics right on a problem you can check.

The solver is a Lattice-Boltzmann method — a kinetic, particle-distribution route to the incompressible Navier-Stokes equations that is explicit, local and robust where a direct pressure solve is finicky. Before trusting it on anything complex, the program validates it on pressure-driven channel flow, where the exact answer is a parabola: the simulated profile matches the analytic one to 0.27%. A solver that nails the case you can check on paper is one you can believe on the case you can't.

DjiniousLab
A simulated channel-flow velocity profile lying on top of the analytic parabola
The correctness anchor: pressure-driven channel (Poiseuille) flow has an exact parabolic velocity profile, and the Lattice-Boltzmann solver reproduces it to a 0.27% L2 error. Validate against the closed form first, then turn the solver loose on the flows that don't have one.
DjiniousLab
The vorticity field of a von Kármán vortex street — alternating red and blue vortices shedding off a cylinder
The hero: flow past a cylinder above a critical Reynolds number sheds alternating vortices — the von Kármán vortex street. The vorticity field shows the signature pattern of counter-rotating eddies (red and blue) peeling off the cylinder and convecting downstream. The most recognizable result in fluid dynamics, solved on a grid.

The wake doesn't always shed — until it does.

At low Reynolds number the flow behind the cylinder is a steady, symmetric pair of recirculating bubbles. Raise the Reynolds number past a critical value and that symmetry breaks: the wake goes unstable and begins to shed vortices at a clean periodic frequency — a Hopf bifurcation in the flow itself. The program sweeps the Reynolds number and catches the transition, the wake oscillation amplitude jumping from essentially zero to fully developed shedding.

DjiniousLab
Wake oscillation amplitude versus Reynolds number — near zero at low Re, large above the critical value
The shedding transition: below a critical Reynolds number (~47) the wake is steady and the oscillation amplitude is essentially zero; above it the wake sheds and the amplitude jumps. A bifurcation in the flow, captured by sweeping a single dimensionless number.

Shedding leaves a fingerprint on the forces.

The vortex street isn't just pretty — it's measurable. Probe the wake and its velocity oscillates at a frequency that, made dimensionless, is the Strouhal number ≈ 0.2, the value every fluids textbook quotes. And the shedding shakes the cylinder: the lift force oscillates at the shedding frequency while the drag ripples at exactly twice it — the von Kármán signature, and the reason chimneys, cables and bridge decks need to be designed against vortex-induced vibration.

DjiniousLab
Drag and lift on the cylinder over time — lift oscillating at the shedding frequency, drag at twice it
The force signature: the alternating vortices push the cylinder side to side, so the lift oscillates at the shedding frequency and the drag ripples at exactly twice it (drag coefficient ≈ 0.94). This is vortex-induced vibration — why slender structures in a flow are designed against exactly this.

The other canonical test, passed too.

The lid-driven cavity — fluid in a box dragged by a moving top lid — is the other standard CFD validation case, with decades of published reference solutions. The solver produces the expected primary recirculating vortex, its centre landing right where the literature (Ghia et al.) puts it. Two canonical benchmarks passed, from one self-contained solver written in the notebook.

DjiniousLab
A lid-driven cavity flow — a primary recirculating vortex with velocity arrows circulating in the box
The lid-driven cavity: a moving top lid drags the fluid into a single primary recirculating vortex, its centre landing where the reference solutions put it. The CFD field's other classic benchmark — same solver, a closed box instead of an open wake.

Every number re-derived at sign-off.

The V&V notebook rebuilds the solver from scratch and re-derives each requirement against theory and benchmark, printing a PASS/FAIL board.

Result

  • Poiseuille profile vs analytic: 0.27%
  • Vortex-shedding amplitude / U₀: 0.87
  • Strouhal number: 0.20
  • Drag coefficient / signature: 0.94; drag = 2× lift
  • Cavity primary-vortex centre: (0.61, 0.72)

Requirement

  • Poiseuille profile vs analytic: R-01 < 2%
  • Vortex-shedding amplitude / U₀: R-02
  • Strouhal number: R-03 ≈ 0.15–0.2
  • Drag coefficient / signature: R-04
  • Cavity primary-vortex centre: R-05

A real field solver, at teaching fidelity.

The deliverable is ten notebooks and the dossier — a discretized PDE field, not an acausal lumped network, so there's no custom block or canvas. The solver is 2D incompressible, low-Mach Lattice-Boltzmann with a single-relaxation-time collision; the grid resolution is modest, the cylinder uses a staircase bounce-back boundary, the drag coefficients are indicative rather than publication-validated, and there's no turbulence model. What the program proves is the capability the portfolio most lacked — solving a partial differential equation as a spatial field on a grid — with a self-contained solver (no external CFD dependency) that reproduces the vortex street, the Strouhal number, the force signature, and two canonical benchmarks, every number re-runnable.