Public API
This page lists exported symbols of CTFlows.MultiPhase.
From CTFlows.MultiPhase
CTFlows.MultiPhase [Module]
CTFlows.MultiPhase — Module
MultiPhaseMulti-phase flow concatenation and sequential integration.
This module provides types and operators for concatenating flows with switching times and optional jumps, implementing exact sequential integration.
AnyMultiPhaseFlow [Struct]
CTFlows.MultiPhase.AnyMultiPhaseFlow — Type
struct MultiPhaseFlow{TD<:CTBase.Traits.TimeDependence, VD<:CTBase.Traits.VariableDependence, D<:CTBase.Traits.AbstractDynamicsTrait, FS<:Tuple, ST<:(Vector{<:Real}), J<:(Vector)} <: CTFlows.Flows.AbstractFlow{TD<:CTBase.Traits.TimeDependence, VD<:CTBase.Traits.VariableDependence, D<:CTBase.Traits.AbstractDynamicsTrait}Type alias for any multi-phase flow.
See also: CTFlows.MultiPhase.MultiPhaseStateFlow, CTFlows.MultiPhase.MultiPhaseHamiltonianFlow.
MultiPhaseFlow [Struct]
CTFlows.MultiPhase.MultiPhaseFlow — Type
struct MultiPhaseFlow{TD<:CTBase.Traits.TimeDependence, VD<:CTBase.Traits.VariableDependence, D<:CTBase.Traits.AbstractDynamicsTrait, FS<:Tuple, ST<:(Vector{<:Real}), J<:(Vector)} <: CTFlows.Flows.AbstractFlow{TD<:CTBase.Traits.TimeDependence, VD<:CTBase.Traits.VariableDependence, D<:CTBase.Traits.AbstractDynamicsTrait}Concrete multi-phase flow combining multiple flows of the same dynamics family with switching times and optional jumps.
The dynamics axis is encoded in D, following the same pattern as Flow:
D = StateDynamics→ state multi-phase flow (aliasMultiPhaseStateFlow)D = HamiltonianDynamics→ Hamiltonian multi-phase flow (aliasMultiPhaseHamiltonianFlow)
flows is a heterogeneous tuple, lifting the previous homogeneous-S/I constraint: phases may wrap systems and integrators of different concrete types.
Type Parameters
TD <: TimeDependence: Time dependence trait (Autonomous or NonAutonomous)VD <: VariableDependence: Variable dependence trait (Fixed or NonFixed)D <: AbstractDynamicsTrait: Dynamics trait (StateDynamicsorHamiltonianDynamics)FS <: Tuple: Tuple ofAbstractFlow{TD,VD,D}(heterogeneous allowed)ST <: Vector{<:Real}: Type of the switching times vectorJ <: Vector{<:Any}: Type of the jumps vector
Fields
flows::FS: Tuple of flows for each phaseswitching_times::ST: Switching times between phasesjumps::J: Optional jump functions applied at switching times
See also: CTFlows.MultiPhase.MultiPhaseStateFlow, CTFlows.MultiPhase.MultiPhaseHamiltonianFlow, CTFlows.Flows.Flow.
MultiPhaseHamiltonianFlow [Struct]
CTFlows.MultiPhase.MultiPhaseHamiltonianFlow — Type
struct MultiPhaseFlow{TD, VD, CTBase.Traits.HamiltonianDynamics, FS, ST, J} <: CTFlows.Flows.AbstractFlow{TD, VD, CTBase.Traits.HamiltonianDynamics}Alias for Hamiltonian multi-phase flows: MultiPhaseFlow{TD,VD,HamiltonianDynamics,FS,ST,J}.
See also: CTFlows.MultiPhase.MultiPhaseFlow, CTFlows.MultiPhase.MultiPhaseStateFlow.
MultiPhaseStateFlow [Struct]
CTFlows.MultiPhase.MultiPhaseStateFlow — Type
struct MultiPhaseFlow{TD, VD, CTBase.Traits.StateDynamics, FS, ST, J} <: CTFlows.Flows.AbstractFlow{TD, VD, CTBase.Traits.StateDynamics}Alias for state multi-phase flows: MultiPhaseFlow{TD,VD,StateDynamics,FS,ST,J}.
See also: CTFlows.MultiPhase.MultiPhaseFlow, CTFlows.MultiPhase.MultiPhaseHamiltonianFlow.
get_flow [Function]
CTFlows.MultiPhase.get_flow — Function
get_flow(
mpf::CTFlows.MultiPhase.MultiPhaseFlow,
i::Int64
) -> Any
Return the flow for a specific phase.
Arguments
mpf::MultiPhaseFlow: The multi-phase flow.i::Int: Phase index (1-based).
Returns
AbstractFlow: The flow for phasei.
See also: CTFlows.MultiPhase.n_phases, CTFlows.MultiPhase.get_switching_time.
get_flows [Function]
CTFlows.MultiPhase.get_flows — Function
get_flows(f::CTFlows.Flows.AbstractFlow) -> Tuple
Get the flows from a single-phase flow as a 1-tuple.
get_flows(mpf::CTFlows.MultiPhase.MultiPhaseFlow) -> Tuple
Get the flows tuple from a multi-phase flow.
get_jump [Function]
CTFlows.MultiPhase.get_jump — Function
get_jump(
mpf::CTFlows.MultiPhase.MultiPhaseFlow,
i::Int64
) -> Any
Return the jump function at a specific phase boundary.
Arguments
mpf::MultiPhaseFlow: The multi-phase flow.i::Int: Phase index (1-based). Returns the jump applied after phasei.
Returns
Union{Nothing, Function, Tuple}: The jump function, ornothingif no jump is defined.
See also: CTFlows.MultiPhase.n_phases, CTFlows.MultiPhase.get_flow.
get_jumps [Function]
CTFlows.MultiPhase.get_jumps — Function
get_jumps(_::CTFlows.Flows.AbstractFlow) -> Vector
Get the jumps from a single-phase flow (empty vector).
get_jumps(mpf::CTFlows.MultiPhase.MultiPhaseFlow) -> Vector
Get the jumps from a multi-phase flow.
get_switching_time [Function]
CTFlows.MultiPhase.get_switching_time — Function
get_switching_time(
mpf::CTFlows.MultiPhase.MultiPhaseFlow,
i::Int64
) -> Real
Return the switching time at a specific phase boundary.
Arguments
mpf::MultiPhaseFlow: The multi-phase flow.i::Int: Phase index (1-based). Returns the switching time between phaseiandi+1.
Returns
Real: The switching time.
See also: CTFlows.MultiPhase.n_phases, CTFlows.MultiPhase.get_flow.
get_switching_times [Function]
CTFlows.MultiPhase.get_switching_times — Function
get_switching_times(
_::CTFlows.Flows.AbstractFlow
) -> Vector{<:Real}
Get the switching times from a single-phase flow (empty vector).
get_switching_times(
mpf::CTFlows.MultiPhase.MultiPhaseFlow
) -> Vector{<:Real}
Get the switching times from a multi-phase flow.
n_phases [Function]
CTFlows.MultiPhase.n_phases — Function
n_phases(mpf::CTFlows.MultiPhase.MultiPhaseFlow) -> Int64
Return the number of phases in a multi-phase flow.
Arguments
mpf::MultiPhaseFlow: The multi-phase flow.
Returns
Int: Number of phases.
See also: CTFlows.MultiPhase.get_flow, CTFlows.MultiPhase.get_switching_time.