codac 2.0.0
|
Go to the source code of this file.
Macros | |
#define | degenerate_mat(op) |
Helper macro to create a matrix from a specific operation applied to each interval element. | |
Functions | |
template<typename U = Scalar> requires IsIntervalDomain<U> | |
double | volume () const |
Computes the volume of the interval matrix. | |
bool | is_empty () const |
Checks whether the interval matrix is empty. | |
template<typename U = Scalar> requires IsIntervalDomain<U> | |
auto | lb () const |
Returns a matrix containing the lower bounds of each interval element. | |
template<typename U = Scalar> requires IsIntervalDomain<U> | |
auto | ub () const |
Returns a matrix containing the upper bounds of each interval element. | |
template<typename U = Scalar> requires IsIntervalDomain<U> | |
auto | mid () const |
Returns a matrix containing the midpoints of each interval element. | |
template<typename U = Scalar> requires IsIntervalDomain<U> | |
auto | mag () const |
Returns a matrix containing the magnitudes of each interval element. | |
template<typename U = Scalar> requires IsIntervalDomain<U> | |
auto | mig () const |
Returns a matrix containing the mignitudes of each interval element. | |
template<typename U = Scalar> requires IsIntervalDomain<U> | |
auto | rand () const |
Returns a matrix with random values chosen inside each interval element. | |
template<typename U = Scalar> requires IsIntervalDomain<U> | |
auto | rad () const |
Returns a matrix containing the radii of each interval element. | |
template<typename U = Scalar> requires IsIntervalDomain<U> | |
auto | diam () const |
Returns a matrix containing the diameters of each interval element. | |
bool | contains (const Matrix< double, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks if this interval matrix contains the specified matrix x . | |
template<typename OtherDerived> | |
bool | contains (const MatrixBase< OtherDerived > &x) const |
Template version to check containment of a matrix with arbitrary derived type. | |
template<typename T> | |
bool | _contains (const T &x) const |
Internal helper function to check containment. | |
bool | interior_contains (const Matrix< double, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks if the interior of this interval matrix contains the specified matrix x . | |
template<typename OtherDerived> | |
bool | interior_contains (const MatrixBase< OtherDerived > &x) const |
Template version to check interior containment of a matrix with arbitrary derived type. | |
template<typename T> | |
bool | _interior_contains (const T &x) const |
Internal helper function to check interior containment. | |
bool | is_unbounded () const |
Checks if the interval matrix contains any unbounded intervals. | |
bool | is_degenerated () const |
Checks if the interval matrix is degenerated. | |
bool | is_flat () const |
Checks if the interval matrix is flat. | |
bool | intersects (const Matrix< codac2::Interval, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks whether this matrix intersects with another matrix of intervals. | |
template<typename OtherDerived> | |
bool | intersects (const MatrixBase< OtherDerived > &x) const |
Checks whether this matrix intersects with another Eigen-compatible matrix. | |
template<typename OtherDerived> | |
bool | _intersects (const MatrixBase< OtherDerived > &x) const |
Internal helper that performs intersection checking. | |
bool | is_disjoint (const Matrix< codac2::Interval, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks if this matrix is disjoint with another matrix of intervals. | |
template<typename OtherDerived> | |
bool | is_disjoint (const MatrixBase< OtherDerived > &x) const |
Checks if this matrix is disjoint with another matrix of compatible type. | |
template<typename OtherDerived> | |
bool | _is_disjoint (const MatrixBase< OtherDerived > &x) const |
Internal helper for disjointness checking. | |
bool | overlaps (const Matrix< codac2::Interval, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks whether this matrix overlaps with another. | |
template<typename OtherDerived> | |
bool | overlaps (const MatrixBase< OtherDerived > &x) const |
Checks whether this matrix overlaps with another matrix of compatible type. | |
template<typename OtherDerived> | |
bool | _overlaps (const MatrixBase< OtherDerived > &x) const |
Internal helper to check overlap. | |
bool | is_subset (const Matrix< codac2::Interval, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks whether this matrix is a subset of another interval matrix. | |
template<typename OtherDerived> | |
bool | is_subset (const MatrixBase< OtherDerived > &x) const |
Checks whether this matrix is a subset of another matrix (Eigen-compatible). | |
template<typename T> | |
bool | _is_subset (const T &x) const |
Internal helper for subset check. | |
bool | is_strict_subset (const Matrix< codac2::Interval, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks whether this matrix is a strict subset of another matrix. | |
template<typename OtherDerived> | |
bool | is_strict_subset (const MatrixBase< OtherDerived > &x) const |
Checks whether this matrix is a strict subset of another matrix (Eigen-compatible). | |
template<typename T> | |
bool | _is_strict_subset (const T &x) const |
Internal helper for strict subset check. | |
bool | is_interior_subset (const Matrix< codac2::Interval, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks whether this matrix is an interior subset of another. | |
template<typename OtherDerived> | |
bool | is_interior_subset (const MatrixBase< OtherDerived > &x) const |
Checks whether this matrix is an interior subset of another matrix (Eigen-compatible). | |
template<typename OtherDerived> | |
bool | _is_interior_subset (const MatrixBase< OtherDerived > &x) const |
Internal helper for interior subset checking. | |
bool | is_strict_interior_subset (const Matrix< codac2::Interval, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks whether this matrix is a strict interior subset of another matrix. | |
template<typename OtherDerived> | |
bool | is_strict_interior_subset (const MatrixBase< OtherDerived > &x) const |
Checks whether this matrix is a strict interior subset of another Eigen-compatible matrix. | |
template<typename OtherDerived> | |
bool | _is_strict_interior_subset (const MatrixBase< OtherDerived > &x) const |
Internal helper for strict interior subset relation. | |
bool | is_superset (const Matrix< codac2::Interval, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks whether this matrix is a superset of another interval matrix. | |
template<typename OtherDerived> | |
bool | is_superset (const MatrixBase< OtherDerived > &x) const |
Checks whether this matrix is a superset of another Eigen-compatible matrix. | |
template<typename OtherDerived> | |
bool | _is_superset (const MatrixBase< OtherDerived > &x) const |
Internal helper for superset check. | |
bool | is_strict_superset (const Matrix< codac2::Interval, RowsAtCompileTime, ColsAtCompileTime > &x) const |
Checks whether this matrix is a strict superset of another matrix. | |
template<typename OtherDerived> | |
bool | is_strict_superset (const MatrixBase< OtherDerived > &x) const |
Checks whether this matrix is a strict superset of an Eigen-compatible matrix. | |
template<typename OtherDerived> | |
bool | _is_strict_superset (const MatrixBase< OtherDerived > &x) const |
Internal helper for strict superset check. | |
bool | is_bisectable () const |
Checks whether at least one interval in the matrix is bisectable. | |
This class reuses some of the functions developed for ibex::IntervalMatrixBase. The original IBEX code is revised in modern C++ and adapted to the template structure proposed in Codac, based on the Eigen library. See ibex::IntervalMatrixBase (IBEX lib, author: Gilles Chabert)
This file is included in the declaration of Eigen::MatrixBase, thanks to the preprocessor token EIGEN_MATRIXBASE_PLUGIN. See: https://eigen.tuxfamily.org/dox/TopicCustomizing_Plugins.html and the file codac2_matrices.h
|
inline |
Computes the volume of the interval matrix.
The volume is computed as the sum of the diameters of each interval element. If any interval is unbounded, returns positive infinity. If the matrix is empty or any interval is degenerated, returns 0.
|
inline |
Checks whether the interval matrix is empty.
An interval matrix is considered empty if any of its elements is empty.
true
if any element interval is empty, false
otherwise.
|
inline |
Returns a matrix containing the lower bounds of each interval element.
|
inline |
Returns a matrix containing the upper bounds of each interval element.
|
inline |
Returns a matrix containing the midpoints of each interval element.
The midpoint is the average of the lower and upper bounds.
|
inline |
Returns a matrix containing the magnitudes of each interval element.
The magnitude is max(|lower bound|, |upper bound|).
|
inline |
Returns a matrix containing the mignitudes of each interval element.
|
inline |
Returns a matrix with random values chosen inside each interval element.
Each element in the resulting matrix is a random number uniformly sampled inside the interval.
|
inline |
Returns a matrix containing the radii of each interval element.
The radius is half the diameter of the interval.
|
inline |
Returns a matrix containing the diameters of each interval element.
The diameter is the difference between upper and lower bounds.
|
inline |
Checks if this interval matrix contains the specified matrix x
.
This means every element of x
is contained in the corresponding interval element of this matrix.
x | The matrix to test for containment. |
true
if every element of x
is contained within the corresponding interval element.
|
inline |
Template version to check containment of a matrix with arbitrary derived type.
x | The matrix to test. |
true
if this interval matrix contains x
.
|
inline |
Checks if the interior of this interval matrix contains the specified matrix x
.
The interior containment means strict containment, not just boundary.
x | The matrix to test. |
true
if the interior of this matrix contains x
.
|
inline |
Template version to check interior containment of a matrix with arbitrary derived type.
x | The matrix to test. |
true
if interior contains x
.
|
inline |
Checks if the interval matrix contains any unbounded intervals.
true
if any interval element is unbounded, false
otherwise.
|
inline |
Checks if the interval matrix is degenerated.
An interval matrix is degenerated if all its elements are degenerated intervals.
true
if all interval elements are degenerated.
|
inline |
Checks if the interval matrix is flat.
A matrix is considered flat if at least one of its intervals is degenerated (i.e., has zero diameter), or if the matrix is empty.
true
if the matrix is empty or contains at least one degenerated interval.
|
inline |
Checks whether this matrix intersects with another matrix of intervals.
Intersection means that every corresponding interval pair from both matrices has a non-empty intersection.
x | A matrix of intervals of the same size. |
true
if all corresponding elements intersect, false
otherwise.
|
inline |
Checks whether this matrix intersects with another Eigen-compatible matrix.
x | The matrix to test for intersection. |
true
if all corresponding interval elements intersect, false
otherwise.
|
inline |
Checks if this matrix is disjoint with another matrix of intervals.
Disjoint means there exists at least one interval pair that does not intersect.
x | A matrix of intervals. |
true
if at least one pair of intervals is disjoint, false
otherwise.
|
inline |
Checks if this matrix is disjoint with another matrix of compatible type.
x | The matrix to test. |
true
if at least one pair of corresponding intervals is disjoint, false
otherwise.
|
inline |
Checks whether this matrix overlaps with another.
Overlap requires that all interval pairs overlap.
x | The matrix of intervals to test overlap against. |
true
if all corresponding intervals overlap.
|
inline |
Checks whether this matrix overlaps with another matrix of compatible type.
x | The matrix to test overlap against. |
true
if all interval pairs overlap.
|
inline |
Checks whether this matrix is a subset of another interval matrix.
Each interval element of this matrix must be a subset of the corresponding interval in x
. An empty matrix is considered a subset of any matrix of the same size.
x | A matrix of intervals. |
true
if all elements of this matrix are subsets of those in x
.
|
inline |
Checks whether this matrix is a subset of another matrix (Eigen-compatible).
x | The matrix to check against. |
true
if all elements are subsets.
|
inline |
Checks whether this matrix is a strict subset of another matrix.
A strict subset means it is a subset and at least one element is strictly contained (not equal).
x | The matrix to compare to. |
true
if this matrix is strictly contained in x
.
|
inline |
Checks whether this matrix is a strict subset of another matrix (Eigen-compatible).
x | The matrix to compare to. |
true
if strictly contained.
|
inline |
Checks whether this matrix is an interior subset of another.
Every interval in this matrix must be strictly inside (in the interior of) the corresponding one in x
.
x | The matrix to check against. |
true
if this matrix is an interior subset of x
.
|
inline |
Checks whether this matrix is an interior subset of another matrix (Eigen-compatible).
x | The matrix to compare with. |
true
if each element is in the interior of the corresponding one in x
.
|
inline |
Checks whether this matrix is a strict interior subset of another matrix.
A strict interior subset means that each interval in this matrix lies strictly within the interior of the corresponding interval in x
.
x | The matrix to compare against. |
true
if every interval in this matrix is strictly inside the corresponding interval in x
.
|
inline |
Checks whether this matrix is a strict interior subset of another Eigen-compatible matrix.
x | The matrix to compare with. |
true
if all intervals are strictly inside the corresponding intervals in x
.
|
inline |
Checks whether this matrix is a superset of another interval matrix.
This means that each interval in this matrix fully contains the corresponding interval in x
.
x | The matrix to compare with. |
true
if every interval in this matrix is a superset of the corresponding one in x
.
|
inline |
Checks whether this matrix is a superset of another Eigen-compatible matrix.
x | The matrix to compare to. |
true
if this matrix fully contains all intervals of x
.
|
inline |
Checks whether this matrix is a strict superset of another matrix.
A strict superset means that each interval contains the corresponding one in x
, and at least one interval strictly contains its counterpart.
x | The matrix to compare against. |
true
if this matrix strictly contains the other matrix.
|
inline |
Checks whether this matrix is a strict superset of an Eigen-compatible matrix.
x | The matrix to compare with. |
true
if this matrix strictly contains the other matrix.
|
inline |
Checks whether at least one interval in the matrix is bisectable.
true
if at least one element in the matrix satisfies that condition