ostk.astrodynamics.access.Generator

class Generator(
self: ostk.astrodynamics.access.Generator,
environment: ostk.physics.Environment,
step: ostk.physics.time.Duration = Duration.minutes(1.0),
tolerance: ostk.physics.time.Duration = Duration.microseconds(1.0),
access_filter: Callable[[ostk.astrodynamics.Access], bool] = None,
state_filter: Callable[[ostk.astrodynamics.trajectory.State, ostk.astrodynamics.trajectory.State], bool] = None,
)

Bases: pybind11_object

An access generator.

Constructor.

Parameters:
  • environment (Environment) -- The environment.

  • step (Duration) -- The step. Defaults to Duration.minutes(1.0).

  • tolerance (Duration) -- The tolerance. Defaults to Duration.microseconds(1.0).

  • access_filter (function) -- The access filter. Defaults to None.

  • state_filter (function) -- The state filter. Defaults to None.

Methods

compute_accesses

Overloaded function.

get_access_filter

Get the access filter.

get_condition_function

Get the condition function.

get_state_filter

Get the state filter.

get_step

Get the step.

get_tolerance

Get the tolerance.

is_defined

Check if the generator is defined.

set_access_filter

Set the access filter.

set_state_filter

Set the state filter.

set_step

Set the step.

set_tolerance

Set the tolerance.

undefined

Get an undefined generator.

compute_accesses(*args, **kwargs)

Overloaded function.

  1. compute_accesses(self: ostk.astrodynamics.access.Generator, interval: ostk.physics.time.Interval, access_target: ostk.astrodynamics.access.AccessTarget, to_trajectory: ostk.astrodynamics.Trajectory, coarse: bool = False) -> list[ostk.astrodynamics.Access]

    Compute the accesses.

    Args:

    interval (Interval): The time interval over which to compute accesses. access_target (AccessTarget): The access target to compute the accesses with. to_trajectory (Trajectory): The trajectory to co compute the accesses with. coarse (bool): True to use coarse mode. Defaults to False. Only available for fixed targets.

    Returns:

    Accesses: The accesses.

  2. compute_accesses(self: ostk.astrodynamics.access.Generator, interval: ostk.physics.time.Interval, access_targets: list[ostk.astrodynamics.access.AccessTarget], to_trajectory: ostk.astrodynamics.Trajectory, coarse: bool = False) -> list[list[ostk.astrodynamics.Access]]

    Compute the accesses.

    Args:

    interval (Interval): The time interval over which to compute accesses. access_targets (list[AccessTarget]): The access targets to compute the accesses with. to_trajectory (Trajectory): The trajectory to co compute the accesses with. coarse (bool): True to use coarse mode. Defaults to False. Only available for fixed targets.

    Returns:

    Accesses: The accesses.

get_access_filter(
self: ostk.astrodynamics.access.Generator,
) Callable[[ostk.astrodynamics.Access], bool]

Get the access filter.

Returns:

The access filter.

Return type:

function

get_condition_function(
self: ostk.astrodynamics.access.Generator,
access_target: ostk.astrodynamics.access.AccessTarget,
to_trajectory: ostk.astrodynamics.Trajectory,
) Callable[[ostk.physics.time.Instant], bool]

Get the condition function.

Parameters:
  • access_target (AccessTarget) -- The access target from which the condition function is being evaluated against.

  • to_trajectory (Trajectory) -- The trajectory to which the condition function is being evaluated against.

Returns:

The condition function.

Return type:

function

get_state_filter(
self: ostk.astrodynamics.access.Generator,
) Callable[[ostk.astrodynamics.trajectory.State, ostk.astrodynamics.trajectory.State], bool]

Get the state filter.

Returns:

The state filter.

Return type:

function

get_step(
self: ostk.astrodynamics.access.Generator,
) ostk.physics.time.Duration

Get the step.

Returns:

The step.

Return type:

Duration

get_tolerance(
self: ostk.astrodynamics.access.Generator,
) ostk.physics.time.Duration

Get the tolerance.

Returns:

The tolerance.

Return type:

Duration

is_defined(self: ostk.astrodynamics.access.Generator) bool

Check if the generator is defined.

Returns:

True if the generator is defined, False otherwise.

Return type:

bool

set_access_filter(
self: ostk.astrodynamics.access.Generator,
access_filter: Callable[[ostk.astrodynamics.Access], bool],
) None

Set the access filter.

Parameters:

access_filter (function) -- The access filter.

set_state_filter(
self: ostk.astrodynamics.access.Generator,
state_filter: Callable[[ostk.astrodynamics.trajectory.State, ostk.astrodynamics.trajectory.State], bool],
) None

Set the state filter.

Parameters:

state_filter (function) -- The state filter.

set_step(
self: ostk.astrodynamics.access.Generator,
step: ostk.physics.time.Duration,
) None

Set the step.

Parameters:

step (Duration) -- The step.

set_tolerance(
self: ostk.astrodynamics.access.Generator,
tolerance: ostk.physics.time.Duration,
) None

Set the tolerance.

Parameters:

tolerance (Duration) -- The tolerance.

static undefined() ostk.astrodynamics.access.Generator

Get an undefined generator.

Returns:

An undefined generator.

Return type:

Generator