Subtracts the off-diagonal entries from the diagonal.
for (register label face=0; face<l.size(); face++) { Diag[l[face]] -= Lower[face]; Diag[u[face]] -= Upper[face]; }
Where:
- Diag is the diagonal coefficient;
- l is the lduAddressing for the lower triangle;
- u is the lduAddressing for the upper triangle;
- Lower is the lower triangle; and
- Upper is the upper triangle.
In terms of discretization coefficients, this is equivalent to:
and in terms of matrix coefficients, this is:
Where:
- A are matrix coefficients; and
- o and n are the owner and neighbour indices.