-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationenhancementNew feature or requestNew feature or request
Description
Background
The Poisson bracket tests verify correctness numerically, but visual examples help understand:
- Physical interpretation of {f,g} as advection operator
- Effect of dealiasing on high-k modes
- Differences between analytical and random fields
Tasks
- Create
examples/poisson_bracket_demo.pyscript - Visualize 2D example: f=sin(x), g=cos(y), {f,g}=-cos(x)sin(y)
- Plot f, g, and {f,g} as 2D heatmaps
- Show quiver plot of ∇f and ∇g
- Annotate with cross product interpretation
- Show effect of dealiasing:
- Compute bracket with and without dealiasing
- Plot difference and high-k mode content
- Compare smooth vs random fields:
- Show why random fields have larger numerical errors
- Visualize spectral content (1D energy spectra)
- Add to documentation as tutorial
Visual Output
examples/
├── poisson_bracket_demo.py
└── figures/
├── analytical_bracket.png # sin/cos example
├── dealiasing_effect.png # with/without comparison
└── random_field_spectra.png # spectral content
Related
- Issue Step 4: Poisson Bracket #4 (Poisson bracket implementation)
- Issue Document numerical error budget for Poisson bracket #36 (error budget documentation)
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationenhancementNew feature or requestNew feature or request