44 #ifndef Foam_MatrixSpace_H 45 #define Foam_MatrixSpace_H 58 template<
class Form,
class Cmpt, direction Mrows, direction Ncols>
92 template<
class SubTensor, direction BRowStart, direction BColStart>
151 template<
class Form2>
152 inline void operator=
164 template<
class VSForm>
165 inline void operator=
197 template<
class Form2,
class Cmpt2>
206 template<
class, direction, direction>
class Block2,
212 const Block2<Form, BRowStart, BColStart>&
block 222 template<direction Row, direction Col>
233 const Cmpt&
xx() const
noexcept {
return elmt<0,0>(); }
234 const Cmpt&
xy() const
noexcept {
return elmt<0,1>(); }
235 const Cmpt&
xz() const
noexcept {
return elmt<0,2>(); }
236 const Cmpt&
yx() const
noexcept {
return elmt<1,0>(); }
237 const Cmpt&
yy() const
noexcept {
return elmt<1,1>(); }
238 const Cmpt&
yz() const
noexcept {
return elmt<1,2>(); }
239 const Cmpt&
zx() const
noexcept {
return elmt<2,0>(); }
240 const Cmpt&
zy() const
noexcept {
return elmt<2,1>(); }
241 const Cmpt&
zz() const
noexcept {
return elmt<2,2>(); }
263 template<
class SubTensor, direction BRowStart, direction BColStart>
264 inline ConstBlock<SubTensor, BRowStart, BColStart>
block()
const;
268 template<
class SubTensor, direction BRowStart, direction BColStart>
269 inline Block<SubTensor, BRowStart, BColStart>
block();
290 template<
class, direction, direction>
class Block2,
294 inline void operator=
296 const Block2<Form, BRowStart, BColStart>&
block 300 template<
class Form2>
301 inline void operator&=
const Cmpt & operator()(const direction i, const direction j) const
(i, j) const element access operator
static direction n() noexcept
The number of columns.
static direction n() noexcept
Return the number of columns in the block.
Block(msType &matrix)
Construct for the given matrix.
ConstBlock(const msType &matrix)
Construct for the given matrix.
const Cmpt & xy() const noexcept
static const direction nCols
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
SubTensor operator()() const
Construct and return the sub-tensor corresponding to this block.
MatrixSpace< Form, Cmpt, Mrows, Ncols > msType
MatrixSpace type.
typeOfTranspose< Cmpt, Form >::type T() const
Return the transpose of the matrix.
void operator=(Foam::zero)
Assignment to zero.
const Cmpt & zy() const noexcept
static const direction mRows
const Cmpt & zx() const noexcept
static constexpr direction nCols
static direction m() noexcept
Return the number of rows in the block.
static direction m() noexcept
The number of rows.
const Cmpt & yx() const noexcept
static constexpr direction mRows
const Cmpt & xz() const noexcept
static const direction mRows
static const direction nCols
ConstBlock< SubTensor, BRowStart, BColStart > block() const
Return a const sub-block corresponding to the specified type.
Creates a single block of cells from point coordinates, numbers of cells in each direction and an exp...
const Cmpt & elmt() const noexcept
Fast const element access using compile-time addressing.
const Cmpt & yy() const noexcept
static direction m() noexcept
The number of rows in the block.
friend Ostream & operator(Ostream &, const VectorSpace< Form, Cmpt, Ncmpts > &)
const Cmpt & zz() const noexcept
MatrixSpace()=default
Default construct.
static direction n() noexcept
The number of columns in the block.
SubTensor operator()() const
Construct and return the sub-tensor corresponding to this block.
const Cmpt & xx() const noexcept
const Cmpt & yz() const noexcept
A class representing the concept of 0 (zero) that can be used to avoid manipulating objects known to ...
static msType identity()
An identity matrix for square matrix-spaces.