Spectral Integral Suite in C++
sis::LinopMat< T > Class Template Reference

This class represents a block matrix operator. It is a matrix of operators. More...

#include <sis.hpp>

Public Member Functions

 LinopMat ()
 This holds a vector of boundary conditions. There should be as many boundary conditions as there are columns, for example consider a (2,3) LinopMat:

\[ \left[ \begin{array}{ccc} L & M & O\\ Q & R & S \end{array} \right]\left[ \begin{array}{c} u\\ v\\ w \end{array} \right] \]

One needs to specify the boundary conditions for three dependent variables, i.e., \(u\), \(v\) and \(w\). More...

 
 LinopMat (int r_, int c_)
 Initializes a Linop Matrix of r_ rows and c_ columns. More...
 
 LinopMat (const LinopMat< T > &in)
 Copy constructor. More...
 
void operator= (const LinopMat &in)
 Assignment operator. More...
 
LinopMat< T > & operator<< (T b)
 Use this to input multiple Linops to the LinopMat using comma separators. Input type of constant. More...
 
Linop< T > & operator[] (int i)
 Use this to to refer to Linops. For 1D Matrices, we use the Row major format when refering to [i]. See wiki for row-major format. More...
 
Linop< T > & operator() (int i, int j)
 Use this to to refer to Linop. For 2D Matrices, refer to matrix element Linop by (i,j) with the row and column index. Indices start from 0. More...
 
LinopMat< T > & operator<< (Eigen::Array< T, Eigen::Dynamic, 1 > b)
 Use this to input multiple Linops to the LinopMat using comma separators. Input type Eigen array. More...
 
LinopMat< T > & operator<< (Linop< T > b)
 Use this to input multiple Linops to the LinopMat using comma. More...
 
void resize (int r_, int c_)
 This clears all contents in the LinopMat, and then creates a fresh LinopMat of size r_ x c_. More...
 
LinopMat< T > & operator, (T b)
 Overloads comma separator to input Chebfuns into a ChebfunMat. Input type constant. More...
 
LinopMat< T > & operator, (Eigen::Array< T, Eigen::Dynamic, 1 > b)
 Overloads comma separator to input Chebfuns into a ChebfunMat. Input type Eigen array. More...
 
LinopMat< T > & operator, (Linop< T > b)
 Overloads comma separator to input Chebfuns into a ChebfunMat. Input type Chebfun. More...
 
ChebfunMat< T > solve (const ChebfunMat< T > &in)
 Solves an input ChebfunMat, Dimensions of ChebfunMat have to be (c,1) More...
 
LinopMat< T > & operator<< (LinopMat< T > b)
 Use this to input multiple LinopMats to the LinopMat using comma separators. Call at after initializing a LinopMat, or after calling resize, , similar to Eigen's << operator. CAREFUL: If dimensions are not compatible, it will not throw an error, and could end up in segv. More...
 
LinopMat< T > & operator, (LinopMat< T > b)
 
LinopMat< T > cTranspose ()
 
void setConstant (T in)
 Sets every member in LinopMat to constant. More...
 
void setIdentity ()
 Sets LinopMat to identity. More...
 

Public Attributes

int r
 Number of rows. More...
 
int c
 Number of columns. More...
 
std::valarray< Linop< T > > LinopVec
 This 1D vector of Linops holds all Linops of the LinopMat in the row-major format. More...
 
int countc
 
int countr
 
bool go_to_next_row
 

Detailed Description

template<class T>
class sis::LinopMat< T >

This class represents a block matrix operator. It is a matrix of operators.

Definition at line 528 of file sis.hpp.

Constructor & Destructor Documentation

◆ LinopMat() [1/3]

template<class T>
sis::LinopMat< T >::LinopMat ( )
inline

This holds a vector of boundary conditions. There should be as many boundary conditions as there are columns, for example consider a (2,3) LinopMat:

\[ \left[ \begin{array}{ccc} L & M & O\\ Q & R & S \end{array} \right]\left[ \begin{array}{c} u\\ v\\ w \end{array} \right] \]

One needs to specify the boundary conditions for three dependent variables, i.e., \(u\), \(v\) and \(w\).

Null constructor

Definition at line 8143 of file sis.hpp.

◆ LinopMat() [2/3]

template<class T>
sis::LinopMat< T >::LinopMat ( int  r_,
int  c_ 
)
inline

Initializes a Linop Matrix of r_ rows and c_ columns.

Definition at line 8146 of file sis.hpp.

References sis::LinopMat< T >::c, sis::LinopMat< T >::LinopVec, and sis::LinopMat< T >::r.

