Kuramoto-Sivashinsky Utilities¶
This module contains helper functions to compute various physical quantities, as well as the [ETDRK4] time integration scheme.
-
orbithunter.ks.physics.
dissipation
(orbit_instance, average='spacetime')[source]¶ Average energy dissipation or corresponding field.
- Parameters
- float or ndarray :
Spatiotemporal dissipation returned as a field, or averaged along an axis (ndarray) or spacetime (float).
Notes
Dissipation \(= u_xx^2\).
-
orbithunter.ks.physics.
energy
(orbit_instance, average='spacetime')[source]¶ Average energy or corresponding field
- Parameters
- float or ndarray :
Spatiotemporal power returned as a field, or averaged along an axis (ndarray) or spacetime (float).
Notes
Energy = 1/2 u^2
-
orbithunter.ks.physics.
energy_variation
(orbit_instance, average='spacetime')[source]¶ The field u_t * u whose spatial average should equal power - dissipation.
- Parameters
- float or ndarray :
Spatiotemporal energy variation returned as a field, or averaged along an axis (ndarray) or spacetime (float).
- Returns
- Field equivalent to u_t * u.
-
orbithunter.ks.physics.
power
(orbit_instance, average='spacetime')[source]¶ Average power or corresponding field
- Parameters
- float or ndarray :
Spatiotemporal power returned as a field, or averaged along an axis (ndarray) or spacetime (float).
Notes
power = u_x^2
-
orbithunter.ks.physics.
integrate
(orbit_, **kwargs)[source]¶ Exponential time-differencing Runge-Kutta 4th order integration scheme.
- Parameters
- orbit_Orbit
The Orbit which contains the initial starting point for the integration
- kwargsdict
verbose : bool
- starting_point :
The row to select as the initial value.
- integration_timefloat
The total amount of time to integrate, if not provided then defaults to orbit’s period (for reproduction of orbit, typically).
- step_sizefloat
The integration step
- return_trajectorybool
Whether to store and return all integration steps or only the endpoint.
- Returns
- Orbit :
Orbit instance with either an integrated trajectory or its final value as a state.
Notes
Adapter https://epubs.siam.org/doi/abs/10.1137/S1064827502410633?journalCode=sjoce3
By default, when input is an instance of relative periodic orbit then shift is calculated off of the integrated trajectory. This will lead to plotting issues so unless desired, you should convert to the base orbit type first.