ostk.astrodynamics.trajectory.StateBuilder¶
- class StateBuilder(*args, **kwargs)¶
Bases:
pybind11_object
This class makes it convenient to build a State object.
Overloaded function.
__init__(self: ostk.astrodynamics.trajectory.StateBuilder, frame: ostk.physics.coordinate.Frame, coordinate_subsets: list[ostk.astrodynamics.trajectory.state.CoordinateSubset]) -> None
Construct a new StateBuilder object.
- Arguments:
frame (Frame): The reference frame. coordinate_subsets list[CoordinateSubset]: The coordinate subsets.
- Returns:
StateBuilder: The new StateBuilder object.
__init__(self: ostk.astrodynamics.trajectory.StateBuilder, frame: ostk.physics.coordinate.Frame, coordinate_broker: ostk.astrodynamics.trajectory.state.CoordinateBroker) -> None
Construct a new StateBuilder object.
- Arguments:
frame (Frame): The reference frame. coordinate_broker (CoordinateBroker): The coordinate broker.
- Returns:
StateBuilder: The new StateBuilder object.
__init__(self: ostk.astrodynamics.trajectory.StateBuilder, state: ostk.astrodynamics.trajectory.State) -> None
Construct a new StateBuilder object.
- Arguments:
state (State): The state.
- Returns:
StateBuilder: The new StateBuilder object.
Methods
Access the coordinate broker of the StateBuilder.
Build a State object from the StateBuilder.
Expand a State object to the coordinate subsets of the StateBuilder.
Get the coordinate subsets of the StateBuilder.
Get the reference frame of the StateBuilder.
Get the total size of all coordinates from all subsets.
Check if the StateBuilder is defined.
Reduce a State object to the coordinate subsets of the StateBuilder.
Get an undefined StateBuilder.
- __add__(
- self: ostk.astrodynamics.trajectory.StateBuilder,
- arg0: ostk.astrodynamics.trajectory.state.CoordinateSubset,
Add a coordinate subset to the StateBuilder.
- Parameters:
coordinate_subsets (CoordinateSubset) -- The coordinate subset to add.
- Returns:
The StateBuilder with the added coordinate subset.
- Return type:
- access_coordinate_broker( ) ostk.astrodynamics.trajectory.state.CoordinateBroker ¶
Access the coordinate broker of the StateBuilder.
- Returns:
The coordinate broker of the StateBuilder.
- Return type:
- build(
- self: ostk.astrodynamics.trajectory.StateBuilder,
- instant: ostk.physics.time.Instant,
- coordinates: numpy.ndarray[numpy.float64[m, 1]],
- instant: ostk.physics.time.Instant,
Build a State object from the StateBuilder.
- Parameters:
instant (Instant) -- The instant of the state.
coordinates (VectorXd) -- The coordinates of the state.
- Returns:
A State object built from the StateBuilder.
- Return type:
- expand(
- self: ostk.astrodynamics.trajectory.StateBuilder,
- state: ostk.astrodynamics.trajectory.State,
- default_state: ostk.astrodynamics.trajectory.State,
- state: ostk.astrodynamics.trajectory.State,
Expand a State object to the coordinate subsets of the StateBuilder.
- get_coordinate_subsets( ) list[ostk.astrodynamics.trajectory.state.CoordinateSubset] ¶
Get the coordinate subsets of the StateBuilder.
- Returns:
The coordinate subsets of the StateBuilder.
- Return type:
Array<Shared<const CoordinateSubset>>
- get_frame( ) ostk.physics.coordinate.Frame ¶
Get the reference frame of the StateBuilder.
- Returns:
The reference frame of the StateBuilder.
- Return type:
Frame
- get_size(self: ostk.astrodynamics.trajectory.StateBuilder) int ¶
Get the total size of all coordinates from all subsets.
- Returns:
The total size of all coordinates from all subsets.
- Return type:
Size
- is_defined(self: ostk.astrodynamics.trajectory.StateBuilder) bool ¶
Check if the StateBuilder is defined.
- Returns:
True if the StateBuilder is defined, False otherwise.
- Return type:
- reduce( ) ostk.astrodynamics.trajectory.State ¶
Reduce a State object to the coordinate subsets of the StateBuilder.
- static undefined() ostk.astrodynamics.trajectory.StateBuilder ¶
Get an undefined StateBuilder.
- Returns:
The undefined StateBuilder.
- Return type: