Examples and Verification

The repository ships runnable scripts in examples/ plus regression tests in test/. This page groups them by validation purpose.

1. How to Run

From repository root:

julia --project=. -e 'using Pkg; Pkg.test()'

Representative examples:

julia --project=. examples/04_mms_convergence.jl
julia --project=. examples/08_two_phase_mms_fixed_interface.jl
julia --project=. examples/27_two_phase_static_circle_spurious_current.jl
julia --project=. examples/14_unsteady_oscillating_cylinder.jl
julia --project=. examples/22_3d_falling_rigid_sphere_split_vs_strong.jl

Developer probes retained intentionally:

julia --project=. test/dev_pressure_outlet_mms.jl
julia --project=. test/dev_outlet_row_equivalence.jl
julia --project=. test/dev_traction_box_probe.jl

2. Monophasic MMS and Convergence

Scripts

  • examples/01_mms_box.jl
  • examples/04_mms_convergence.jl
  • examples/05_mms_convergence_zero_pressure.jl
  • examples/24_mms_convergence_suite.jl (multi-case suite)

What this validates

  • steady mono assembly consistency,
  • pressure-gradient/divergence coupling,
  • convergence behavior under different BC scenarios,
  • gauge-aware pressure error handling.

3. Embedded-Boundary MMS and Obstacle Cases

Scripts

  • examples/02_mms_circle_obstacle.jl
  • examples/03_flow_past_circle.jl
  • examples/06_mms_convergence_embedded_outside_circle.jl

What this validates

  • cut-cell geometry coupling,
  • cut Dirichlet trace enforcement,
  • obstacle-style embedded-boundary behavior.

4. Two-Phase Fixed-Interface Validations

Scripts

  • examples/08_two_phase_mms_fixed_interface.jl
  • examples/27_two_phase_static_circle_spurious_current.jl
  • examples/09_two_phase_planar_couette.jl
  • examples/10_two_phase_planar_poiseuille.jl
  • examples/11_two_phase_oscillatory_couette.jl
  • examples/12_two_phase_viscous_drop_drag.jl

What this validates

  • traction/interface-force row path,
  • shared interface trace behavior,
  • pressure-jump handling,
  • static-circle snapshot plotting (velocity arrows + pressure map) and Laplace sweep diagnostics (La = rho*D*sigma/mu^2, Ca = ||u||_inf*mu/sigma),
  • layered profile reproduction (Couette/Poiseuille),
  • oscillatory response, fixed-drop drag trends.

5. Unsteady and Moving-Boundary Monophasic

Scripts

  • examples/07_unsteady_sphere_drag.jl
  • examples/13_unsteady_moving_body_translation.jl
  • examples/14_unsteady_oscillating_cylinder.jl
  • examples/25_moving_mms_time_schemes.jl

What this validates

  • BE/CN/theta unsteady path,
  • moving slab assembly behavior,
  • prescribed moving interface velocity path,
  • force/torque diagnostics in moving settings.

6. Outlet / Traction / Symmetry Families

Scripts/tests

  • examples/15_channel_pressure_outlet_traction.jl
  • examples/16_channel_poiseuille_pressure_outlet.jl
  • test/dev_outlet_row_equivalence.jl
  • test/dev_traction_box_probe.jl
  • targeted BC testsets in test/runtests.jl

What this validates

  • side-level traction overwrite algebra,
  • pressure-outlet and do-nothing specializations,
  • symmetry side rules and cross-coupling terms.

7. Rigid-Body FSI Families

Scripts

  • examples/17_fsi_free_falling_circle.jl
  • examples/18_fsi_prescribed_rotating_cylinder.jl
  • examples/19_fsi_spin_decay_calibrated.jl
  • examples/20_fsi_falling_rotating_ellipse.jl
  • examples/22_3d_falling_rigid_sphere_split_vs_strong.jl
  • examples/23_fsi_neutral_buoyancy_decay.jl

What this validates

  • split-coupled rigid-body updates,
  • rotational coupling and torque response,
  • strong-coupling fixed-point iterations,
  • 3D rigid-sphere coupling behavior and split-vs-strong comparison.

8. 3D Coverage

Scripts

  • examples/07_unsteady_sphere_drag.jl
  • examples/12_two_phase_viscous_drop_drag.jl
  • examples/21_3d_rigid_sphere_drag.jl
  • examples/22_3d_falling_rigid_sphere_split_vs_strong.jl

What this validates

  • 3D mono and moving runs,
  • 3D fixed-interface two-phase run,
  • 3D rigid-body/FSI helper path.

9. Verification Map

Example / test familyModel familyWhat it checksExpected outcomeStatus
runtests.jl mono MMS blocksMono steady/unsteadyassembly consistency + convergence trendsresiduals small, errors decrease with refinementImplemented
06_mms_convergence_embedded_outside_circle.jlMono cut-cellembedded-interface MMS behaviorconvergence trend and stable solveImplemented
08_two_phase_mms_fixed_interface.jlTwo-phase fixed interfacetraction jump pathnear-zero velocity with imposed jumpImplemented
27_two_phase_static_circle_spurious_current.jl + testTwo-phase fixed interfacespurious-current level + Laplace jumpu near zero and pressure jump close to theoryImplemented
09/10/11 layered examplesTwo-phase fixed interfaceCouette/Poiseuille/oscillatory profilesprofile and phase behavior match expectationsImplemented
13/25 moving examples + moving_boundary_stokes_tests.jlMoving monoslab/end-time moving assembly behaviorstable stepping and expected temporal trendsImplemented
outlet/symmetry testsets + dev_* probesMono BC algebratraction/outlet/symmetry row semanticsrow-equivalence and sign rules holdImplemented
fsi_tests.jl + 17..23 examplesRigid-body FSIsplit/rotation/strong/3D helper pathsforce/torque trends and convergence sanity checksImplemented
moving two-phase interfaceTwo-phase moving interfacegeometric interface evolutionn/aMissing
multi-body/contact FSIRigid-body FSIcollisions/contact constraintsn/aMissing

10. Notes on Test vs Script Roles

  • test/runtests.jl and included files are CI regression coverage.
  • test/dev_pressure_outlet_mms.jl is a manual developer probe (not included by runtests.jl).
  • test/dev_outlet_row_equivalence.jl and test/dev_traction_box_probe.jl are retained developer probes currently included in runtests.jl.