-
Notifications
You must be signed in to change notification settings - Fork 0
Dynamic axis management: add/remove/reshape axes at specification time #2
Copy link
Copy link
Open
Milestone
Description
Support declarative addition and removal of axes in the system specification, so users can straightforwardly extend a model with new trait, spatial, or structured dimensions.
Motivation
A TRIDENT-like model starts with trait axes (phytoplankton size θ, zooplankton size ϑ) and a spatial axis (depth z). A user should be able to:
- Add a new trait axis (e.g. light-harvesting pigment ratio) with one YAML block
- The compiler should automatically:
- Extend the state tensor dimensions
- Wire diffusion operators for the new axis
- Adjust reaction terms that depend on the new trait
- Validate that rate functions have the right arity
Tasks
-
Axistype hierarchy:TraitAxis,SpatialAxis,StructuredAxis(age, stage, etc.) - Each axis declares: name, bounds, default resolution, diffusion coefficient (optional), boundary conditions
-
add_axis!(spec, axis)— extend a compiled SystemSpec with a new dimension -
remove_axis!(spec, name)— project out a dimension (integrate or marginalise) - Validate: reaction terms must accept the correct number of trait arguments after axis changes
- Tensor-product grid assembly: the full state is the outer product of all axis grids
- Resolution independence: axes can have different resolutions; the compiler handles indexing
Cross-references
- OpEngine.jl Dynamic axis management: add/remove/reshape axes at specification time #2: the adaptive grid refinement consumes axis declarations from here
- OpEngine.jl Core YAML-to-callable system compiler #1: the solver must handle variable-dimension state vectors
- trident Core YAML-to-callable system compiler #1: TRIDENT is the first consumer — 3 trait axes + 1 spatial axis
- ACCIDDA/op_system: Python equivalent should get a parallel issue
Boundary
This is specification — how axes are declared and validated. The grid points (uniform or adaptive) are computed by OpEngine.jl. The evaluation of whether adding an axis improves predictions is ModelCriticism.jl.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels