|
glucat
0.8.4
|
A matrix_multi<Scalar_T,LO,HI> is a matrix approximation to a multivector. More...
#include <matrix_multi.h>

Public Types | |
| typedef matrix_multi | multivector_t |
| typedef multivector_t | matrix_multi_t |
| typedef Scalar_T | scalar_t |
| typedef index_set< LO, HI > | index_set_t |
| typedef std::pair< const index_set_t, Scalar_T > | term_t |
| typedef std::vector< Scalar_T > | vector_t |
| typedef error< multivector_t > | error_t |
| typedef framed_multi< Scalar_T, LO, HI > | framed_multi_t |
Public Member Functions | |
| ~matrix_multi () | |
| Destructor. More... | |
| matrix_multi () | |
| Default constructor. More... | |
| template<typename Other_Scalar_T > | |
| matrix_multi (const matrix_multi< Other_Scalar_T, LO, HI > &val) | |
| Construct a multivector from a multivector with a different scalar type. More... | |
| template<typename Other_Scalar_T > | |
| matrix_multi (const matrix_multi< Other_Scalar_T, LO, HI > &val, const index_set_t frm, const bool prechecked=false) | |
| Construct a multivector, within a given frame, from a given multivector. More... | |
| matrix_multi (const multivector_t &val, const index_set_t frm, const bool prechecked=false) | |
| Construct a multivector, within a given frame, from a given multivector. More... | |
| matrix_multi (const index_set_t ist, const Scalar_T &crd=Scalar_T(1)) | |
| Construct a multivector from an index set and a scalar coordinate. More... | |
| matrix_multi (const index_set_t ist, const Scalar_T &crd, const index_set_t frm, const bool prechecked=false) | |
| Construct a multivector, within a given frame, from an index set and a scalar coordinate. More... | |
| matrix_multi (const Scalar_T &scr, const index_set_t frm=index_set_t()) | |
| Construct a multivector from a scalar (within a frame, if given) More... | |
| matrix_multi (const int scr, const index_set_t frm=index_set_t()) | |
| Construct a multivector from an int (within a frame, if given) More... | |
| matrix_multi (const vector_t &vec, const index_set_t frm, const bool prechecked=false) | |
| Construct a multivector, within a given frame, from a given vector. More... | |
| matrix_multi (const std::string &str) | |
| Construct a multivector from a string: eg: "3+2{1,2}-6.1e-2{2,3}". More... | |
| matrix_multi (const std::string &str, const index_set_t frm, const bool prechecked=false) | |
| Construct a multivector, within a given frame, from a string: eg: "3+2{1,2}-6.1e-2{2,3}". More... | |
| matrix_multi (const char *str) | |
| Construct a multivector from a char*: eg: "3+2{1,2}-6.1e-2{2,3}". More... | |
| matrix_multi (const char *str, const index_set_t frm, const bool prechecked=false) | |
| Construct a multivector, within a given frame, from a char*: eg: "3+2{1,2}-6.1e-2{2,3}". More... | |
| template<typename Other_Scalar_T > | |
| matrix_multi (const framed_multi< Other_Scalar_T, LO, HI > &val) | |
| Construct a multivector from a framed_multi_t. More... | |
| template<typename Other_Scalar_T > | |
| matrix_multi (const framed_multi< Other_Scalar_T, LO, HI > &val, const index_set_t frm, const bool prechecked=false) | |
| Construct a multivector, within a given frame, from a framed_multi_t. More... | |
| const matrix_multi_t | fast_matrix_multi (const index_set_t frm) const |
| Use generalized FFT to construct a matrix_multi_t. More... | |
| template<typename Other_Scalar_T > | |
| const framed_multi< Other_Scalar_T, LO, HI > | fast_framed_multi () const |
| Use inverse generalized FFT to construct a framed_multi_t. More... | |
| _GLUCAT_CLIFFORD_ALGEBRA_OPERATIONS multivector_t & | operator= (const multivector_t &rhs) |
| Assignment operator. More... | |
| multivector_t & | operator+= (const term_t &rhs) |
| Add a term, if non-zero. More... | |
Static Public Member Functions | |
| static const std::string | classname () |
| Class name used in messages. More... | |
| static const matrix_multi_t | random (const index_set_t frm, Scalar_T fill=Scalar_T(1)) |
| Random multivector within a frame. More... | |
Private Types | |
| typedef ublas::row_major | orientation_t |
| typedef ublas::compressed_matrix< int, orientation_t > | basis_matrix_t |
| typedef ublas::compressed_matrix< Scalar_T, orientation_t > | matrix_t |
| typedef matrix_t::size_type | matrix_index_t |
Private Member Functions | |
| template<typename Matrix_T > | |
| matrix_multi (const Matrix_T &mtx, const index_set_t frm) | |
| Construct a multivector within a given frame from a given matrix. More... | |
| matrix_multi (const matrix_t &mtx, const index_set_t frm) | |
| Construct a multivector within a given frame from a given matrix. More... | |
| const basis_matrix_t | basis_element (const index_set< LO, HI > &ist) const |
| Create a basis element matrix within the current frame. More... | |
Private Attributes | |
| index_set_t | m_frame |
| Index set representing the frame for the subalgebra which contains the multivector. More... | |
| matrix_t | m_matrix |
| Matrix value representing the multivector within the folded frame. More... | |
Friends | |
| template<typename Other_Scalar_T , const index_t Other_LO, const index_t Other_HI> | |
| class | framed_multi |
| template<typename Other_Scalar_T , const index_t Other_LO, const index_t Other_HI> | |
| class | matrix_multi |
| const matrix_multi_t | operator* (const matrix_multi_t &lhs, const matrix_multi_t &rhs) |
| const matrix_multi_t | operator^ (const matrix_multi_t &lhs, const matrix_multi_t &rhs) |
| const matrix_multi_t | operator& (const matrix_multi_t &lhs, const matrix_multi_t &rhs) |
| const matrix_multi_t | operator% (const matrix_multi_t &lhs, const matrix_multi_t &rhs) |
| Scalar_T | star (const matrix_multi_t &lhs, const matrix_multi_t &rhs) |
| const matrix_multi_t | operator/ (const matrix_multi_t &lhs, const matrix_multi_t &rhs) |
| const matrix_multi_t | operator| (const matrix_multi_t &lhs, const matrix_multi_t &rhs) |
| std::istream & | operator>> (std::istream &s, multivector_t &val) |
| std::ostream & | operator<< (std::ostream &os, const multivector_t &val) |
| std::ostream & | operator<< (std::ostream &os, const term_t &term) |
| template<typename Other_Scalar_T , const index_t Other_LO, const index_t Other_HI> | |
| const index_set< Other_LO, Other_HI > | reframe (const matrix_multi< Other_Scalar_T, Other_LO, Other_HI > &lhs, const matrix_multi< Other_Scalar_T, Other_LO, Other_HI > &rhs, matrix_multi< Other_Scalar_T, Other_LO, Other_HI > &lhs_reframed, matrix_multi< Other_Scalar_T, Other_LO, Other_HI > &rhs_reframed) |
| template<typename Other_Scalar_T , const index_t Other_LO, const index_t Other_HI> | |
| const matrix_multi< Other_Scalar_T, Other_LO, Other_HI > | matrix_sqrt (const matrix_multi< Other_Scalar_T, Other_LO, Other_HI > &val, const matrix_multi< Other_Scalar_T, Other_LO, Other_HI > &i) |
| template<typename Other_Scalar_T , const index_t Other_LO, const index_t Other_HI> | |
| const matrix_multi< Other_Scalar_T, Other_LO, Other_HI > | matrix_log (const matrix_multi< Other_Scalar_T, Other_LO, Other_HI > &val, const matrix_multi< Other_Scalar_T, Other_LO, Other_HI > &i) |
A matrix_multi<Scalar_T,LO,HI> is a matrix approximation to a multivector.
Definition at line 132 of file matrix_multi.h.
|
private |
Definition at line 152 of file matrix_multi.h.
| typedef error<multivector_t> glucat::matrix_multi< Scalar_T, LO, HI >::error_t |
Definition at line 142 of file matrix_multi.h.
| typedef framed_multi<Scalar_T,LO,HI> glucat::matrix_multi< Scalar_T, LO, HI >::framed_multi_t |
Definition at line 143 of file matrix_multi.h.
| typedef index_set<LO,HI> glucat::matrix_multi< Scalar_T, LO, HI >::index_set_t |
Definition at line 139 of file matrix_multi.h.
|
private |
Definition at line 159 of file matrix_multi.h.
| typedef multivector_t glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi_t |
Definition at line 137 of file matrix_multi.h.
|
private |
Definition at line 157 of file matrix_multi.h.
| typedef matrix_multi glucat::matrix_multi< Scalar_T, LO, HI >::multivector_t |
Definition at line 136 of file matrix_multi.h.
|
private |
Definition at line 150 of file matrix_multi.h.
| typedef Scalar_T glucat::matrix_multi< Scalar_T, LO, HI >::scalar_t |
Definition at line 138 of file matrix_multi.h.
| typedef std::pair<const index_set_t, Scalar_T> glucat::matrix_multi< Scalar_T, LO, HI >::term_t |
Definition at line 140 of file matrix_multi.h.
| typedef std::vector<Scalar_T> glucat::matrix_multi< Scalar_T, LO, HI >::vector_t |
Definition at line 141 of file matrix_multi.h.
|
inline |
Destructor.
Definition at line 165 of file matrix_multi.h.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi |
Default constructor.
Definition at line 99 of file matrix_multi_imp.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const matrix_multi< Other_Scalar_T, LO, HI > & | val | ) |
Construct a multivector from a multivector with a different scalar type.
Definition at line 108 of file matrix_multi_imp.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix, and glucat::numeric_traits< Scalar_T >::to_scalar_t().
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const matrix_multi< Other_Scalar_T, LO, HI > & | val, |
| const index_set_t | frm, | ||
| const bool | prechecked = false |
||
| ) |
Construct a multivector, within a given frame, from a given multivector.
Definition at line 130 of file matrix_multi_imp.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::m_frame, glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix, and glucat::numeric_traits< Scalar_T >::to_scalar_t().
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const multivector_t & | val, |
| const index_set_t | frm, | ||
| const bool | prechecked = false |
||
| ) |
Construct a multivector, within a given frame, from a given multivector.
Definition at line 158 of file matrix_multi_imp.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::m_frame, and glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const index_set_t | ist, |
| const Scalar_T & | crd = Scalar_T(1) |
||
| ) |
Construct a multivector from an index set and a scalar coordinate.
Definition at line 170 of file matrix_multi_imp.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::m_frame, and glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const index_set_t | ist, |
| const Scalar_T & | crd, | ||
| const index_set_t | frm, | ||
| const bool | prechecked = false |
||
| ) |
Construct a multivector, within a given frame, from an index set and a scalar coordinate.
Definition at line 182 of file matrix_multi_imp.h.
References PyClical::ist, and glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const Scalar_T & | scr, |
| const index_set_t | frm = index_set_t() |
||
| ) |
Construct a multivector from a scalar (within a frame, if given)
Definition at line 196 of file matrix_multi_imp.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const int | scr, |
| const index_set_t | frm = index_set_t() |
||
| ) |
Construct a multivector from an int (within a frame, if given)
Definition at line 208 of file matrix_multi_imp.h.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const vector_t & | vec, |
| const index_set_t | frm, | ||
| const bool | prechecked = false |
||
| ) |
Construct a multivector, within a given frame, from a given vector.
Definition at line 214 of file matrix_multi_imp.h.
References glucat::index_set< LO, HI >::count(), glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix, glucat::index_set< LO, HI >::max(), and glucat::index_set< LO, HI >::min().
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const std::string & | str | ) |
Construct a multivector from a string: eg: "3+2{1,2}-6.1e-2{2,3}".
Definition at line 241 of file matrix_multi_imp.h.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const std::string & | str, |
| const index_set_t | frm, | ||
| const bool | prechecked = false |
||
| ) |
Construct a multivector, within a given frame, from a string: eg: "3+2{1,2}-6.1e-2{2,3}".
Definition at line 247 of file matrix_multi_imp.h.
|
inline |
Construct a multivector from a char*: eg: "3+2{1,2}-6.1e-2{2,3}".
Definition at line 196 of file matrix_multi.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi.
|
inline |
Construct a multivector, within a given frame, from a char*: eg: "3+2{1,2}-6.1e-2{2,3}".
Definition at line 199 of file matrix_multi.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const framed_multi< Other_Scalar_T, LO, HI > & | val | ) |
Construct a multivector from a framed_multi_t.
Definition at line 254 of file matrix_multi_imp.h.
References PyClical::e(), glucat::tuning< Mult_Matrix_Threshold, Div_Max_Steps, Sqrt_Max_Steps, Log_Max_Outer_Steps, Log_Max_Inner_Steps, Basis_Max_Count, Fast_Size_Threshold, Inv_Fast_Dim_Threshold, Products_Size_Threshold, Function_Precision >::fast_size_threshold, glucat::matrix_multi< Scalar_T, LO, HI >::m_frame, and glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix.
| glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi | ( | const framed_multi< Other_Scalar_T, LO, HI > & | val, |
| const index_set_t | frm, | ||
| const bool | prechecked = false |
||
| ) |
Construct a multivector, within a given frame, from a framed_multi_t.
Definition at line 281 of file matrix_multi_imp.h.
References PyClical::e(), and glucat::tuning< Mult_Matrix_Threshold, Div_Max_Steps, Sqrt_Max_Steps, Log_Max_Outer_Steps, Log_Max_Inner_Steps, Basis_Max_Count, Fast_Size_Threshold, Inv_Fast_Dim_Threshold, Products_Size_Threshold, Function_Precision >::fast_size_threshold.
|
private |
Construct a multivector within a given frame from a given matrix.
Definition at line 309 of file matrix_multi_imp.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix, and glucat::numeric_traits< Scalar_T >::to_scalar_t().
|
private |
Construct a multivector within a given frame from a given matrix.
Definition at line 330 of file matrix_multi_imp.h.
|
private |
Create a basis element matrix within the current frame.
Definition at line 1245 of file matrix_multi_imp.h.
References glucat::tuning< Mult_Matrix_Threshold, Div_Max_Steps, Sqrt_Max_Steps, Log_Max_Outer_Steps, Log_Max_Inner_Steps, Basis_Max_Count, Fast_Size_Threshold, Inv_Fast_Dim_Threshold, Products_Size_Threshold, Function_Precision >::basis_max_count, PyClical::e(), glucat::index_set< LO, HI >::fold(), glucat::gen::generator_table< Matrix_T >::generator(), PyClical::ist, glucat::index_set< LO, HI >::max(), glucat::index_set< LO, HI >::min(), glucat::matrix::mono_prod(), and glucat::offset_level().
Referenced by glucat::framed_multi< Scalar_T, LO, HI >::framed_multi().
|
static |
Class name used in messages.
Definition at line 71 of file matrix_multi_imp.h.
| const framed_multi< Other_Scalar_T, LO, HI > glucat::matrix_multi< Scalar_T, LO, HI >::fast_framed_multi |
Use inverse generalized FFT to construct a framed_multi_t.
Definition at line 1168 of file matrix_multi_imp.h.
References glucat::framed_multi< Scalar_T, LO, HI >::centre_pm4_qp4(), glucat::framed_multi< Scalar_T, LO, HI >::centre_pp4_qm4(), glucat::framed_multi< Scalar_T, LO, HI >::centre_qp1_pm1(), glucat::gen::offset_to_super, glucat::pos_mod(), and glucat::framed_multi< Scalar_T, LO, HI >::unfold().
|
inline |
Use generalized FFT to construct a matrix_multi_t.
Definition at line 1155 of file matrix_multi_imp.h.
|
inline |
Add a term, if non-zero.
Geometric sum.
Geometric sum of multivector and scalar.
Definition at line 472 of file matrix_multi_imp.h.
| matrix_multi< Scalar_T, LO, HI > & glucat::matrix_multi< Scalar_T, LO, HI >::operator= | ( | const multivector_t & | rhs | ) |
Assignment operator.
Definition at line 338 of file matrix_multi_imp.h.
References glucat::matrix_multi< Scalar_T, LO, HI >::m_frame, and glucat::matrix_multi< Scalar_T, LO, HI >::m_matrix.
|
static |
Random multivector within a frame.
Definition at line 998 of file matrix_multi_imp.h.
References PyClical::fill, and glucat::framed_multi< Scalar_T, LO, HI >::random().
|
friend |
Definition at line 145 of file matrix_multi.h.
|
friend |
|
friend |
Definition at line 147 of file matrix_multi.h.
Referenced by glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi().
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
private |
Index set representing the frame for the subalgebra which contains the multivector.
Definition at line 275 of file matrix_multi.h.
Referenced by glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi(), glucat::operator*(), glucat::operator/(), glucat::matrix_multi< Scalar_T, LO, HI >::operator=(), and glucat::reframe().
|
private |
Matrix value representing the multivector within the folded frame.
Definition at line 277 of file matrix_multi.h.
Referenced by glucat::framed_multi< Scalar_T, LO, HI >::framed_multi(), glucat::matrix_multi< Scalar_T, LO, HI >::matrix_multi(), glucat::operator*(), and glucat::matrix_multi< Scalar_T, LO, HI >::operator=().