A special matrix type and solver, designed for finite volume solutions of scalar equations. Face addressing is used to make all matrix assembly and solution loops vectorise. More...
Classes | |
class | fvSolver |
Solver class returned by the solver function. More... | |
Public Types | |
typedef GeometricField< Type, fvsPatchField, surfaceMesh > * | surfaceTypeFieldPtr |
Declare return type of the faceFluxCorrectionPtr() function. More... | |
Public Member Functions | |
ClassName ("fvMatrix") | |
fvMatrix (const GeometricField< Type, fvPatchField, volMesh > &, const dimensionSet &) | |
Construct given a field to solve for. More... | |
fvMatrix (const fvMatrix< Type > &) | |
Construct as copy. More... | |
fvMatrix (const tmp< fvMatrix< Type >> &) | |
Construct as copy of tmp<fvMatrix<Type>> deleting argument. More... | |
fvMatrix (const GeometricField< Type, fvPatchField, volMesh > &, Istream &) | |
Construct from Istream given field to solve for. More... | |
virtual | ~fvMatrix () |
Destructor. More... | |
const GeometricField< Type, fvPatchField, volMesh > & | psi () const |
const dimensionSet & | dimensions () const |
Field< Type > & | source () |
const Field< Type > & | source () const |
FieldField< Field, Type > & | internalCoeffs () |
fvBoundary scalar field containing pseudo-matrix coeffs More... | |
FieldField< Field, Type > & | boundaryCoeffs () |
fvBoundary scalar field containing pseudo-matrix coeffs More... | |
surfaceTypeFieldPtr & | faceFluxCorrectionPtr () |
Return pointer to face-flux non-orthogonal correction field. More... | |
void | setValues (const labelUList &cells, const UList< Type > &values) |
Set solution in given cells to the specified values. More... | |
void | setValues (const labelUList &cells, const UIndirectList< Type > &values) |
Set solution in given cells to the specified values. More... | |
void | setReference (const label celli, const Type &value, const bool forceReference=false) |
Set reference level for solution. More... | |
void | setComponentReference (const label patchi, const label facei, const direction cmpt, const scalar value) |
Set reference level for a component of the solution. More... | |
void | relax (const scalar alpha) |
Relax matrix (for steady-state solution). More... | |
void | relax () |
Relax matrix (for steady-state solution). More... | |
void | boundaryManipulate (typename GeometricField< Type, fvPatchField, volMesh >::Boundary &values) |
Manipulate based on a boundary field. More... | |
autoPtr< fvSolver > | solver (const dictionary &) |
Construct and return the solver. More... | |
autoPtr< fvSolver > | solver () |
Construct and return the solver. More... | |
SolverPerformance< Type > | solve (const dictionary &) |
Solve segregated or coupled returning the solution statistics. More... | |
SolverPerformance< Type > | solveSegregated (const dictionary &) |
Solve segregated returning the solution statistics. More... | |
SolverPerformance< Type > | solveCoupled (const dictionary &) |
Solve coupled returning the solution statistics. More... | |
SolverPerformance< Type > | solve () |
Solve returning the solution statistics. More... | |
tmp< Field< Type > > | residual () const |
Return the matrix residual. More... | |
tmp< scalarField > | D () const |
Return the matrix scalar diagonal. More... | |
tmp< Field< Type > > | DD () const |
Return the matrix Type diagonal. More... | |
tmp< volScalarField > | A () const |
Return the central coefficient. More... | |
tmp< GeometricField< Type, fvPatchField, volMesh > > | H () const |
Return the H operation source. More... | |
tmp< volScalarField > | H1 () const |
Return H(1) More... | |
tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > | flux () const |
Return the face-flux field from the matrix. More... | |
void | operator= (const fvMatrix< Type > &) |
void | operator= (const tmp< fvMatrix< Type >> &) |
void | negate () |
void | operator+= (const fvMatrix< Type > &) |
void | operator+= (const tmp< fvMatrix< Type >> &) |
void | operator-= (const fvMatrix< Type > &) |
void | operator-= (const tmp< fvMatrix< Type >> &) |
void | operator+= (const DimensionedField< Type, volMesh > &) |
void | operator+= (const tmp< DimensionedField< Type, volMesh >> &) |
void | operator+= (const tmp< GeometricField< Type, fvPatchField, volMesh >> &) |
void | operator-= (const DimensionedField< Type, volMesh > &) |
void | operator-= (const tmp< DimensionedField< Type, volMesh >> &) |
void | operator-= (const tmp< GeometricField< Type, fvPatchField, volMesh >> &) |
void | operator+= (const dimensioned< Type > &) |
void | operator-= (const dimensioned< Type > &) |
void | operator+= (const zero &) |
void | operator-= (const zero &) |
void | operator*= (const DimensionedField< scalar, volMesh > &) |
void | operator*= (const tmp< DimensionedField< scalar, volMesh >> &) |
void | operator*= (const tmp< volScalarField > &) |
void | operator*= (const dimensioned< scalar > &) |
template<> | |
void | setComponentReference (const label patchi, const label facei, const direction, const scalar value) |
template<> | |
Foam::autoPtr< Foam::fvMatrix< Foam::scalar >::fvSolver > | solver (const dictionary &solverControls) |
template<> | |
Foam::solverPerformance | solveSegregated (const dictionary &solverControls) |
template<> | |
Foam::tmp< Foam::scalarField > | residual () const |
template<> | |
Foam::tmp< Foam::volScalarField > | H () const |
template<> | |
Foam::tmp< Foam::volScalarField > | H1 () const |
template<> | |
void | setComponentReference (const label patchi, const label facei, const direction, const scalar value) |
template<> | |
autoPtr< fvMatrix< scalar >::fvSolver > | solver (const dictionary &) |
template<> | |
solverPerformance | solveSegregated (const dictionary &) |
template<> | |
tmp< scalarField > | residual () const |
template<> | |
tmp< volScalarField > | H () const |
template<> | |
tmp< volScalarField > | H1 () const |
![]() | |
int | count () const |
Return the current reference count. More... | |
bool | unique () const |
Return true if the reference count is zero. More... | |
void | operator++ () |
Increment the reference count. More... | |
void | operator++ (int) |
Increment the reference count. More... | |
void | operator-- () |
Decrement the reference count. More... | |
void | operator-- (int) |
Decrement the reference count. More... | |
![]() | |
ClassName ("lduMatrix") | |
lduMatrix (const lduMesh &) | |
Construct given an LDU addressed mesh. More... | |
lduMatrix (const lduMatrix &) | |
Construct as copy. More... | |
lduMatrix (lduMatrix &, bool reuse) | |
Construct as copy or re-use as specified. More... | |
lduMatrix (const lduMesh &, Istream &) | |
Construct given an LDU addressed mesh and an Istream. More... | |
~lduMatrix () | |
Destructor. More... | |
const lduMesh & | mesh () const |
Return the LDU mesh from which the addressing is obtained. More... | |
const lduAddressing & | lduAddr () const |
Return the LDU addressing. More... | |
const lduSchedule & | patchSchedule () const |
Return the patch evaluation schedule. More... | |
scalarField & | lower () |
scalarField & | diag () |
scalarField & | upper () |
scalarField & | lower (const label size) |
scalarField & | diag (const label nCoeffs) |
scalarField & | upper (const label nCoeffs) |
const scalarField & | lower () const |
const scalarField & | diag () const |
const scalarField & | upper () const |
bool | hasDiag () const |
bool | hasUpper () const |
bool | hasLower () const |
bool | diagonal () const |
bool | symmetric () const |
bool | asymmetric () const |
void | sumDiag () |
void | negSumDiag () |
void | sumMagOffDiag (scalarField &sumOff) const |
void | Amul (scalarField &, const tmp< scalarField > &, const FieldField< Field, scalar > &, const lduInterfaceFieldPtrsList &, const direction cmpt) const |
Matrix multiplication with updated interfaces. More... | |
void | Tmul (scalarField &, const tmp< scalarField > &, const FieldField< Field, scalar > &, const lduInterfaceFieldPtrsList &, const direction cmpt) const |
Matrix transpose multiplication with updated interfaces. More... | |
void | sumA (scalarField &, const FieldField< Field, scalar > &, const lduInterfaceFieldPtrsList &) const |
Sum the coefficients on each row of the matrix. More... | |
void | residual (scalarField &rA, const scalarField &psi, const scalarField &source, const FieldField< Field, scalar > &interfaceBouCoeffs, const lduInterfaceFieldPtrsList &interfaces, const direction cmpt) const |
tmp< scalarField > | residual (const scalarField &psi, const scalarField &source, const FieldField< Field, scalar > &interfaceBouCoeffs, const lduInterfaceFieldPtrsList &interfaces, const direction cmpt) const |
void | initMatrixInterfaces (const FieldField< Field, scalar > &interfaceCoeffs, const lduInterfaceFieldPtrsList &interfaces, const scalarField &psiif, scalarField &result, const direction cmpt) const |
Initialise the update of interfaced interfaces. More... | |
void | updateMatrixInterfaces (const FieldField< Field, scalar > &interfaceCoeffs, const lduInterfaceFieldPtrsList &interfaces, const scalarField &psiif, scalarField &result, const direction cmpt) const |
Update interfaced interfaces for matrix operations. More... | |
template<class Type > | |
tmp< Field< Type > > | H (const Field< Type > &) const |
template<class Type > | |
tmp< Field< Type > > | H (const tmp< Field< Type >> &) const |
tmp< scalarField > | H1 () const |
template<class Type > | |
tmp< Field< Type > > | faceH (const Field< Type > &) const |
template<class Type > | |
tmp< Field< Type > > | faceH (const tmp< Field< Type >> &) const |
InfoProxy< lduMatrix > | info () const |
Return info proxy. More... | |
void | operator= (const lduMatrix &) |
void | negate () |
void | operator+= (const lduMatrix &) |
void | operator-= (const lduMatrix &) |
void | operator*= (const scalarField &) |
void | operator*= (scalar) |
template<class Type > | |
Foam::tmp< Foam::Field< Type > > | H (const Field< Type > &psi) const |
template<class Type > | |
Foam::tmp< Foam::Field< Type > > | H (const tmp< Field< Type >> &tpsi) const |
template<class Type > | |
Foam::tmp< Foam::Field< Type > > | faceH (const Field< Type > &psi) const |
template<class Type > | |
Foam::tmp< Foam::Field< Type > > | faceH (const tmp< Field< Type >> &tpsi) const |
Protected Member Functions | |
template<class Type2 > | |
void | addToInternalField (const labelUList &addr, const Field< Type2 > &pf, Field< Type2 > &intf) const |
Add patch contribution to internal field. More... | |
template<class Type2 > | |
void | addToInternalField (const labelUList &addr, const tmp< Field< Type2 >> &tpf, Field< Type2 > &intf) const |
template<class Type2 > | |
void | subtractFromInternalField (const labelUList &addr, const Field< Type2 > &pf, Field< Type2 > &intf) const |
Subtract patch contribution from internal field. More... | |
template<class Type2 > | |
void | subtractFromInternalField (const labelUList &addr, const tmp< Field< Type2 >> &tpf, Field< Type2 > &intf) const |
void | addBoundaryDiag (scalarField &diag, const direction cmpt) const |
void | addCmptAvBoundaryDiag (scalarField &diag) const |
void | addBoundarySource (Field< Type > &source, const bool couples=true) const |
template<template< class > class ListType> | |
void | setValuesFromList (const labelUList &cells, const ListType< Type > &values) |
Set solution in given cells to the specified values. More... | |
![]() | |
refCount () | |
Construct null initializing count to 0. More... | |
Friends | |
class | fvSolver |
Declare friendship with the fvSolver class. More... | |
tmp< GeometricField< Type, fvPatchField, volMesh > > | operator& (const fvMatrix< Type > &, const DimensionedField< Type, volMesh > &) |
tmp< GeometricField< Type, fvPatchField, volMesh > > | operator& (const fvMatrix< Type > &, const tmp< GeometricField< Type, fvPatchField, volMesh >> &) |
tmp< GeometricField< Type, fvPatchField, volMesh > > | operator& (const tmp< fvMatrix< Type >> &, const DimensionedField< Type, volMesh > &) |
tmp< GeometricField< Type, fvPatchField, volMesh > > | operator& (const tmp< fvMatrix< Type >> &, const tmp< GeometricField< Type, fvPatchField, volMesh >> &) |
Ostream & | operator (Ostream &, const fvMatrix< Type > &) |
A special matrix type and solver, designed for finite volume solutions of scalar equations. Face addressing is used to make all matrix assembly and solution loops vectorise.
Definition at line 71 of file fvPatchField.H.
typedef GeometricField<Type, fvsPatchField, surfaceMesh>* surfaceTypeFieldPtr |
Declare return type of the faceFluxCorrectionPtr() function.
Definition at line 318 of file fvMatrix.H.
fvMatrix | ( | const GeometricField< Type, fvPatchField, volMesh > & | psi, |
const dimensionSet & | ds | ||
) |
Construct given a field to solve for.
Definition at line 268 of file fvMatrix.C.
References GeometricField< Type, PatchField, GeoMesh >::boundaryFieldRef(), Foam::endl(), regIOobject::eventNo(), forAll, InfoInFunction, DimensionedField< Type, GeoMesh >::mesh(), patchi, and Foam::Zero.
Referenced by fvMatrix< Type >::fvMatrix(), fvMatrix< Type >::fvSolver::fvSolver(), and fvMatrix< Type >::setValuesFromList().
Construct as copy.
Definition at line 322 of file fvMatrix.C.
References Foam::endl(), and InfoInFunction.
Construct as copy of tmp<fvMatrix<Type>> deleting argument.
Definition at line 352 of file fvMatrix.C.
References Foam::endl(), fvMatrix< Type >::fvMatrix(), and InfoInFunction.
fvMatrix | ( | const GeometricField< Type, fvPatchField, volMesh > & | psi, |
Istream & | is | ||
) |
Construct from Istream given field to solve for.
Definition at line 408 of file fvMatrix.C.
References Foam::endl(), forAll, InfoInFunction, DimensionedField< Type, GeoMesh >::mesh(), patchi, and Foam::Zero.
|
virtual |
Destructor.
Definition at line 455 of file fvMatrix.C.
References Foam::endl(), InfoInFunction, and fvMatrix< Type >::setValues().
Referenced by fvMatrix< Type >::fvSolver::fvSolver().
|
protected |
Add patch contribution to internal field.
Definition at line 38 of file fvMatrix.C.
References Foam::abort(), Foam::FatalError, FatalErrorInFunction, forAll, List< Type >::size(), and UList< T >::size().
Referenced by fvMatrix< Type >::DD(), and fvMatrix< Type >::H1().
|
protected |
Definition at line 61 of file fvMatrix.C.
References fvMatrix< Type >::subtractFromInternalField().
|
protected |
Subtract patch contribution from internal field.
Definition at line 75 of file fvMatrix.C.
References Foam::abort(), Foam::FatalError, FatalErrorInFunction, forAll, List< Type >::size(), and UList< T >::size().
Referenced by fvMatrix< Type >::addToInternalField().
|
protected |
Definition at line 98 of file fvMatrix.C.
References fvMatrix< Type >::addBoundaryDiag().
|
protected |
Definition at line 111 of file fvMatrix.C.
References Foam::component(), forAll, and patchi.
Referenced by fvMatrix< Type >::H(), fvMatrix< Type >::residual(), and fvMatrix< Type >::subtractFromInternalField().
|
protected |
Definition at line 129 of file fvMatrix.C.
References fvMatrix< Type >::addBoundarySource(), Foam::cmptAv(), forAll, and patchi.
Referenced by fvMatrix< Type >::D(), and fvMatrix< Type >::H().
|
protected |
Definition at line 145 of file fvMatrix.C.
References Foam::cmptMultiply(), fvPatchField< Type >::coupled(), forAll, patchi, fvPatchField< Type >::patchNeighbourField(), and fvMatrix< Type >::setValuesFromList().
Referenced by fvMatrix< Type >::addCmptAvBoundaryDiag(), fvMatrix< Type >::H(), and fvMatrix< Type >::residual().
|
protected |
Set solution in given cells to the specified values.
Definition at line 178 of file fvMatrix.C.
References polyMesh::boundaryMesh(), Foam::constant::universal::c, cells, primitiveMesh::cells(), Foam::diag(), forAll, fvMatrix< Type >::fvMatrix(), primitiveMesh::isInternalFace(), mesh, fvMesh::neighbour(), fvMesh::owner(), patchi, primitiveFieldRef(), psi, polyBoundaryMesh::whichPatch(), and Foam::Zero.
Referenced by fvMatrix< Type >::addBoundarySource(), and fvMatrix< Type >::setValues().
ClassName | ( | "fvMatrix< Type >" | ) |
|
inline |
Definition at line 281 of file fvMatrix.H.
Referenced by MRFZone::addCoriolis(), explicitPorositySource::addSup(), interRegionExplicitPorositySource::addSup(), radialActuationDiskSource::addSup(), interRegionHeatTransferModel::addSup(), SemiImplicitSource< Type >::addSup(), actuationDiskSource::addSup(), solidificationMeltingSource::addSup(), rotorDiskSource::addSup(), Foam::checkMethod(), optionList::constrain(), fixedCoeff::correct(), powerLaw::correct(), DarcyForchheimer::correct(), fvMatrix< Type >::operator+=(), and fvMatrix< Type >::operator-=().
|
inline |
Definition at line 286 of file fvMatrix.H.
Referenced by explicitPorositySource::addSup(), meanVelocityForce::addSup(), interRegionExplicitPorositySource::addSup(), SemiImplicitSource< Type >::addSup(), rotorDiskSource::addSup(), Foam::checkMethod(), fixedCoeff::correct(), powerLaw::correct(), DarcyForchheimer::correct(), and fvMatrix< Type >::flux().
|
inline |
Definition at line 291 of file fvMatrix.H.
Referenced by MRFZone::addCoriolis(), interRegionExplicitPorositySource::addSup(), radialActuationDiskSource::addSup(), actuationDiskSource::addSup(), solidificationMeltingSource::addSup(), effectivenessHeatExchangerSource::addSup(), fixedCoeff::correct(), DarcyForchheimer::correct(), EulerD2dt2Scheme< Type >::fvmD2dt2(), EulerDdtScheme< Type >::fvmDdt(), backwardDdtScheme< Type >::fvmDdt(), CoEulerDdtScheme< Type >::fvmDdt(), SLTSDdtScheme< Type >::fvmDdt(), localEulerDdtScheme< Type >::fvmDdt(), CrankNicolsonDdtScheme< Type >::fvmDdt(), gaussLaplacianScheme< Type, GType >::fvmLaplacian(), fvMatrix< Type >::operator+=(), fvMatrix< Type >::operator-=(), fvMatrix< Type >::relax(), fvMatrix< Type >::setReference(), ThermoCloud< CloudType >::Sh(), ReactingCloud< CloudType >::Srho(), KinematicCloud< CloudType >::SU(), and ReactingCloud< CloudType >::SYi().
|
inline |
Definition at line 296 of file fvMatrix.H.
References fvMatrix< Type >::boundaryCoeffs(), and fvMatrix< Type >::internalCoeffs().
|
inline |
fvBoundary scalar field containing pseudo-matrix coeffs
for internal cells
Definition at line 303 of file fvMatrix.H.
Referenced by gaussConvectionScheme< Type >::fvmDiv(), gaussLaplacianScheme< Type, GType >::fvmLaplacianUncorrected(), and fvMatrix< Type >::source().
|
inline |
fvBoundary scalar field containing pseudo-matrix coeffs
for boundary cells
Definition at line 310 of file fvMatrix.H.
Referenced by gaussConvectionScheme< Type >::fvmDiv(), gaussLaplacianScheme< Type, GType >::fvmLaplacianUncorrected(), and fvMatrix< Type >::source().
|
inline |
Return pointer to face-flux non-orthogonal correction field.
Definition at line 321 of file fvMatrix.H.
References fvMatrix< Type >::A(), Foam::constant::atomic::alpha, fvMatrix< Type >::boundaryManipulate(), cells, Foam::checkMethod(), Foam::correction(), fvMatrix< Type >::D(), fvMatrix< Type >::DD(), fvMatrix< Type >::flux(), fvMatrix< Type >::H(), fvMatrix< Type >::H1(), fvMatrix< Type >::negate(), fvMatrix< Type >::operator*=(), fvMatrix< Type >::operator+=(), fvMatrix< Type >::operator-=(), fvMatrix< Type >::operator=(), patchi, fvMatrix< Type >::relax(), fvMatrix< Type >::residual(), fvMatrix< Type >::setComponentReference(), fvMatrix< Type >::setReference(), fvMatrix< Type >::setValues(), fvMatrix< Type >::fvSolver::solve(), fvMatrix< Type >::solveCoupled(), fvMatrix< Type >::solver(), and fvMatrix< Type >::solveSegregated().
Referenced by gaussLaplacianScheme< Type, GType >::fvmLaplacian().
void setValues | ( | const labelUList & | cells, |
const UList< Type > & | values | ||
) |
Set solution in given cells to the specified values.
and eliminate the corresponding equations from the matrix.
Definition at line 474 of file fvMatrix.C.
References fvMatrix< Type >::setValuesFromList().
Referenced by FixedValueConstraint< Type >::constrain(), fixedTemperatureConstraint::constrain(), fvMatrix< Type >::faceFluxCorrectionPtr(), fixedInternalValueFvPatchField< Type >::manipulateMatrix(), epsilonWallFunctionFvPatchScalarField::manipulateMatrix(), omegaWallFunctionFvPatchScalarField::manipulateMatrix(), and fvMatrix< Type >::~fvMatrix().
void setValues | ( | const labelUList & | cells, |
const UIndirectList< Type > & | values | ||
) |
Set solution in given cells to the specified values.
and eliminate the corresponding equations from the matrix.
Definition at line 485 of file fvMatrix.C.
References fvMatrix< Type >::setReference(), and fvMatrix< Type >::setValuesFromList().
void setReference | ( | const label | celli, |
const Type & | value, | ||
const bool | forceReference = false |
||
) |
Set reference level for solution.
Definition at line 496 of file fvMatrix.C.
References lduMatrix::diag(), and fvMatrix< Type >::source().
Referenced by Foam::CorrectPhi(), fvMatrix< Type >::faceFluxCorrectionPtr(), and fvMatrix< Type >::setValues().
void setComponentReference | ( | const label | patchi, |
const label | facei, | ||
const direction | cmpt, | ||
const scalar | value | ||
) |
Set reference level for a component of the solution.
on a given patch face
Definition at line 33 of file fvMatrixSolve.C.
References Foam::diag(), patchi, and fvMatrix< Type >::solve().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr().
void relax | ( | const scalar | alpha | ) |
Relax matrix (for steady-state solution).
alpha = 1 : diagonally equal alpha < 1 : diagonally dominant alpha = 0 : do nothing Note: Requires positive diagonal.
Definition at line 511 of file fvMatrix.C.
References Foam::constant::atomic::alpha, Foam::cmptMag(), Foam::cmptMax(), Foam::cmptMin(), Foam::component(), fvPatchField< Type >::coupled(), fvMatrix< Type >::D(), lduMatrix::diag(), Foam::endl(), forAll, InfoInFunction, lduMatrix::lduAddr(), Foam::mag(), Foam::max(), UPstream::msgType(), Foam::nl, lduAddressing::patchAddr(), patchi, Foam::reduce(), Foam::returnReduce(), List< T >::size(), List< Type >::size(), fvMatrix< Type >::source(), and lduMatrix::sumMagOffDiag().
Referenced by dynamicLagrangian< BasicTurbulenceModel >::correct(), thixotropicViscosity::correct(), kOmegaSST< TurbulenceModel, BasicTurbulenceModel >::correct(), scalarTransport::execute(), and thermalBaffle::solveEnergy().
void relax | ( | ) |
Relax matrix (for steady-state solution).
alpha is read from controlDict
Definition at line 662 of file fvMatrix.C.
References fvMatrix< Type >::boundaryManipulate(), and Foam::name().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr().
void boundaryManipulate | ( | typename GeometricField< Type, fvPatchField, volMesh >::Boundary & | values | ) |
Manipulate based on a boundary field.
Definition at line 679 of file fvMatrix.C.
References forAll, and patchi.
Referenced by kOmegaSST< TurbulenceModel, BasicTurbulenceModel >::correct(), fvMatrix< Type >::faceFluxCorrectionPtr(), and fvMatrix< Type >::relax().
autoPtr<fvSolver> solver | ( | const dictionary & | ) |
Construct and return the solver.
Use the given solver controls
Foam::autoPtr< typename Foam::fvMatrix< Type >::fvSolver > solver | ( | ) |
Construct and return the solver.
Solver controls read from fvSolution
Definition at line 279 of file fvMatrixSolve.C.
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr(), and fvMatrix< Type >::setComponentReference().
Foam::SolverPerformance< Type > solve | ( | const dictionary & | solverControls | ) |
Solve segregated or coupled returning the solution statistics.
Use the given solver controls
Definition at line 57 of file fvMatrixSolve.C.
References Foam::endl(), Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, Foam::Info, dictionary::lookupOrDefault(), messageStream::masterStream(), mesh, dictionary::readIfPresent(), fvMatrix< Type >::solveSegregated(), and Foam::type().
Referenced by Implicit< CloudType >::cacheFields(), Foam::checkMethod(), dynamicLagrangian< BasicTurbulenceModel >::correct(), Foam::CorrectPhi(), scalarTransport::execute(), thermalBaffle::solveEnergy(), and kinematicSingleLayer::solveThickness().
Foam::SolverPerformance< Type > solveSegregated | ( | const dictionary & | solverControls | ) |
Solve segregated returning the solution statistics.
Use the given solver controls
Definition at line 104 of file fvMatrixSolve.C.
References GeometricField< Type, PatchField, GeoMesh >::boundaryField(), Field< Type >::component(), GeometricField< Type, PatchField, GeoMesh >::correctBoundaryConditions(), Foam::diag(), Foam::endl(), Foam::Info, messageStream::masterStream(), mesh, DimensionedField< Type, GeoMesh >::mesh(), IOobject::name(), Foam::New(), GeometricField< Type, PatchField, GeoMesh >::primitiveField(), GeometricField< Type, PatchField, GeoMesh >::primitiveFieldRef(), SolverPerformance< Type >::print(), psi, solve(), and fvMatrix< Type >::solveCoupled().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr(), fvMatrix< Type >::fvSolver::solve(), and fvMatrix< Type >::solve().
Foam::SolverPerformance< Type > solveCoupled | ( | const dictionary & | solverControls | ) |
Solve coupled returning the solution statistics.
Use the given solver controls
Definition at line 219 of file fvMatrixSolve.C.
References GeometricField< Type, PatchField, GeoMesh >::boundaryFieldRef(), GeometricField< Type, PatchField, GeoMesh >::correctBoundaryConditions(), Foam::diag(), LduMatrix< Type, DType, LUType >::diag(), Foam::endl(), Foam::Info, messageStream::masterStream(), mesh, DimensionedField< Type, GeoMesh >::mesh(), IOobject::name(), SolverPerformance< Type >::print(), and psi.
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr(), and fvMatrix< Type >::solveSegregated().
Foam::SolverPerformance< Type > solve | ( | ) |
Solve returning the solution statistics.
Solver controls read from fvSolution
Definition at line 313 of file fvMatrixSolve.C.
References fvMatrix< Type >::fvSolver::solve().
Referenced by Foam::checkMethod(), and fvMatrix< Type >::setComponentReference().
Foam::tmp< Foam::Field< Type > > residual | ( | ) | const |
Return the matrix residual.
Definition at line 330 of file fvMatrixSolve.C.
References fvMatrix< Type >::addBoundaryDiag(), fvMatrix< Type >::addBoundarySource(), Field< Type >::component(), tmp< T >::ref(), Field< Type >::replace(), and lduMatrix::residual().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr().
Foam::tmp< Foam::scalarField > D | ( | ) | const |
Return the matrix scalar diagonal.
Definition at line 692 of file fvMatrix.C.
References fvMatrix< Type >::addCmptAvBoundaryDiag(), lduMatrix::diag(), and tmp< T >::ref().
Referenced by fvMatrix< Type >::A(), fvMatrix< Type >::faceFluxCorrectionPtr(), and fvMatrix< Type >::relax().
Foam::tmp< Foam::Field< Type > > DD | ( | ) | const |
Return the matrix Type diagonal.
Definition at line 701 of file fvMatrix.C.
References fvMatrix< Type >::addToInternalField(), fvPatchField< Type >::coupled(), lduMatrix::diag(), forAll, lduMatrix::lduAddr(), patchi, tmp< T >::ref(), and List< Type >::size().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr().
Foam::tmp< Foam::volScalarField > A | ( | ) | const |
Return the central coefficient.
Definition at line 725 of file fvMatrix.C.
References fvMatrix< Type >::D(), Foam::dimVol, IOobject::NO_READ, IOobject::NO_WRITE, and tmp< T >::ref().
Referenced by Foam::checkMethod(), meanVelocityForce::constrain(), fvMatrix< Type >::faceFluxCorrectionPtr(), and kinematicSingleLayer::solveThickness().
Foam::tmp< Foam::GeometricField< Type, Foam::fvPatchField, Foam::volMesh > > H | ( | ) | const |
Return the H operation source.
Definition at line 754 of file fvMatrix.C.
References fvMatrix< Type >::addBoundaryDiag(), fvMatrix< Type >::addBoundarySource(), fvMatrix< Type >::addCmptAvBoundaryDiag(), GeometricField< Type, PatchField, GeoMesh >::correctBoundaryConditions(), DimensionedField< Type, GeoMesh >::dimensions(), Foam::dimVol, lduMatrix::H(), IOobject::NO_READ, IOobject::NO_WRITE, GeometricField< Type, PatchField, GeoMesh >::primitiveFieldRef(), tmp< T >::ref(), and GeometricField< Type, PatchField, GeoMesh >::replace().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr(), and kinematicSingleLayer::solveThickness().
Foam::tmp< Foam::volScalarField > H1 | ( | ) | const |
Return H(1)
Definition at line 816 of file fvMatrix.C.
References fvMatrix< Type >::addToInternalField(), Foam::component(), fvPatchField< Type >::coupled(), Foam::dimVol, fvMatrix< Type >::flux(), forAll, lduMatrix::H1(), lduMatrix::lduAddr(), IOobject::NO_READ, IOobject::NO_WRITE, patchi, GeometricField< Type, PatchField, GeoMesh >::ref(), and List< Type >::size().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr().
Foam::tmp< Foam::GeometricField< Type, Foam::fvsPatchField, Foam::surfaceMesh > > flux | ( | ) | const |
Return the face-flux field from the matrix.
Definition at line 864 of file fvMatrix.C.
References Foam::abort(), GeometricField< Type, PatchField, GeoMesh >::boundaryFieldRef(), Foam::cmptMultiply(), fvMatrix< Type >::dimensions(), lduMatrix::faceH(), Foam::FatalError, FatalErrorInFunction, forAll, IOobject::NO_READ, IOobject::NO_WRITE, patchi, GeometricField< Type, PatchField, GeoMesh >::primitiveFieldRef(), and tmp< T >::ref().
Referenced by Implicit< CloudType >::cacheFields(), Foam::checkMethod(), Foam::CorrectPhi(), fvMatrix< Type >::faceFluxCorrectionPtr(), fvMatrix< Type >::H1(), Foam::MULES::implicitSolve(), and kinematicSingleLayer::solveThickness().
Definition at line 951 of file fvMatrix.C.
References Foam::abort(), Foam::FatalError, FatalErrorInFunction, and lduMatrix::operator=().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr(), and fvMatrix< Type >::operator=().
Definition at line 987 of file fvMatrix.C.
References fvMatrix< Type >::operator=().
void negate | ( | ) |
Definition at line 995 of file fvMatrix.C.
References lduMatrix::negate().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr().
Definition at line 1010 of file fvMatrix.C.
References Foam::checkMethod(), and lduMatrix::operator+=().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr(), and fvMatrix< Type >::operator+=().
Definition at line 1036 of file fvMatrix.C.
References fvMatrix< Type >::operator+=().
Definition at line 1044 of file fvMatrix.C.
References Foam::checkMethod(), and lduMatrix::operator-=().
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr(), and fvMatrix< Type >::operator-=().
Definition at line 1068 of file fvMatrix.C.
References fvMatrix< Type >::operator-=().
void operator+= | ( | const DimensionedField< Type, volMesh > & | su | ) |
Definition at line 1077 of file fvMatrix.C.
References Foam::checkMethod(), and fvMatrix< Type >::source().
void operator+= | ( | const tmp< DimensionedField< Type, volMesh >> & | tsu | ) |
Definition at line 1088 of file fvMatrix.C.
References fvMatrix< Type >::operator+=().
void operator+= | ( | const tmp< GeometricField< Type, fvPatchField, volMesh >> & | tsu | ) |
Definition at line 1099 of file fvMatrix.C.
References fvMatrix< Type >::operator+=().
void operator-= | ( | const DimensionedField< Type, volMesh > & | su | ) |
Definition at line 1110 of file fvMatrix.C.
References Foam::checkMethod(), and fvMatrix< Type >::source().
void operator-= | ( | const tmp< DimensionedField< Type, volMesh >> & | tsu | ) |
Definition at line 1121 of file fvMatrix.C.
References fvMatrix< Type >::operator-=().
void operator-= | ( | const tmp< GeometricField< Type, fvPatchField, volMesh >> & | tsu | ) |
Definition at line 1132 of file fvMatrix.C.
References fvMatrix< Type >::operator-=().
void operator+= | ( | const dimensioned< Type > & | su | ) |
Definition at line 1143 of file fvMatrix.C.
References fvMatrix< Type >::psi(), and fvMatrix< Type >::source().
void operator-= | ( | const dimensioned< Type > & | su | ) |
Definition at line 1153 of file fvMatrix.C.
References fvMatrix< Type >::psi(), and fvMatrix< Type >::source().
Definition at line 1163 of file fvMatrix.C.
Definition at line 1171 of file fvMatrix.C.
void operator*= | ( | const DimensionedField< scalar, volMesh > & | dsf | ) |
Definition at line 1179 of file fvMatrix.C.
References Foam::abort(), Foam::FatalError, FatalErrorInFunction, forAll, lduMatrix::operator*=(), and patchi.
Referenced by fvMatrix< Type >::faceFluxCorrectionPtr(), and fvMatrix< Type >::operator*=().
void operator*= | ( | const tmp< DimensionedField< scalar, volMesh >> & | tdsf | ) |
Definition at line 1209 of file fvMatrix.C.
References fvMatrix< Type >::operator*=().
void operator*= | ( | const tmp< volScalarField > & | tvsf | ) |
Definition at line 1220 of file fvMatrix.C.
References fvMatrix< Type >::operator*=().
void operator*= | ( | const dimensioned< scalar > & | ds | ) |
Definition at line 1231 of file fvMatrix.C.
References Foam::checkMethod(), and lduMatrix::operator*=().
void setComponentReference | ( | const label | patchi, |
const label | facei, | ||
const direction | , | ||
const scalar | value | ||
) |
Definition at line 33 of file fvScalarMatrix.C.
References Foam::diag(), patchi, and fvMatrix< Type >::solver().
Foam::autoPtr< Foam::fvMatrix< Foam::scalar >::fvSolver > solver | ( | const dictionary & | solverControls | ) |
Definition at line 58 of file fvScalarMatrix.C.
References Foam::diag(), Foam::endl(), Foam::Info, messageStream::masterStream(), mesh, Foam::New(), and fvMatrix< Type >::fvSolver::solve().
Foam::solverPerformance solveSegregated | ( | const dictionary & | solverControls | ) |
Definition at line 138 of file fvScalarMatrix.C.
References GeometricField< Type, PatchField, GeoMesh >::correctBoundaryConditions(), Foam::diag(), Foam::endl(), Foam::Info, messageStream::masterStream(), mesh, DimensionedField< Type, GeoMesh >::mesh(), IOobject::name(), Foam::New(), GeometricField< Type, PatchField, GeoMesh >::primitiveFieldRef(), SolverPerformance< Type >::print(), psi, and solve().
Foam::tmp< Foam::scalarField > residual | ( | ) | const |
Definition at line 187 of file fvScalarMatrix.C.
References tmp< T >::ref().
Foam::tmp< Foam::volScalarField > H | ( | ) | const |
Definition at line 211 of file fvScalarMatrix.C.
References GeometricField< Type, PatchField, GeoMesh >::correctBoundaryConditions(), Foam::dimVol, GeometricField< Type, PatchField, GeoMesh >::primitiveFieldRef(), and tmp< T >::ref().
Foam::tmp< Foam::volScalarField > H1 | ( | ) | const |
Definition at line 243 of file fvScalarMatrix.C.
References Foam::dimVol, and GeometricField< Type, PatchField, GeoMesh >::ref().
void setComponentReference | ( | const label | patchi, |
const label | facei, | ||
const direction | , | ||
const scalar | value | ||
) |
autoPtr< fvMatrix< scalar >::fvSolver > solver | ( | const dictionary & | ) |
solverPerformance solveSegregated | ( | const dictionary & | ) |
tmp< scalarField > residual | ( | ) | const |
tmp< volScalarField > H | ( | ) | const |
tmp< volScalarField > H1 | ( | ) | const |
|
friend |
Declare friendship with the fvSolver class.
Definition at line 148 of file fvMatrix.H.
|
friend |
|
friend |
|
friend |
|
friend |