diff --git a/src/thermophysicalModels/reactionThermo/mixtures/multiComponentMixture/multiComponentMixture.C b/src/thermophysicalModels/reactionThermo/mixtures/multiComponentMixture/multiComponentMixture.C index 4e8d40faff180430f9e1f282d74bf8a22c488ef5..0414b0077e302973a42dcd37225aeb75594c0ddd 100644 --- a/src/thermophysicalModels/reactionThermo/mixtures/multiComponentMixture/multiComponentMixture.C +++ b/src/thermophysicalModels/reactionThermo/mixtures/multiComponentMixture/multiComponentMixture.C @@ -6,6 +6,7 @@ \\/ M anipulation | ------------------------------------------------------------------------------- Copyright (C) 2011-2017 OpenFOAM Foundation + Copyright (C) 2021 OpenCFD Ltd. ------------------------------------------------------------------------------- License This file is part of OpenFOAM. @@ -59,13 +60,21 @@ void Foam::multiComponentMixture<ThermoType>::correctMassFractions() Yt += Y_[n]; } - if (mag(max(Yt).value()) < ROOTVSMALL) + if (mag(min(Yt).value()) < ROOTVSMALL) { FatalErrorInFunction << "Sum of mass fractions is zero for species " << this->species() << exit(FatalError); } + if (mag(max(Yt).value()) != scalar(1)) + { + WarningInFunction + << "Sum of mass fractions is different from one for species " + << this->species() + << nl; + } + forAll(Y_, n) { Y_[n] /= Yt; diff --git a/tutorials/combustion/fireFoam/LES/compartmentFire/0/N2 b/tutorials/combustion/fireFoam/LES/compartmentFire/0/N2 index af2cab4616cc1f50776e431c190a1dba84e2ed2e..1c54ddf0695a41498a3fac7474f375b0e802dfd2 100644 --- a/tutorials/combustion/fireFoam/LES/compartmentFire/0/N2 +++ b/tutorials/combustion/fireFoam/LES/compartmentFire/0/N2 @@ -24,7 +24,7 @@ boundaryField inlet { type calculated; - value uniform 0.76699; + value uniform 0; } entrainment { diff --git a/tutorials/combustion/fireFoam/LES/flameSpreadWaterSuppressionPanel/0/N2 b/tutorials/combustion/fireFoam/LES/flameSpreadWaterSuppressionPanel/0/N2 index df14991fc5945c44f24ebaaf5f08e2a0bec1e97c..322c1c51c39baa647803b5a071bd20075da42e92 100644 --- a/tutorials/combustion/fireFoam/LES/flameSpreadWaterSuppressionPanel/0/N2 +++ b/tutorials/combustion/fireFoam/LES/flameSpreadWaterSuppressionPanel/0/N2 @@ -43,7 +43,7 @@ boundaryField inlet { type calculated; - value $internalField; + value uniform 0; } region0_to_pyrolysisRegion_coupledWall diff --git a/tutorials/combustion/fireFoam/LES/oppositeBurningPanels/0/N2 b/tutorials/combustion/fireFoam/LES/oppositeBurningPanels/0/N2 index 8b2b4eb7240885accfdeb0b272f1cb52fd4654fd..2e97c7ef4012a34ebf5a8af915a77aadf82c07f4 100644 --- a/tutorials/combustion/fireFoam/LES/oppositeBurningPanels/0/N2 +++ b/tutorials/combustion/fireFoam/LES/oppositeBurningPanels/0/N2 @@ -40,7 +40,7 @@ boundaryField burner { type calculated; - value $internalField; + value uniform 0; } "(region0_to.*)" diff --git a/tutorials/combustion/fireFoam/LES/simplePMMApanel/0/N2 b/tutorials/combustion/fireFoam/LES/simplePMMApanel/0/N2 index 2bf2d847400d43beb9096fe04634e2865d3a3c47..f1967c47e8f21fe60961432e072594a50972fb6f 100644 --- a/tutorials/combustion/fireFoam/LES/simplePMMApanel/0/N2 +++ b/tutorials/combustion/fireFoam/LES/simplePMMApanel/0/N2 @@ -48,7 +48,8 @@ boundaryField region0_to_panelRegion_panel { - type zeroGradient; + type calculated; + value uniform 0; } } diff --git a/tutorials/combustion/fireFoam/LES/simplePMMApanel/0/O2 b/tutorials/combustion/fireFoam/LES/simplePMMApanel/0/O2 index 0dd4f49f062db59801b829eca55fd561a972fc5a..923aed5dbd565bc0cd7e0fe0d52411934cb36ba3 100644 --- a/tutorials/combustion/fireFoam/LES/simplePMMApanel/0/O2 +++ b/tutorials/combustion/fireFoam/LES/simplePMMApanel/0/O2 @@ -48,7 +48,8 @@ boundaryField region0_to_panelRegion_panel { - type zeroGradient; + type fixedValue; + value uniform 0; } } diff --git a/tutorials/combustion/fireFoam/LES/smallPoolFire2D/0/N2 b/tutorials/combustion/fireFoam/LES/smallPoolFire2D/0/N2 index 841b2c741fa0218ec60f8a765d0633ba66c1ad50..f0833ac8d6a0a220a696edb81f35dc4654794dd4 100644 --- a/tutorials/combustion/fireFoam/LES/smallPoolFire2D/0/N2 +++ b/tutorials/combustion/fireFoam/LES/smallPoolFire2D/0/N2 @@ -17,7 +17,7 @@ FoamFile dimensions [0 0 0 0 0 0 0]; -internalField uniform 0.76699; +internalField uniform 0.77; boundaryField { @@ -36,7 +36,7 @@ boundaryField inlet { type calculated; - value $internalField; + value uniform 0; } frontAndBack diff --git a/tutorials/combustion/fireFoam/LES/smallPoolFire2D/0/O2 b/tutorials/combustion/fireFoam/LES/smallPoolFire2D/0/O2 index 34d7964dd779296d6c4d9239df180ff23877cfb4..c16e79c331ce174b9e6b54a6de021f08125f0ce6 100644 --- a/tutorials/combustion/fireFoam/LES/smallPoolFire2D/0/O2 +++ b/tutorials/combustion/fireFoam/LES/smallPoolFire2D/0/O2 @@ -17,7 +17,7 @@ FoamFile dimensions [0 0 0 0 0 0 0]; -internalField uniform 0.23301; +internalField uniform 0.23; boundaryField { diff --git a/tutorials/combustion/fireFoam/LES/smallPoolFire3D/0/N2 b/tutorials/combustion/fireFoam/LES/smallPoolFire3D/0/N2 index e9c1c64659c670a320250d39eed15777ac67916e..735cb62c5b108c7e214398ab8db931e9da01a823 100644 --- a/tutorials/combustion/fireFoam/LES/smallPoolFire3D/0/N2 +++ b/tutorials/combustion/fireFoam/LES/smallPoolFire3D/0/N2 @@ -36,7 +36,7 @@ boundaryField inlet { type calculated; - value $internalField; + value uniform 0; } } diff --git a/tutorials/combustion/reactingFoam/laminar/counterFlowFlame2D/0/CH4 b/tutorials/combustion/reactingFoam/laminar/counterFlowFlame2D/0/CH4 index 92fe7b568da4247d64eb2f27301535f216eb6fbd..937e2fe75f0280bafcaab9d622d949fbd54600c7 100644 --- a/tutorials/combustion/reactingFoam/laminar/counterFlowFlame2D/0/CH4 +++ b/tutorials/combustion/reactingFoam/laminar/counterFlowFlame2D/0/CH4 @@ -23,7 +23,7 @@ boundaryField fuel { type fixedValue; - value uniform 1; + value uniform 10; } air @@ -36,7 +36,7 @@ boundaryField { type inletOutlet; inletValue uniform 0; - value uniform 0; + value uniform 1; } frontAndBack diff --git a/tutorials/combustion/reactingFoam/laminar/counterFlowFlame2D/0/N2 b/tutorials/combustion/reactingFoam/laminar/counterFlowFlame2D/0/N2 index 1b709fad89c9b471c9474fcf4857fc43ca8f5871..0cc0abbf41b81342ac86788525b968efbf64a01d 100644 --- a/tutorials/combustion/reactingFoam/laminar/counterFlowFlame2D/0/N2 +++ b/tutorials/combustion/reactingFoam/laminar/counterFlowFlame2D/0/N2 @@ -35,8 +35,8 @@ boundaryField outlet { type inletOutlet; - inletValue uniform 1; - value uniform 1; + inletValue uniform 0; + value uniform 0; } frontAndBack