GTSAM  4.0.2
C++ library for smoothing and mapping (SAM)
Classes | Namespaces | Macros | Typedefs | Functions
Matrix.h File Reference

typedef and functions to augment Eigen's MatrixXd More...

#include <gtsam/base/OptionalJacobian.h>
#include <gtsam/base/Vector.h>
#include <vector>
Include dependency graph for Matrix.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  gtsam::Reshape< OutM, OutN, OutOptions, InM, InN, InOptions >
 Reshape functor. More...
 
struct  gtsam::Reshape< M, M, InOptions, M, M, InOptions >
 Reshape specialization that does nothing as shape stays the same (needed to not be ambiguous for square input equals square output) More...
 
struct  gtsam::Reshape< M, N, InOptions, M, N, InOptions >
 Reshape specialization that does nothing as shape stays the same. More...
 
struct  gtsam::Reshape< N, M, InOptions, M, N, InOptions >
 Reshape specialization that does transpose. More...
 
struct  gtsam::MultiplyWithInverse< N >
 
struct  gtsam::MultiplyWithInverseFunction< T, N >
 

Namespaces

 gtsam
 

Macros

#define GTSAM_MAKE_MATRIX_DEFS(N)
 

Typedefs

typedef Eigen::MatrixXd gtsam::Matrix
 
typedef Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic, Eigen::RowMajor > gtsam::MatrixRowMajor
 
typedef Eigen::Block< Matrix > gtsam::SubMatrix
 
typedef Eigen::Block< const Matrix > gtsam::ConstSubMatrix
 

Functions

const Eigen::IOFormat & gtsam::matlabFormat ()
 
template<class MATRIX >
bool gtsam::equal_with_abs_tol (const Eigen::DenseBase< MATRIX > &A, const Eigen::DenseBase< MATRIX > &B, double tol=1e-9)
 
bool gtsam::operator== (const Matrix &A, const Matrix &B)
 
bool gtsam::operator!= (const Matrix &A, const Matrix &B)
 
GTSAM_EXPORT bool gtsam::assert_equal (const Matrix &A, const Matrix &B, double tol=1e-9)
 
GTSAM_EXPORT bool gtsam::assert_inequal (const Matrix &A, const Matrix &B, double tol=1e-9)
 
GTSAM_EXPORT bool gtsam::assert_equal (const std::list< Matrix > &As, const std::list< Matrix > &Bs, double tol=1e-9)
 
GTSAM_EXPORT bool gtsam::linear_independent (const Matrix &A, const Matrix &B, double tol=1e-9)
 
GTSAM_EXPORT bool gtsam::linear_dependent (const Matrix &A, const Matrix &B, double tol=1e-9)
 
GTSAM_EXPORT Vector gtsam::operator^ (const Matrix &A, const Vector &v)
 
template<class MATRIX >
MATRIX gtsam::prod (const MATRIX &A, const MATRIX &B)
 
GTSAM_EXPORT void gtsam::print (const Matrix &A, const std::string &s, std::ostream &stream)
 
GTSAM_EXPORT void gtsam::print (const Matrix &A, const std::string &s="")
 
GTSAM_EXPORT void gtsam::save (const Matrix &A, const std::string &s, const std::string &filename)
 
GTSAM_EXPORT std::istream & gtsam::operator>> (std::istream &inputStream, Matrix &destinationMatrix)
 
template<class MATRIX >
Eigen::Block< const MATRIX > gtsam::sub (const MATRIX &A, size_t i1, size_t i2, size_t j1, size_t j2)
 
template<typename Derived1 , typename Derived2 >
void gtsam::insertSub (Eigen::MatrixBase< Derived1 > &fullMatrix, const Eigen::MatrixBase< Derived2 > &subMatrix, size_t i, size_t j)
 
GTSAM_EXPORT Matrix gtsam::diag (const std::vector< Matrix > &Hs)
 
template<class MATRIX >
const MATRIX::ConstColXpr gtsam::column (const MATRIX &A, size_t j)
 
template<class MATRIX >
const MATRIX::ConstRowXpr gtsam::row (const MATRIX &A, size_t j)
 
template<class MATRIX >
void gtsam::zeroBelowDiagonal (MATRIX &A, size_t cols=0)
 
Matrix gtsam::trans (const Matrix &A)
 
template<int OutM, int OutN, int OutOptions, int InM, int InN, int InOptions>
Reshape< OutM, OutN, OutOptions, InM, InN, InOptions >::ReshapedType gtsam::reshape (const Eigen::Matrix< double, InM, InN, InOptions > &m)
 
