EmrysFilter 0.1.0
State estimation utilities in C++23 using Eigen
Loading...
Searching...
No Matches
Emrys::Repeated< Block, MaxCount_ > Class Template Reference

A fixed-size Block repeated count() times, up to MaxCount_, such as one block per vehicle. More...

#include <EmrysFilter/Spaces/Composite.h>

Public Types

using BlockType = Block
 The repeated block's type.

Public Member Functions

 Repeated (Block block, Eigen::Index count=0)
 count repetitions of block.
Block const & block () const
Eigen::Index count () const
Eigen::Index valueDimension () const
void setCount (Eigen::Index count)
 Sets the number of repetitions to count, at most MaxCount.
void resize (Eigen::Index n)
 Resizes to n coordinates, a whole number of repetitions.
template<typename Derived>
requires (internal::HasNormalize<Block>)
void normalize (Eigen::MatrixBase< Derived > const &rows) const
 Normalizes each repetition; a repeated block without normalize() has none.
template<typename X, typename D, typename Out>
requires (internal::HasPlus<Block>)
void plus (Eigen::MatrixBase< X > const &x, Eigen::MatrixBase< D > const &d, Eigen::MatrixBase< Out > const &out) const
 \( x \boxplus \delta \) for each repetition, for a block with its own plus().
template<typename A, typename B, typename Out>
requires (internal::HasMinus<Block>)
void minus (Eigen::MatrixBase< A > const &a, Eigen::MatrixBase< B > const &b, Eigen::MatrixBase< Out > const &out) const
 \( a \boxminus b \) for each repetition, for a block with its own minus().
Repeated< DifferenceSpace< Block >, MaxCount_ > difference () const
 The block's difference space, repeated as many times.

Static Public Attributes

static constexpr int MaxCount = MaxCount_
 Maximum number of repetitions, or Eigen::Dynamic if unbounded.
static constexpr int FixedValueDimension = 0
 nothing is fixed: every coordinate belongs to a repetition
static constexpr int ValueDimensionStep = Block::FixedValueDimension
 the coordinates of one repetition
static constexpr int MaxValueDimension
 MaxCount repetitions' worth of coordinates, or Eigen::Dynamic if unbounded.

Friends

bool operator== (Repeated const &, Repeated const &)=default
 Equal when every stored parameter and size is; a fixed-size Repeated is always equal.

Detailed Description

template<Space Block, int MaxCount_ = Eigen::Dynamic>
class Emrys::Repeated< Block, MaxCount_ >

A fixed-size Block repeated count() times, up to MaxCount_, such as one block per vehicle.

Its size is count() times the block's size. Every repetition shares the block's parameters (periods and bounds). A tag derived from it can inherit its constructors to start with a count: struct Vehicles : Repeated<Vehicle> { using Repeated::Repeated; };, then Vehicles{Vehicle{}, 3}.

Member Function Documentation

◆ block()

template<Space Block, int MaxCount_ = Eigen::Dynamic>
Block const & Emrys::Repeated< Block, MaxCount_ >::block ( ) const
inlinenodiscard
Returns
the repeated block, with its parameters

◆ count()

template<Space Block, int MaxCount_ = Eigen::Dynamic>
Eigen::Index Emrys::Repeated< Block, MaxCount_ >::count ( ) const
inlinenodiscard
Returns
the number of repetitions

◆ difference()

template<Space Block, int MaxCount_ = Eigen::Dynamic>
Repeated< DifferenceSpace< Block >, MaxCount_ > Emrys::Repeated< Block, MaxCount_ >::difference ( ) const
inlinenodiscard

The block's difference space, repeated as many times.

It keeps no tags.

◆ valueDimension()

template<Space Block, int MaxCount_ = Eigen::Dynamic>
Eigen::Index Emrys::Repeated< Block, MaxCount_ >::valueDimension ( ) const
inlinenodiscard
Returns
the number of coordinates: count() repetitions of ValueDimensionStep

Member Data Documentation

◆ MaxValueDimension

template<Space Block, int MaxCount_ = Eigen::Dynamic>
int Emrys::Repeated< Block, MaxCount_ >::MaxValueDimension
staticconstexpr
Initial value:
=
MaxCount == Eigen::Dynamic ? Eigen::Dynamic : MaxCount * Block::FixedValueDimension
static constexpr int MaxCount
Maximum number of repetitions, or Eigen::Dynamic if unbounded.
Definition Composite.h:429

MaxCount repetitions' worth of coordinates, or Eigen::Dynamic if unbounded.


The documentation for this class was generated from the following file: