31#include "../containers/C2DContainer.hpp"
41 "Column major storage is assumed for LAPACK.");
113 template <
class ForwardIt>
115 for (
int i = 0; i <
Size(); ++i) {
118 for (
int k = 0; k <
Size(); ++k) *vec_out += *(vec++) * mat(i, k);
A templated matrix/vector-like object.
Definition C2DContainer.hpp:374
C2DContainer & resize(const Index_t size1, const Index_t size2=1) noexcept
Request a change of size.
Definition C2DContainer.hpp:541
Index_t rows() const noexcept
Definition C2DContainer.hpp:222
Class to store a dense general square matrix that uses the Column Major order storage format....
Definition CSquareMatrixCM.hpp:39
passivedouble & operator()(int i, int j)
Operator, which makes available the given matrix element as a reference.
Definition CSquareMatrixCM.hpp:66
const passivedouble & operator()(int i, int j) const
Operator, which makes available the given matrix element as a const reference.
Definition CSquareMatrixCM.hpp:74
void MatVecMult(ForwardIt vec_in, ForwardIt vec_out) const
Naive matrix-vector multiplication with general type.
Definition CSquareMatrixCM.hpp:114
CSquareMatrixCM(int N)
Overloaded constructor, which allocates the memory to store the matrix.
Definition CSquareMatrixCM.hpp:58
int Size() const
Function, which makes available the size of the matrix.
Definition CSquareMatrixCM.hpp:98
const ColMajorMatrix< passivedouble > & GetMat() const
Function, which makes available a const reference to the actual matrix.
Definition CSquareMatrixCM.hpp:86
ColMajorMatrix< passivedouble > & GetMat()
Function, which makes available a reference to the actual matrix.
Definition CSquareMatrixCM.hpp:80
void Transpose()
Function, which transposes the matrix in-place.
Definition CSquareMatrixCM.cpp:57
void Initialize(int N)
Function, which allocates the memory for the matrix.
Definition CSquareMatrixCM.hpp:92
void MatMatMult(const char side, const ColMajorMatrix< passivedouble > &mat_in, ColMajorMatrix< passivedouble > &mat_out) const
Function, which carries out the matrix produc of the current matrix with mat_in and stores the result...
Definition CSquareMatrixCM.cpp:82
CSquareMatrixCM()=default
Default constructor. Nothing to be done.
void Invert()
Function, which inverts the matrix in-place.
Definition CSquareMatrixCM.cpp:62
double passivedouble
Definition code_config.hpp:129