◆ LinopMat() [3/3]

template<class T>
sis::LinopMat< T >::LinopMat ( const LinopMat< T > &  in)
inline

Member Function Documentation

◆ cTranspose()

template<class T>
LinopMat<T> sis::LinopMat< T >::cTranspose ( )
inline

Definition at line 8325 of file sis.hpp.

References sis::LinopMat< T >::c, sis::conj(), and sis::LinopMat< T >::r.

◆ operator()()

◆ operator,() [1/4]

template<class T>
LinopMat<T>& sis::LinopMat< T >::operator, ( b)
inline

Overloads comma separator to input Chebfuns into a ChebfunMat. Input type constant.

Definition at line 8223 of file sis.hpp.

References sis::LinopMat< T >::LinopVec.

◆ operator,() [2/4]

template<class T>
LinopMat<T>& sis::LinopMat< T >::operator, ( Eigen::Array< T, Eigen::Dynamic, 1 >  b)
inline

Overloads comma separator to input Chebfuns into a ChebfunMat. Input type Eigen array.

Definition at line 8230 of file sis.hpp.

References sis::LinopMat< T >::LinopVec.

◆ operator,() [3/4]

template<class T>
LinopMat<T>& sis::LinopMat< T >::operator, ( Linop< T >  b)
inline

Overloads comma separator to input Chebfuns into a ChebfunMat. Input type Chebfun.

Definition at line 8237 of file sis.hpp.

References sis::LinopMat< T >::LinopVec.

◆ operator,() [4/4]

◆ operator<<() [1/4]

template<class T>
LinopMat<T>& sis::LinopMat< T >::operator<< ( b)
inline

Use this to input multiple Linops to the LinopMat using comma separators. Input type of constant.

Definition at line 8176 of file sis.hpp.

References sis::LinopMat< T >::LinopVec.

◆ operator<<() [2/4]

template<class T>
LinopMat<T>& sis::LinopMat< T >::operator<< ( Eigen::Array< T, Eigen::Dynamic, 1 >  b)
inline

Use this to input multiple Linops to the LinopMat using comma separators. Input type Eigen array.

Definition at line 8197 of file sis.hpp.

References sis::LinopMat< T >::LinopVec.

◆ operator<<() [3/4]

template<class T>
LinopMat<T>& sis::LinopMat< T >::operator<< ( Linop< T >  b)
inline

Use this to input multiple Linops to the LinopMat using comma.

Definition at line 8205 of file sis.hpp.

References sis::LinopMat< T >::LinopVec.

◆ operator<<() [4/4]

template<class T>
LinopMat<T>& sis::LinopMat< T >::operator<< ( LinopMat< T >  b)
inline

Use this to input multiple LinopMats to the LinopMat using comma separators. Call at after initializing a LinopMat, or after calling resize, , similar to Eigen's << operator. CAREFUL: If dimensions are not compatible, it will not throw an error, and could end up in segv.

Definition at line 8251 of file sis.hpp.

References sis::LinopMat< T >::c, sis::LinopMat< T >::countc, sis::LinopMat< T >::countr, sis::LinopMat< T >::go_to_next_row, sis::LinopMat< T >::operator()(), sis::LinopMat< T >::r, and sis::LinopMat< T >::setConstant().

◆ operator=()

template<class T>
void sis::LinopMat< T >::operator= ( const LinopMat< T > &  in)
inline

Assignment operator.

Definition at line 8164 of file sis.hpp.

References sis::LinopMat< T >::c, sis::LinopMat< T >::LinopVec, sis::LinopMat< T >::r, and sis::LinopMat< T >::resize().

◆ operator[]()

template<class T>
Linop<T>& sis::LinopMat< T >::operator[] ( int  i)
inline

Use this to to refer to Linops. For 1D Matrices, we use the Row major format when refering to [i]. See wiki for row-major format.

Definition at line 8185 of file sis.hpp.

References sis::LinopMat< T >::LinopVec.

◆ resize()

◆ setConstant()

◆ setIdentity()

template<class T>
void sis::LinopMat< T >::setIdentity ( )
inline

◆ solve()

template<class T>
ChebfunMat<T> sis::LinopMat< T >::solve ( const ChebfunMat< T > &  in)
inline

Solves an input ChebfunMat, Dimensions of ChebfunMat have to be (c,1)

Definition at line 8245 of file sis.hpp.

Member Data Documentation

◆ c

◆ countc

◆ countr

◆ go_to_next_row

◆ LinopVec

◆ r


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