45 const scalar coeffVal,
50 source_(mSize, sourceVal)
113 <<
"Different size matrices"
117 if (source_.size() != m.source_.size())
120 <<
"Different size source vectors"
134 const simpleMatrix<Type>& m1,
135 const simpleMatrix<Type>& m2
138 return simpleMatrix<Type>
142 m1.source_ + m2.source_
150 const simpleMatrix<Type>& m1,
151 const simpleMatrix<Type>& m2
154 return simpleMatrix<Type>
158 m1.source_ - m2.source_
167 const simpleMatrix<Type>& m
170 return simpleMatrix<Type>(
s*m.matrix_,
s*m.source_);
180 const simpleMatrix<Type>& m
183 os << static_cast<const scalarSquareMatrix&>(m) <<
nl << m.source_;
Generic templated field type.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
label m() const noexcept
The number of rows.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
SquareMatrix & operator=(const SquareMatrix &)=default
Copy assignment.
A simple square matrix solver with scalar coefficients.
void operator=(const simpleMatrix< Type > &)
Field< Type > solve() const
Solve the matrix using Gaussian elimination with pivoting.
Field< Type > LUsolve() const
Solve the matrix using LU decomposition with pivoting.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
OBJstream os(runTime.globalPath()/outputName)
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
errorManip< error > abort(error &err)
SquareMatrix< scalar > scalarSquareMatrix
void LUsolve(scalarSquareMatrix &matrix, List< Type > &source)
constexpr char nl
The newline '\n' character (0x0a)
SolverPerformance< Type > solve(faMatrix< Type > &, const dictionary &)
Solve returning the solution statistics given convergence tolerance.