Main MRPT website > C++ reference for MRPT 1.5.7
List of all members | Public Member Functions | Public Attributes | Private Attributes
mrpt::poses::SO_average< 3 > Class Template Reference

Detailed Description

template<>
class mrpt::poses::SO_average< 3 >

Computes weighted and un-weighted averages of SO(3) orientations.

Add values to average with append(), when done call get_average(). Use clear() to reset the accumulator and start a new average computation. Theoretical base: Average on SO(3) manifolds is computed by averaging the corresponding matrices, then projecting the result back to the closest matrix in the manifold. Shortly explained in these slides See also: eq. (3.7) in "MEANS AND AVERAGING IN THE GROUP OF ROTATIONS", MAHER MOAKHER, 2002.

Note
Class introduced in MRPT 1.3.1
See also
SE_traits

Definition at line 64 of file SO_SE_average.h.

#include <mrpt/poses/SO_SE_average.h>

Public Member Functions

 SO_average ()
 Constructor. More...
 
void clear ()
 Resets the accumulator. More...
 
void append (const Eigen::Matrix3d &M)
 Adds a new orientation to the computation. More...
 
void append (const Eigen::Matrix3d &M, const double weight)
 Adds a new orientation to the weighted-average computation. More...
 
Eigen::Matrix3d get_average () const
 Returns the average orientation. More...
 

Public Attributes

bool enable_exception_on_undeterminate
 (Default=false) Set to true if you want to raise an exception on undetermined average values. More...
 

Private Attributes

double m_count
 
Eigen::Matrix3d m_accum_rot
 

Constructor & Destructor Documentation

◆ SO_average()

mrpt::poses::SO_average< 3 >::SO_average ( )

Constructor.

Member Function Documentation

◆ append() [1/2]

void mrpt::poses::SO_average< 3 >::append ( const Eigen::Matrix3d &  M)

Adds a new orientation to the computation.

See also
get_average

Referenced by run_test_so3_avrg().

◆ append() [2/2]

void mrpt::poses::SO_average< 3 >::append ( const Eigen::Matrix3d &  M,
const double  weight 
)

Adds a new orientation to the weighted-average computation.

See also
get_average

◆ clear()

void mrpt::poses::SO_average< 3 >::clear ( )

Resets the accumulator.

◆ get_average()

Eigen::Matrix3d mrpt::poses::SO_average< 3 >::get_average ( ) const

Returns the average orientation.

Exceptions
std::logic_errorIf no data point were inserted.
std::runtime_errorUpon undeterminate average value (ie there was a problem with the SVD) and enable_exception_on_undeterminate is set to true (otherwise, the 0 orientation would be returned)
See also
append

Referenced by run_test_so3_avrg().

Member Data Documentation

◆ enable_exception_on_undeterminate

bool mrpt::poses::SO_average< 3 >::enable_exception_on_undeterminate

(Default=false) Set to true if you want to raise an exception on undetermined average values.

Definition at line 76 of file SO_SE_average.h.

◆ m_accum_rot

Eigen::Matrix3d mrpt::poses::SO_average< 3 >::m_accum_rot
private

Definition at line 79 of file SO_SE_average.h.

◆ m_count

double mrpt::poses::SO_average< 3 >::m_count
private

Definition at line 78 of file SO_SE_average.h.




Page generated by Doxygen 1.8.14 for MRPT 1.5.7 Git: 5902e14cc Wed Apr 24 15:04:01 2019 +0200 at lun oct 28 01:39:17 CET 2019