Core concepts¶
The package has one short numerical pipeline:
- The caller owns
timeandpositions; aSimulationSpeccarries them with the system, load, and sensor layout for one run. - A load only generates a force field on those axes.
- A system supplies matrices and maps physical positions to its generalized coordinates.
- The solver performs the load projection, including modal projection for the finite-element beam.
Array conventions remain explicit:
| Quantity | Shape |
|---|---|
| Physical load field | (position, time) |
| Generalized force and response | (DOF, time) |
| Sensor signal | (sensor, time) |
| Dataset signal | (sample, sensor, time) |
| Mode shapes | (mode, position) |
For MDOF systems, positions must be all integer DOF indices in order. For the
beam, positions are physical coordinates along its span.
Dataset samples receive deterministic seeds derived from the dataset seed and sample index. This keeps results independent of worker count.
Dataset generation does not mutate a template system. For every case mapping,
DynaResp calls system_builder(case), calls load_builder(case), and then
simulates those returned objects with the supplied sensors.
Design pattern¶
The package uses a small strategy-based pipeline. A structural system defines matrix assembly and coordinate mapping, a load defines excitation generation, and each measurement effect defines one signal transformation. The simulation engine depends on those common contracts, so changing a beam to an MDOF model or white noise to a moving load does not change the orchestration code.
SimulationSpec is the explicit context for one run. It holds the selected
strategies and validated axes; run_simulation executes them. Dataset builders
are factories for creating a fresh system and load per realization.
Variability is separate from those physics strategies. Use parameter_grid or
an ordinary list for controlled designs. For random or correlated studies,
case_builder(rng) constructs one mapping per sample with a deterministic
NumPy generator. Neither choice changes the simulation engine.