GTSAM_EXPORT std::pair< Matrix, Matrix > gtsam::qr (const Matrix &A)
 
GTSAM_EXPORT void gtsam::inplace_QR (Matrix &A)
 
GTSAM_EXPORT std::list< std::tuple< Vector, double, double > > gtsam::weighted_eliminate (Matrix &A, Vector &b, const Vector &sigmas)
 
GTSAM_EXPORT void gtsam::householder_ (Matrix &A, size_t k, bool copy_vectors=true)
 
GTSAM_EXPORT void gtsam::householder (Matrix &A, size_t k)
 
GTSAM_EXPORT Vector gtsam::backSubstituteUpper (const Matrix &U, const Vector &b, bool unit=false)
 
GTSAM_EXPORT Vector gtsam::backSubstituteUpper (const Vector &b, const Matrix &U, bool unit=false)
 
GTSAM_EXPORT Vector gtsam::backSubstituteLower (const Matrix &L, const Vector &b, bool unit=false)
 
GTSAM_EXPORT Matrix gtsam::stack (size_t nrMatrices,...)
 
GTSAM_EXPORT Matrix gtsam::stack (const std::vector< Matrix > &blocks)
 
GTSAM_EXPORT Matrix gtsam::collect (const std::vector< const Matrix *> &matrices, size_t m=0, size_t n=0)
 
GTSAM_EXPORT Matrix gtsam::collect (size_t nrMatrices,...)
 
GTSAM_EXPORT void gtsam::vector_scale_inplace (const Vector &v, Matrix &A, bool inf_mask=false)
 
GTSAM_EXPORT Matrix gtsam::vector_scale (const Vector &v, const Matrix &A, bool inf_mask=false)
 
GTSAM_EXPORT Matrix gtsam::vector_scale (const Matrix &A, const Vector &v, bool inf_mask=false)
 
Matrix3 gtsam::skewSymmetric (double wx, double wy, double wz)
 
template<class Derived >
Matrix3 gtsam::skewSymmetric (const Eigen::MatrixBase< Derived > &w)
 
GTSAM_EXPORT Matrix gtsam::inverse_square_root (const Matrix &A)
 
GTSAM_EXPORT Matrix gtsam::cholesky_inverse (const Matrix &A)
 
GTSAM_EXPORT void gtsam::svd (const Matrix &A, Matrix &U, Vector &S, Matrix &V)
 
GTSAM_EXPORT std::tuple< int, double, Vector > gtsam::DLT (const Matrix &A, double rank_tol=1e-9)
 
GTSAM_EXPORT Matrix gtsam::expm (const Matrix &A, size_t K=7)
 
std::string gtsam::formatMatrixIndented (const std::string &label, const Matrix &matrix, bool makeVectorHorizontal=false)
 
GTSAM_EXPORT Matrix gtsam::LLt (const Matrix &A)
 
GTSAM_EXPORT Matrix gtsam::RtR (const Matrix &A)
 
GTSAM_EXPORT Vector gtsam::columnNormSquare (const Matrix &A)
 

Detailed Description

typedef and functions to augment Eigen's MatrixXd

Author
Christian Potthast
Kai Ni
Frank Dellaert
Alex Cunningham
Alex Hagiopol
Varun Agrawal

Macro Definition Documentation

◆ GTSAM_MAKE_MATRIX_DEFS

#define GTSAM_MAKE_MATRIX_DEFS (   N)
Value:
using Matrix##N = Eigen::Matrix<double, N, N>; \
using Matrix1##N = Eigen::Matrix<double, 1, N>; \
using Matrix2##N = Eigen::Matrix<double, 2, N>; \
using Matrix3##N = Eigen::Matrix<double, 3, N>; \
using Matrix4##N = Eigen::Matrix<double, 4, N>; \
using Matrix5##N = Eigen::Matrix<double, 5, N>; \
using Matrix6##N = Eigen::Matrix<double, 6, N>; \
using Matrix7##N = Eigen::Matrix<double, 7, N>; \
using Matrix8##N = Eigen::Matrix<double, 8, N>; \
using Matrix9##N = Eigen::Matrix<double, 9, N>; \
static const Eigen::MatrixBase<Matrix##N>::IdentityReturnType I_##N##x##N = Matrix##N::Identity(); \
static const Eigen::MatrixBase<Matrix##N>::ConstantReturnType Z_##N##x##N = Matrix##N::Zero();