basicSpecieMixture: Corrected test for zero total mass-fraction

Resolves bug-report https://bugs.openfoam.org/view.php?id=3775
This commit is contained in:
Henry Weller
2022-01-07 10:20:52 +00:00
parent 1041a0c21b
commit 0b681597c4

View File

@ -2,7 +2,7 @@
========= | ========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org \\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2014-2021 OpenFOAM Foundation \\ / A nd | Copyright (C) 2014-2022 OpenFOAM Foundation
\\/ M anipulation | \\/ M anipulation |
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
License License
@ -200,7 +200,7 @@ void Foam::basicSpecieMixture::correctMassFractions()
Yt += Y_[i]; Yt += Y_[i];
} }
if (mag(max(Yt).value()) < rootVSmall) if (mag(min(Yt).value()) < rootVSmall)
{ {
FatalErrorInFunction FatalErrorInFunction
<< "Sum of mass fractions is zero for species " << species() << "Sum of mass fractions is zero for species " << species()