LocalGuidance
A library that generates velocity references to follow a path.
robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ > Class Template Reference

#include <DiscreteTimeTransferFunction.hpp>

Inheritance diagram for robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >:
Inheritance graph

Public Types

using CoefficientArray = std::array< double, Size_ >
 

Public Member Functions

 DiscreteTimeTransferFunction ()=default
 
 DiscreteTimeTransferFunction (const CoefficientArray &numeratorCoefficients, const CoefficientArray &denominatorCoefficients, const ValueType_ &y0=getDefaultValue< ValueType_ >())
 
virtual ~DiscreteTimeTransferFunction ()=default
 
 EIGEN_MAKE_ALIGNED_OPERATOR_NEW_IF (traits::is_eigen_matrix< ValueType_ >::value) inline void setCoefficients(const CoefficientArray &numeratorCoefficients
 

Public Attributes

const CoefficientArraydenominatorCoefficients
 
const CoefficientArray const ValueType_ & y0
 
const CoefficientArray const ValueType_ Size_ input_
 
std::array< ValueType_, Size_output_
 
CoefficientArray numeratorCoefficients_
 
CoefficientArray denominatorCoefficients_
 
double invA_n_ = 1.0
 

Static Public Attributes

static constexpr unsigned int Size_ = Order_+1
 

Detailed Description

template<typename ValueType_, unsigned int Order_>
class robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >

This class implements a generic discrete time (DT) transfer function.

             b_0 + b_1 * z + b_2 * z^2 + ... + b_n * z^n

G(z) = ------------------------------------------— a_0 + a_1 * z + a_2 * z^2 + ... + a_n * z^n

The number of coefficients (n) in the numerator and denominator has to be equal. It is up to the user to fill unused entries with 0.

Member Typedef Documentation

template<typename ValueType_ , unsigned int Order_>
using robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::CoefficientArray = std::array<double, Size_>

Constructor & Destructor Documentation

template<typename ValueType_ , unsigned int Order_>
robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::DiscreteTimeTransferFunction ( )
explicitdefault
template<typename ValueType_ , unsigned int Order_>
robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::DiscreteTimeTransferFunction ( const CoefficientArray numeratorCoefficients,
const CoefficientArray denominatorCoefficients,
const ValueType_ &  y0 = getDefaultValue<ValueType_>() 
)
inlineexplicit
Parameters
numeratorCoefficientsThe numerator coefficients b_0, ..., b_n
denominatorCoefficientsThe denominator coefficients a_0, ..., a_n
y0Default value to initialize the inputs and outputs to
template<typename ValueType_ , unsigned int Order_>
virtual robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::~DiscreteTimeTransferFunction ( )
virtualdefault

Member Function Documentation

template<typename ValueType_ , unsigned int Order_>
robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::EIGEN_MAKE_ALIGNED_OPERATOR_NEW_IF ( traits::is_eigen_matrix< ValueType_ >::value  ) const

Set transfer function coefficients, normalize them if necessary and reset its states

Parameters
numeratorCoefficientsThe numerator coefficients b_0, ..., b_n
denominatorCoefficientsThe denominator coefficients a_0, ..., a_n
y0Default value to initialize the inputs and outputs to

Member Data Documentation

template<typename ValueType_ , unsigned int Order_>
const CoefficientArray& robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::denominatorCoefficients
template<typename ValueType_ , unsigned int Order_>
CoefficientArray robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::denominatorCoefficients_
template<typename ValueType_ , unsigned int Order_>
const CoefficientArray const ValueType_ Size_ robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::input_
template<typename ValueType_ , unsigned int Order_>
double robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::invA_n_ = 1.0
template<typename ValueType_ , unsigned int Order_>
CoefficientArray robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::numeratorCoefficients_
template<typename ValueType_ , unsigned int Order_>
std::array<ValueType_, Size_> robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::output_
template<typename ValueType_ , unsigned int Order_>
constexpr unsigned int robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::Size_ = Order_+1
static
template<typename ValueType_ , unsigned int Order_>
const CoefficientArray const ValueType_& robot_utils::DiscreteTimeTransferFunction< ValueType_, Order_ >::y0

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