ostk.physics.unit.Interval

class Interval(
self: ostk.physics.unit.Interval,
arg0: ostk.physics.unit.Length,
arg1: ostk.physics.unit.Length,
arg2: ostk.mathematics.object.RealInterval.Type,
)

Bases: pybind11_object

Constructor.

Parameters:

Methods

closed

Construct a closed interval.

contains_interval

Check if the interval contains another interval.

contains_length

Check if the interval contains a length.

get_lower_bound

Get the lower bound.

get_upper_bound

Get the upper bound.

intersects

Check if the interval intersects another interval.

is_defined

Check if the interval is defined.

is_degenerate

Check if the interval is degenerate.

undefined

Get an undefined interval.

static closed(
arg0: ostk.physics.unit.Length,
arg1: ostk.physics.unit.Length,
) ostk.physics.unit.Interval

Construct a closed interval.

Returns:

A closed interval.

Return type:

Interval

contains_interval(
self: ostk.physics.unit.Interval,
arg0: ostk.physics.unit.Interval,
) bool

Check if the interval contains another interval.

Parameters:

anOtherInterval (Interval) -- Another interval.

Returns:

True if contains.

Return type:

bool

contains_length(
self: ostk.physics.unit.Interval,
arg0: ostk.physics.unit.Length,
) bool

Check if the interval contains a length.

Parameters:

aLength (Length) -- A length.

Returns:

True if contains.

Return type:

bool

get_lower_bound(self: ostk.physics.unit.Interval) ostk.physics.unit.Length

Get the lower bound.

Returns:

The lower bound.

Return type:

Length

get_upper_bound(self: ostk.physics.unit.Interval) ostk.physics.unit.Length

Get the upper bound.

Returns:

The upper bound.

Return type:

Length

intersects(
self: ostk.physics.unit.Interval,
arg0: ostk.physics.unit.Interval,
) bool

Check if the interval intersects another interval.

Returns:

True if intersects.

Return type:

bool

is_defined(self: ostk.physics.unit.Interval) bool

Check if the interval is defined.

Returns:

True if defined.

Return type:

bool

is_degenerate(self: ostk.physics.unit.Interval) bool

Check if the interval is degenerate.

Returns:

True if degenerate.

Return type:

bool

static undefined() ostk.physics.unit.Interval

Get an undefined interval.

Returns:

An undefined interval.

Return type:

Interval