Diagonal time-integration of single source term
I am trying to time-integrate only a single source term defined by:
fvScalarMatrix eqn( fvm::ddt(x) == -fvm::Sp(coeff, x) );
eqn.relax();
eqn.solve();
It is failing with this error:
[4] --> FOAM FATAL ERROR:
[4] lowerPtr_ or upperPtr_ unallocated
[4]
[4] From function const scalarField& Foam::lduMatrix::lower() const
[4] in file matrices/lduMatrix/lduMatrix/lduMatrix.C at line 271.
[4]
FOAM parallel run aborting
The solver is defined as:
"(x)"
{
solver PCG;
preconditioner diagonal;
tolerance 1e-8;
relTol 0.001;
maxIter 400;
}
If I replace the fvm source term with the fvc operator:
fvScalarMatrix eqn( fvm::ddt(x) == -fvc::Sp(coeff, x) );
I get same error.
If I comment out the eqn.relax()
and just solve, I get a different error:
Foam::error::printStack(Foam::Ostream&) at ??:?
[34] #1 Foam::sigFpe::sigHandler(int) at ??:?
Is this type of equation supported?