MRG: Integrated Foundation code to commit 7d6845d

This commit is contained in:
Andrew Heather
2017-03-23 14:33:33 +00:00
595 changed files with 7175 additions and 11727 deletions

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2017 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
@ -71,8 +71,8 @@ const char* Foam::NamedEnum
{
"none",
"sum",
"sumMag",
"weightedSum",
"sumMag",
"sumDirection",
"sumDirectionBalance",
"average",

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2015-2017 OpenCFD Ltd.
-------------------------------------------------------------------------------
License

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2015-2017 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
@ -147,6 +147,17 @@ processSameTypeValues
break;
}
case opWeightedSum:
{
if (weightField.size())
{
result = sum(weightField*values);
}
else
{
result = sum(values);
}
break;
}
{
if (returnReduce(weightField.empty(), andOp<bool>()))
{
@ -225,6 +236,20 @@ processSameTypeValues
result = gSum(factor*values);
break;
}
case opWeightedAreaIntegrate:
{
const scalarField magSf(mag(Sf));
if (weightField.size())
{
result = sum(weightField*magSf*values);
}
else
{
result = sum(magSf*values);
}
break;
}
case opMin:
{
result = gMin(values);

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2017 OpenCFD Ltd.
-------------------------------------------------------------------------------
License

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2016-2017 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
@ -80,19 +80,19 @@ Usage
The \c operation is one of:
\plaintable
none | No operation
sum | Sum
weightedSum | Weighted sum
sumMag | Sum of component magnitudes
average | Ensemble average
weightedAverage | Weighted average
volAverage | Volume weighted average
weightedVolAverage | Weighted volume average
volIntegrate | Volume integral
none | No operation
sum | Sum
weightedSum | Weighted sum
sumMag | Sum of component magnitudes
average | Ensemble average
weightedAverage | Weighted average
volAverage | Volume weighted average
weightedVolAverage | Weighted volume average
volIntegrate | Volume integral
weightedVolIntegrate | Weighted volume integral
min | Minimum
max | Maximum
CoV | Coefficient of variation: standard deviation/mean
min | Minimum
max | Maximum
CoV | Coefficient of variation: standard deviation/mean
\endplaintable
See also
@ -163,7 +163,7 @@ protected:
//- Operation to apply to values
operationType operation_;
//- Weight field name - only used for opWeightedAverage mode
//- Weight field name - only used for weighted modes
word weightFieldName_;

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2015-2017 OpenCFD Ltd.
-------------------------------------------------------------------------------
License