mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
BUG: incorrect cellId check in fvMatrix::setReferences()
This commit is contained in:
@ -527,14 +527,14 @@ void Foam::fvMatrix<Type>::setReferences
|
|||||||
const bool forceReference
|
const bool forceReference
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
bool needRef = (forceReference || psi_.needReference());
|
const bool needRef = (forceReference || psi_.needReference());
|
||||||
|
|
||||||
if (needRef)
|
if (needRef)
|
||||||
{
|
{
|
||||||
forAll(cellLabels, celli)
|
forAll(cellLabels, celli)
|
||||||
{
|
{
|
||||||
label cellId = cellLabels[celli];
|
const label cellId = cellLabels[celli];
|
||||||
if (celli >= 0)
|
if (cellId >= 0)
|
||||||
{
|
{
|
||||||
source()[cellId] += diag()[cellId]*values[celli];
|
source()[cellId] += diag()[cellId]*values[celli];
|
||||||
diag()[cellId] += diag()[cellId];
|
diag()[cellId] += diag()[cellId];
|
||||||
|
|||||||
Reference in New Issue
Block a user