136 #ifndef Foam_QRMatrix_H 137 #define Foam_QRMatrix_H 151 template<
class MatrixType>
156 typedef typename MatrixType::cmptType
cmptType;
157 typedef SquareMatrix<cmptType>
SMatrix;
158 typedef RectangularMatrix<cmptType>
RMatrix;
211 label calcShapeFactor(
const MatrixType&
A)
const;
214 void decompose(MatrixType& AT);
217 void decompose(MatrixType& AT,
const bool pivot);
220 void calcQ(
const MatrixType& AT);
231 template<
template<
typename>
class ListContainer>
232 void solvex(ListContainer<cmptType>&
x)
const;
236 template<
template<
typename>
class ListContainer>
240 const ListContainer<cmptType>& source
322 const UList<cmptType>& source
331 const IndirectListBase<cmptType, Addr>& source
336 tmp<Field<cmptType>>
solve 338 const UList<cmptType>& source
344 tmp<Field<cmptType>>
solve 346 const IndirectListBase<cmptType, Addr>& source
363 namespace MatrixTools
372 template<
class MatrixType>
MatrixType::cmptType cmptType
pivoting
Options for the column pivoting.
outputs
Options for the output types.
RectangularMatrix< cmptType > RMatrix
QRMatrix computes QR decomposition of a given scalar/complex matrix A into the following: ...
SMatrix P() const
Create and return the permutation matrix.
void solve(List< cmptType > &x, const UList< cmptType > &source) const
Solve the linear system with the given source and return the solution in the argument x...
SMatrix inv() const
Return the inverse of (Q*R), solving x = (Q*R).inv()*source.
compute economy-size decomposition
void diag(pointPatchField< vector > &, const pointPatchField< tensor > &)
const MatrixType & R() const noexcept
Return const reference to R.
const dimensionedScalar e
Elementary charge.
const dimensionedScalar b
Wien displacement law constant: default SI units: [m.K].
const MatrixType & Q() const noexcept
Return const reference to Q.
compute full-size decomposition
const labelList & p() const noexcept
Return const reference to p.
switch off column pivoting
static Ostream & output(Ostream &os, const IntRange< T > &range)
List< label > labelList
A List of labels.
SquareMatrix< cmptType > SMatrix
static const Foam::dimensionedScalar A("", Foam::dimPressure, 611.21)
modes
Options for the decomposition mode.
mode_t mode(const fileName &name, const bool followLink=true)
Return the file mode, normally following symbolic links.
switch on column pivoting
QRMatrix()=delete
Construct null.