mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
GIT: resolved merge conflict
This commit is contained in:
@ -66,7 +66,7 @@ int main(int argc, char *argv[])
|
||||
fft::reverseTransform
|
||||
(
|
||||
K/(mag(K) + 1.0e-6) ^ forceGen.newField(), K.nn()
|
||||
)
|
||||
)*recRootN
|
||||
);
|
||||
|
||||
#include "globalProperties.H"
|
||||
|
||||
@ -19,3 +19,10 @@
|
||||
|
||||
Kmesh K(mesh);
|
||||
UOprocess forceGen(K, runTime.deltaTValue(), turbulenceProperties);
|
||||
|
||||
label ntot = 1;
|
||||
forAll(K.nn(), idim)
|
||||
{
|
||||
ntot *= K.nn()[idim];
|
||||
}
|
||||
const scalar recRootN = 1.0/Foam::sqrt(scalar(ntot));
|
||||
|
||||
@ -78,7 +78,6 @@ Description
|
||||
#include "XiModel.H"
|
||||
#include "PDRDragModel.H"
|
||||
#include "ignition.H"
|
||||
#include "Switch.H"
|
||||
#include "bound.H"
|
||||
#include "pimpleControl.H"
|
||||
#include "fvOptions.H"
|
||||
|
||||
@ -63,7 +63,6 @@ Description
|
||||
#include "XiModel.H"
|
||||
#include "PDRDragModel.H"
|
||||
#include "ignition.H"
|
||||
#include "Switch.H"
|
||||
#include "bound.H"
|
||||
#include "dynamicRefineFvMesh.H"
|
||||
#include "pimpleControl.H"
|
||||
|
||||
@ -58,14 +58,14 @@ Foam::PDRDragModel::PDRDragModel
|
||||
(
|
||||
PDRProperties.subDict
|
||||
(
|
||||
word(PDRProperties.lookup("PDRDragModel")) + "Coeffs"
|
||||
PDRProperties.get<word>("PDRDragModel") + "Coeffs"
|
||||
)
|
||||
),
|
||||
turbulence_(turbulence),
|
||||
rho_(rho),
|
||||
U_(U),
|
||||
phi_(phi),
|
||||
on_(PDRDragModelCoeffs_.lookup("drag"))
|
||||
on_(PDRDragModelCoeffs_.get<bool>("drag"))
|
||||
{}
|
||||
|
||||
|
||||
@ -81,7 +81,7 @@ bool Foam::PDRDragModel::read(const dictionary& PDRProperties)
|
||||
{
|
||||
PDRDragModelCoeffs_ = PDRProperties.optionalSubDict(type() + "Coeffs");
|
||||
|
||||
PDRDragModelCoeffs_.lookup("drag") >> on_;
|
||||
PDRDragModelCoeffs_.read("drag", on_);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -67,7 +67,7 @@ protected:
|
||||
const volVectorField& U_;
|
||||
const surfaceScalarField& phi_;
|
||||
|
||||
Switch on_;
|
||||
bool on_;
|
||||
|
||||
|
||||
private:
|
||||
|
||||
@ -36,9 +36,9 @@ Foam::autoPtr<Foam::PDRDragModel> Foam::PDRDragModel::New
|
||||
const surfaceScalarField& phi
|
||||
)
|
||||
{
|
||||
const word modelType(PDRProperties.lookup("PDRDragModel"));
|
||||
const word modelType(PDRProperties.get<word>("PDRDragModel"));
|
||||
|
||||
Info<< "Selecting flame-wrinkling model " << modelType << endl;
|
||||
Info<< "Selecting drag model " << modelType << endl;
|
||||
|
||||
auto cstrIter = dictionaryConstructorTablePtr_->cfind(modelType);
|
||||
|
||||
|
||||
@ -165,8 +165,8 @@ bool Foam::PDRDragModels::basic::read(const dictionary& PDRProperties)
|
||||
{
|
||||
PDRDragModel::read(PDRProperties);
|
||||
|
||||
PDRDragModelCoeffs_.lookup("Csu") >> Csu.value();
|
||||
PDRDragModelCoeffs_.lookup("Csk") >> Csk.value();
|
||||
PDRDragModelCoeffs_.read("Csu", Csu.value());
|
||||
PDRDragModelCoeffs_.read("Csk", Csk.value());
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -1,2 +1,3 @@
|
||||
Switch adjustTimeStep(runTime.controlDict().lookup("adjustTimeStep"));
|
||||
scalar maxDeltaT(readScalar(runTime.controlDict().lookup("maxDeltaT")));
|
||||
bool adjustTimeStep(runTime.controlDict().get<bool>("adjustTimeStep"));
|
||||
|
||||
scalar maxDeltaT(runTime.controlDict().get<scalar>("maxDeltaT"));
|
||||
|
||||
@ -1,3 +1,3 @@
|
||||
runTime.controlDict().lookup("adjustTimeStep") >> adjustTimeStep;
|
||||
runTime.controlDict().read("adjustTimeStep", adjustTimeStep);
|
||||
|
||||
maxDeltaT = readScalar(runTime.controlDict().lookup("maxDeltaT"));
|
||||
runTime.controlDict().read("maxDeltaT", maxDeltaT);
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
IOporosityModelList pZones(mesh);
|
||||
Switch pressureImplicitPorosity(false);
|
||||
bool pressureImplicitPorosity(false);
|
||||
|
||||
// nUCorrectors used for pressureImplicitPorosity
|
||||
int nUCorr = 0;
|
||||
|
||||
@ -13,9 +13,11 @@ IOdictionary gravitationalProperties
|
||||
);
|
||||
|
||||
const dimensionedVector g(gravitationalProperties.lookup("g"));
|
||||
const Switch rotating(gravitationalProperties.lookup("rotating"));
|
||||
const bool rotating(gravitationalProperties.get<bool>("rotating"));
|
||||
const dimensionedVector Omega =
|
||||
(
|
||||
rotating ? gravitationalProperties.lookup("Omega")
|
||||
: dimensionedVector("Omega", -dimTime, vector(0,0,0));
|
||||
: dimensionedVector("Omega", -dimTime, vector(0,0,0))
|
||||
);
|
||||
const dimensionedScalar magg = mag(g);
|
||||
const dimensionedVector gHat = g/magg;
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
IOporosityModelList pZones(mesh);
|
||||
Switch pressureImplicitPorosity(false);
|
||||
bool pressureImplicitPorosity(false);
|
||||
|
||||
// nUCorrectors used for pressureImplicitPorosity
|
||||
int nUCorr = 0;
|
||||
|
||||
@ -39,7 +39,7 @@ ThermalPhaseChangePhaseSystem
|
||||
HeatAndMassTransferPhaseSystem<BasePhaseSystem>(mesh),
|
||||
volatile_(this->lookup("volatile")),
|
||||
saturationModel_(saturationModel::New(this->subDict("saturationModel"))),
|
||||
massTransfer_(this->lookup("massTransfer"))
|
||||
massTransfer_(this->template get<bool>("massTransfer"))
|
||||
{
|
||||
|
||||
forAllConstIters(this->phasePairs_, phasePairIter)
|
||||
@ -357,7 +357,7 @@ void Foam::ThermalPhaseChangePhaseSystem<BasePhaseSystem>::correctThermo()
|
||||
|
||||
volScalarField iDmdtNew(iDmdt);
|
||||
|
||||
if (massTransfer_ )
|
||||
if (massTransfer_)
|
||||
{
|
||||
volScalarField H1
|
||||
(
|
||||
|
||||
@ -43,7 +43,6 @@ SourceFiles
|
||||
|
||||
#include "HeatAndMassTransferPhaseSystem.H"
|
||||
#include "saturationModel.H"
|
||||
#include "Switch.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
@ -71,7 +70,7 @@ protected:
|
||||
autoPtr<saturationModel> saturationModel_;
|
||||
|
||||
// Mass transfer enabled
|
||||
Switch massTransfer_;
|
||||
bool massTransfer_;
|
||||
|
||||
//- Interfacial Mass transfer rate
|
||||
HashPtrTable<volScalarField, phasePairKey, phasePairKey::hash>
|
||||
|
||||
@ -1,3 +1,3 @@
|
||||
const dictionary& stressControl = mesh.solutionDict().subDict("stressAnalysis");
|
||||
|
||||
Switch compactNormalStress(stressControl.lookup("compactNormalStress"));
|
||||
bool compactNormalStress(stressControl.get<bool>("compactNormalStress"));
|
||||
|
||||
@ -2,4 +2,4 @@
|
||||
|
||||
int nCorr = stressControl.lookupOrDefault<int>("nCorrectors", 1);
|
||||
|
||||
scalar convergenceTolerance(readScalar(stressControl.lookup("D")));
|
||||
scalar convergenceTolerance(stressControl.get<scalar>("D"));
|
||||
|
||||
@ -184,9 +184,7 @@
|
||||
volScalarField lambda(nu*E/((1.0 + nu)*(1.0 - 2.0*nu)));
|
||||
volScalarField threeK(E/(1.0 - 2.0*nu));
|
||||
|
||||
Switch planeStress(mechanicalProperties.lookup("planeStress"));
|
||||
|
||||
if (planeStress)
|
||||
if (mechanicalProperties.get<bool>("planeStress"))
|
||||
{
|
||||
Info<< "Plane Stress\n" << endl;
|
||||
|
||||
|
||||
@ -1,3 +1,3 @@
|
||||
nCorr = stressControl.lookupOrDefault<int>("nCorrectors", 1);
|
||||
convergenceTolerance = readScalar(stressControl.lookup("D"));
|
||||
stressControl.lookup("compactNormalStress") >> compactNormalStress;
|
||||
convergenceTolerance = stressControl.get<scalar>("D");
|
||||
compactNormalStress = stressControl.get<bool>("compactNormalStress");
|
||||
|
||||
@ -12,7 +12,7 @@ IOdictionary thermalProperties
|
||||
)
|
||||
);
|
||||
|
||||
Switch thermalStress(thermalProperties.lookup("thermalStress"));
|
||||
bool thermalStress(thermalProperties.get<bool>("thermalStress"));
|
||||
|
||||
volScalarField threeKalpha
|
||||
(
|
||||
@ -46,7 +46,6 @@ volScalarField DT
|
||||
|
||||
if (thermalStress)
|
||||
{
|
||||
|
||||
autoPtr<volScalarField> CPtr;
|
||||
|
||||
IOobject CIO
|
||||
|
||||
@ -39,7 +39,6 @@ Description
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "fvCFD.H"
|
||||
#include "Switch.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
|
||||
@ -164,9 +164,7 @@ void tractionDisplacementFvPatchVectorField::updateCoeffs()
|
||||
scalarField lambda(nu*E/((1.0 + nu)*(1.0 - 2.0*nu)));
|
||||
scalarField threeK(E/(1.0 - 2.0*nu));
|
||||
|
||||
Switch planeStress(mechanicalProperties.lookup("planeStress"));
|
||||
|
||||
if (planeStress)
|
||||
if (mechanicalProperties.get<bool>("planeStress"))
|
||||
{
|
||||
lambda = nu*E/((1.0 + nu)*(1.0 - nu));
|
||||
threeK = E/(1.0 - nu);
|
||||
@ -185,9 +183,7 @@ void tractionDisplacementFvPatchVectorField::updateCoeffs()
|
||||
+ twoMuLambda*fvPatchField<vector>::snGrad() - (n & sigmaD)
|
||||
)/twoMuLambda;
|
||||
|
||||
Switch thermalStress(thermalProperties.lookup("thermalStress"));
|
||||
|
||||
if (thermalStress)
|
||||
if (thermalProperties.get<bool>("thermalStress"))
|
||||
{
|
||||
const fvPatchField<scalar>& threeKalpha=
|
||||
patch().lookupPatchField<volScalarField, scalar>("threeKalpha");
|
||||
|
||||
@ -39,7 +39,6 @@ Description
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
#include "fvCFD.H"
|
||||
#include "Switch.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
|
||||
@ -163,9 +163,7 @@ void tractionDisplacementCorrectionFvPatchVectorField::updateCoeffs()
|
||||
scalarField mu(E/(2.0*(1.0 + nu)));
|
||||
scalarField lambda(nu*E/((1.0 + nu)*(1.0 - 2.0*nu)));
|
||||
|
||||
Switch planeStress(mechanicalProperties.lookup("planeStress"));
|
||||
|
||||
if (planeStress)
|
||||
if (mechanicalProperties.get<bool>("planeStress"))
|
||||
{
|
||||
lambda = nu*E/((1.0 + nu)*(1.0 - nu));
|
||||
}
|
||||
|
||||
@ -137,10 +137,9 @@ int main(int argc, char *argv[])
|
||||
<< cells.instance()/cells.local()/cells.name()
|
||||
<< nl << endl;
|
||||
|
||||
for (const label celli : cells)
|
||||
{
|
||||
cutCells.erase(celli);
|
||||
}
|
||||
|
||||
cutCells.retain(cells);
|
||||
|
||||
Info<< "Removed from cells to cut all the ones not in set "
|
||||
<< setName << nl << endl;
|
||||
}
|
||||
|
||||
@ -89,9 +89,7 @@ Foam::edgeStats::edgeStats(const polyMesh& mesh)
|
||||
|
||||
IOdictionary motionProperties(motionObj);
|
||||
|
||||
Switch twoDMotion(motionProperties.lookup("twoDMotion"));
|
||||
|
||||
if (twoDMotion)
|
||||
if (motionProperties.get<bool>("twoDMotion"))
|
||||
{
|
||||
Info<< "Correcting for 2D motion" << endl << endl;
|
||||
|
||||
|
||||
@ -658,9 +658,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
IOdictionary motionProperties(motionObj);
|
||||
|
||||
Switch twoDMotion(motionProperties.lookup("twoDMotion"));
|
||||
|
||||
if (twoDMotion)
|
||||
if (motionProperties.get<bool>("twoDMotion"))
|
||||
{
|
||||
Info<< "Correcting for 2D motion" << endl << endl;
|
||||
correct2DPtr = new twoDPointCorrector(mesh);
|
||||
|
||||
@ -297,7 +297,7 @@ int main(int argc, char *argv[])
|
||||
autoPtr<extrudeModel> model(extrudeModel::New(dict));
|
||||
|
||||
// Whether to flip normals
|
||||
const Switch flipNormals(dict.lookup("flipNormals"));
|
||||
const bool flipNormals(dict.get<bool>("flipNormals"));
|
||||
|
||||
// What to extrude
|
||||
const ExtrudeMode mode = ExtrudeModeNames.lookup
|
||||
@ -983,8 +983,7 @@ int main(int argc, char *argv[])
|
||||
// Merging front and back patch faces
|
||||
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Switch mergeFaces(dict.lookup("mergeFaces"));
|
||||
if (mergeFaces)
|
||||
if (dict.get<bool>("mergeFaces"))
|
||||
{
|
||||
if (mode == MESH)
|
||||
{
|
||||
@ -1009,7 +1008,6 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
|
||||
|
||||
polyTopoChanger stitcher(mesh);
|
||||
stitcher.setSize(1);
|
||||
|
||||
|
||||
@ -1536,8 +1536,8 @@ int main(int argc, char *argv[])
|
||||
mappedPatchBase::sampleMode sampleMode =
|
||||
mappedPatchBase::sampleModeNames_[dict.lookup("sampleMode")];
|
||||
|
||||
const Switch oneD(dict.lookup("oneD"));
|
||||
Switch oneDNonManifoldEdges(false);
|
||||
const bool oneD(dict.get<bool>("oneD"));
|
||||
bool oneDNonManifoldEdges(false);
|
||||
word oneDPatchType(emptyPolyPatch::typeName);
|
||||
if (oneD)
|
||||
{
|
||||
@ -1545,7 +1545,7 @@ int main(int argc, char *argv[])
|
||||
dict.lookup("oneDPolyPatchType") >> oneDPatchType;
|
||||
}
|
||||
|
||||
const Switch adaptMesh(dict.lookup("adaptMesh"));
|
||||
const bool adaptMesh(dict.get<bool>("adaptMesh"));
|
||||
|
||||
if (hasZones)
|
||||
{
|
||||
|
||||
@ -97,7 +97,7 @@ Foam::automatic::automatic
|
||||
(
|
||||
const dictionary& cellSizeCalcTypeDict,
|
||||
const triSurfaceMesh& surface,
|
||||
const scalar& defaultCellSize
|
||||
const scalar defaultCellSize
|
||||
)
|
||||
:
|
||||
cellSizeCalculationType
|
||||
@ -109,12 +109,15 @@ Foam::automatic::automatic
|
||||
),
|
||||
coeffsDict_(cellSizeCalcTypeDict.optionalSubDict(typeName + "Coeffs")),
|
||||
surfaceName_(surface.searchableSurface::name()),
|
||||
readCurvature_(Switch(coeffsDict_.lookup("curvature"))),
|
||||
curvatureFile_(coeffsDict_.lookup("curvatureFile")),
|
||||
readFeatureProximity_(Switch(coeffsDict_.lookup("featureProximity"))),
|
||||
featureProximityFile_(coeffsDict_.lookup("featureProximityFile")),
|
||||
readInternalCloseness_(Switch(coeffsDict_.lookup("internalCloseness"))),
|
||||
internalClosenessFile_(coeffsDict_.lookup("internalClosenessFile")),
|
||||
|
||||
readCurvature_(coeffsDict_.get<bool>("curvature")),
|
||||
readFeatureProximity_(coeffsDict_.get<bool>("featureProximity")),
|
||||
readInternalCloseness_(coeffsDict_.get<bool>("internalCloseness")),
|
||||
|
||||
curvatureFile_(coeffsDict_.get<word>("curvatureFile")),
|
||||
featureProximityFile_(coeffsDict_.get<word>("featureProximityFile")),
|
||||
internalClosenessFile_(coeffsDict_.get<word>("internalClosenessFile")),
|
||||
|
||||
curvatureCellSizeCoeff_
|
||||
(
|
||||
readScalar(coeffsDict_.lookup("curvatureCellSizeCoeff"))
|
||||
|
||||
@ -37,7 +37,6 @@ SourceFiles
|
||||
#include "cellSizeCalculationType.H"
|
||||
#include "triSurfaceFields.H"
|
||||
#include "PrimitivePatchInterpolation.H"
|
||||
#include "Switch.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
@ -54,9 +53,6 @@ class automatic
|
||||
:
|
||||
public cellSizeCalculationType
|
||||
{
|
||||
|
||||
private:
|
||||
|
||||
// Private data
|
||||
|
||||
//- Dictionary of coefficients for automatic cell sizing
|
||||
@ -65,13 +61,12 @@ private:
|
||||
//- Name of the surface. Used to write the cell size field
|
||||
const fileName surfaceName_;
|
||||
|
||||
const Switch readCurvature_;
|
||||
const bool readCurvature_;
|
||||
const bool readFeatureProximity_;
|
||||
const bool readInternalCloseness_;
|
||||
|
||||
const word curvatureFile_;
|
||||
|
||||
const Switch readFeatureProximity_;
|
||||
const word featureProximityFile_;
|
||||
|
||||
const Switch readInternalCloseness_;
|
||||
const word internalClosenessFile_;
|
||||
|
||||
//- The curvature values are multiplied by the inverse of this value to
|
||||
@ -100,13 +95,12 @@ public:
|
||||
(
|
||||
const dictionary& cellSizeCalcTypeDict,
|
||||
const triSurfaceMesh& surface,
|
||||
const scalar& defaultCellSize
|
||||
const scalar defaultCellSize
|
||||
);
|
||||
|
||||
|
||||
//- Destructor
|
||||
virtual ~automatic()
|
||||
{}
|
||||
virtual ~automatic() = default;
|
||||
|
||||
|
||||
// Member Functions
|
||||
|
||||
@ -42,43 +42,30 @@ Foam::cvControls::cvControls
|
||||
foamyHexMeshDict_.subDict("surfaceConformation")
|
||||
);
|
||||
|
||||
pointPairDistanceCoeff_ = readScalar
|
||||
(
|
||||
surfDict.lookup("pointPairDistanceCoeff")
|
||||
);
|
||||
pointPairDistanceCoeff_ =
|
||||
surfDict.get<scalar>("pointPairDistanceCoeff");
|
||||
|
||||
mixedFeaturePointPPDistanceCoeff_ = readScalar
|
||||
(
|
||||
surfDict.lookup("mixedFeaturePointPPDistanceCoeff")
|
||||
);
|
||||
mixedFeaturePointPPDistanceCoeff_ =
|
||||
surfDict.get<scalar>("mixedFeaturePointPPDistanceCoeff");
|
||||
|
||||
featurePointExclusionDistanceCoeff_ = readScalar
|
||||
(
|
||||
surfDict.lookup("featurePointExclusionDistanceCoeff")
|
||||
);
|
||||
featurePointExclusionDistanceCoeff_ =
|
||||
surfDict.get<scalar>("featurePointExclusionDistanceCoeff");
|
||||
|
||||
featureEdgeExclusionDistanceCoeff_ = readScalar
|
||||
(
|
||||
surfDict.lookup("featureEdgeExclusionDistanceCoeff")
|
||||
);
|
||||
featureEdgeExclusionDistanceCoeff_ =
|
||||
surfDict.get<scalar>("featureEdgeExclusionDistanceCoeff");
|
||||
|
||||
surfaceSearchDistanceCoeff_ =
|
||||
surfDict.get<scalar>("surfaceSearchDistanceCoeff");
|
||||
|
||||
surfaceSearchDistanceCoeff_ = readScalar
|
||||
(
|
||||
surfDict.lookup("surfaceSearchDistanceCoeff")
|
||||
);
|
||||
maxSurfaceProtrusionCoeff_ =
|
||||
surfDict.get<scalar>("maxSurfaceProtrusionCoeff");
|
||||
|
||||
maxSurfaceProtrusionCoeff_ = readScalar
|
||||
(
|
||||
surfDict.lookup("maxSurfaceProtrusionCoeff")
|
||||
);
|
||||
|
||||
maxQuadAngle_ = readScalar(surfDict.lookup("maxQuadAngle"));
|
||||
maxQuadAngle_ = surfDict.get<scalar>("maxQuadAngle");
|
||||
|
||||
surfaceConformationRebuildFrequency_ = max
|
||||
(
|
||||
1,
|
||||
readLabel(surfDict.lookup("surfaceConformationRebuildFrequency"))
|
||||
surfDict.get<label>("surfaceConformationRebuildFrequency")
|
||||
);
|
||||
|
||||
|
||||
@ -87,33 +74,23 @@ Foam::cvControls::cvControls
|
||||
surfDict.subDict("featurePointControls")
|
||||
);
|
||||
|
||||
specialiseFeaturePoints_ = Switch
|
||||
(
|
||||
featurePointControlsDict.lookup("specialiseFeaturePoints")
|
||||
);
|
||||
specialiseFeaturePoints_ =
|
||||
featurePointControlsDict.get<Switch>("specialiseFeaturePoints");
|
||||
|
||||
guardFeaturePoints_ = Switch
|
||||
(
|
||||
featurePointControlsDict.lookup("guardFeaturePoints")
|
||||
);
|
||||
guardFeaturePoints_ =
|
||||
featurePointControlsDict.get<Switch>("guardFeaturePoints");
|
||||
|
||||
edgeAiming_ = Switch
|
||||
(
|
||||
featurePointControlsDict.lookup("edgeAiming")
|
||||
);
|
||||
edgeAiming_ =
|
||||
featurePointControlsDict.get<Switch>("edgeAiming");
|
||||
|
||||
if (!guardFeaturePoints_)
|
||||
{
|
||||
snapFeaturePoints_ = Switch
|
||||
(
|
||||
featurePointControlsDict.lookup("snapFeaturePoints")
|
||||
);
|
||||
snapFeaturePoints_ =
|
||||
featurePointControlsDict.get<Switch>("snapFeaturePoints");
|
||||
}
|
||||
|
||||
circulateEdges_ = Switch
|
||||
(
|
||||
featurePointControlsDict.lookup("circulateEdges")
|
||||
);
|
||||
circulateEdges_ =
|
||||
featurePointControlsDict.get<Switch>("circulateEdges");
|
||||
|
||||
// Controls for coarse surface conformation
|
||||
|
||||
@ -122,62 +99,47 @@ Foam::cvControls::cvControls
|
||||
surfDict.subDict("conformationControls")
|
||||
);
|
||||
|
||||
surfacePtExclusionDistanceCoeff_ = readScalar
|
||||
(
|
||||
conformationControlsDict.lookup("surfacePtExclusionDistanceCoeff")
|
||||
);
|
||||
surfacePtExclusionDistanceCoeff_ =
|
||||
conformationControlsDict.get<scalar>("surfacePtExclusionDistanceCoeff");
|
||||
|
||||
edgeSearchDistCoeffSqr_ = sqr
|
||||
(
|
||||
readScalar
|
||||
(
|
||||
conformationControlsDict.lookup("edgeSearchDistCoeff")
|
||||
)
|
||||
conformationControlsDict.get<scalar>("edgeSearchDistCoeff")
|
||||
);
|
||||
|
||||
surfacePtReplaceDistCoeffSqr_ = sqr
|
||||
(
|
||||
readScalar
|
||||
(
|
||||
conformationControlsDict.lookup("surfacePtReplaceDistCoeff")
|
||||
)
|
||||
conformationControlsDict.get<scalar>("surfacePtReplaceDistCoeff")
|
||||
);
|
||||
|
||||
maxConformationIterations_ = readLabel
|
||||
(
|
||||
conformationControlsDict.lookup("maxIterations")
|
||||
);
|
||||
maxConformationIterations_ =
|
||||
conformationControlsDict.get<label>("maxIterations");
|
||||
|
||||
iterationToInitialHitRatioLimit_ = readScalar
|
||||
(
|
||||
conformationControlsDict.lookup("iterationToInitialHitRatioLimit")
|
||||
);
|
||||
iterationToInitialHitRatioLimit_ =
|
||||
conformationControlsDict.get<scalar>("iterationToInitialHitRatioLimit");
|
||||
|
||||
|
||||
// Motion control controls
|
||||
|
||||
const dictionary& motionDict(foamyHexMeshDict_.subDict("motionControl"));
|
||||
|
||||
defaultCellSize_ = readScalar(motionDict.lookup("defaultCellSize"));
|
||||
defaultCellSize_ = motionDict.get<scalar>("defaultCellSize");
|
||||
|
||||
minimumCellSize_ =
|
||||
readScalar(motionDict.lookup("minimumCellSizeCoeff"))*defaultCellSize_;
|
||||
motionDict.get<scalar>("minimumCellSizeCoeff")*defaultCellSize_;
|
||||
|
||||
objOutput_ = Switch(motionDict.lookupOrDefault<Switch>("objOutput", false));
|
||||
objOutput_ =
|
||||
motionDict.lookupOrDefault<Switch>("objOutput", false);
|
||||
|
||||
timeChecks_ = Switch
|
||||
(
|
||||
motionDict.lookupOrDefault<Switch>("timeChecks", false)
|
||||
);
|
||||
timeChecks_ =
|
||||
motionDict.lookupOrDefault<Switch>("timeChecks", false);
|
||||
|
||||
printVertexInfo_ = Switch
|
||||
(
|
||||
motionDict.lookupOrDefault<Switch>("printVertexInfo", false)
|
||||
);
|
||||
printVertexInfo_ =
|
||||
motionDict.lookupOrDefault<Switch>("printVertexInfo", false);
|
||||
|
||||
if (Pstream::parRun())
|
||||
{
|
||||
maxLoadUnbalance_ = readScalar(motionDict.lookup("maxLoadUnbalance"));
|
||||
maxLoadUnbalance_ = motionDict.get<scalar>("maxLoadUnbalance");
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -186,7 +148,7 @@ Foam::cvControls::cvControls
|
||||
|
||||
cosAlignmentAcceptanceAngle_ = cos
|
||||
(
|
||||
degToRad(readScalar(motionDict.lookup("alignmentAcceptanceAngle")))
|
||||
degToRad(motionDict.get<scalar>("alignmentAcceptanceAngle"))
|
||||
);
|
||||
|
||||
|
||||
@ -197,19 +159,15 @@ Foam::cvControls::cvControls
|
||||
motionDict.subDict("pointInsertionCriteria")
|
||||
);
|
||||
|
||||
insertionDistCoeff_ = readScalar
|
||||
(
|
||||
insertionDict.lookup("cellCentreDistCoeff")
|
||||
);
|
||||
insertionDistCoeff_ =
|
||||
insertionDict.get<scalar>("cellCentreDistCoeff");
|
||||
|
||||
faceAreaRatioCoeff_ = readScalar
|
||||
(
|
||||
insertionDict.lookup("faceAreaRatioCoeff")
|
||||
);
|
||||
faceAreaRatioCoeff_ =
|
||||
insertionDict.get<scalar>("faceAreaRatioCoeff");
|
||||
|
||||
cosInsertionAcceptanceAngle_ = cos
|
||||
(
|
||||
degToRad(readScalar(insertionDict.lookup("acceptanceAngle")))
|
||||
degToRad(insertionDict.get<scalar>("acceptanceAngle"))
|
||||
);
|
||||
|
||||
// Point removal criteria
|
||||
@ -219,10 +177,8 @@ Foam::cvControls::cvControls
|
||||
motionDict.subDict("pointRemovalCriteria")
|
||||
);
|
||||
|
||||
removalDistCoeff_ = readScalar
|
||||
(
|
||||
removalDict.lookup("cellCentreDistCoeff")
|
||||
);
|
||||
removalDistCoeff_ =
|
||||
removalDict.get<scalar>("cellCentreDistCoeff");
|
||||
|
||||
// polyMesh filtering controls
|
||||
|
||||
@ -231,34 +187,31 @@ Foam::cvControls::cvControls
|
||||
foamyHexMeshDict_.subDict("polyMeshFiltering")
|
||||
);
|
||||
|
||||
filterEdges_ = Switch
|
||||
(
|
||||
filteringDict.lookupOrDefault<Switch>("filterEdges", true)
|
||||
);
|
||||
filterEdges_ =
|
||||
filteringDict.lookupOrDefault<Switch>("filterEdges", true);
|
||||
|
||||
filterFaces_ = Switch
|
||||
(
|
||||
filteringDict.lookupOrDefault<Switch>("filterFaces", false)
|
||||
);
|
||||
filterFaces_ =
|
||||
filteringDict.lookupOrDefault<Switch>("filterFaces", false);
|
||||
|
||||
if (filterFaces_)
|
||||
{
|
||||
filterEdges_ = Switch::ON;
|
||||
filterEdges_ = filterFaces_;
|
||||
}
|
||||
|
||||
writeTetDualMesh_ = Switch(filteringDict.lookup("writeTetDualMesh"));
|
||||
writeTetDualMesh_ =
|
||||
filteringDict.get<Switch>("writeTetDualMesh");
|
||||
|
||||
writeCellShapeControlMesh_ =
|
||||
Switch(filteringDict.lookup("writeCellShapeControlMesh"));
|
||||
filteringDict.get<Switch>("writeCellShapeControlMesh");
|
||||
|
||||
if (Pstream::parRun())
|
||||
{
|
||||
writeBackgroundMeshDecomposition_ =
|
||||
Switch(filteringDict.lookup("writeBackgroundMeshDecomposition"));
|
||||
filteringDict.get<Switch>("writeBackgroundMeshDecomposition");
|
||||
}
|
||||
else
|
||||
{
|
||||
writeBackgroundMeshDecomposition_ = Switch(false);
|
||||
writeBackgroundMeshDecomposition_ = Switch::FALSE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -58,13 +58,10 @@ Foam::initialPointsMethod::initialPointsMethod
|
||||
(
|
||||
sqr
|
||||
(
|
||||
readScalar
|
||||
(
|
||||
initialPointsDict.lookup("minimumSurfaceDistanceCoeff")
|
||||
)
|
||||
initialPointsDict.get<scalar>("minimumSurfaceDistanceCoeff")
|
||||
)
|
||||
),
|
||||
fixInitialPoints_(Switch(initialPointsDict.lookup("fixInitialPoints")))
|
||||
fixInitialPoints_(initialPointsDict.get<bool>("fixInitialPoints"))
|
||||
{}
|
||||
|
||||
|
||||
@ -80,7 +77,7 @@ Foam::autoPtr<Foam::initialPointsMethod> Foam::initialPointsMethod::New
|
||||
const autoPtr<backgroundMeshDecomposition>& decomposition
|
||||
)
|
||||
{
|
||||
const word methodName(initialPointsDict.lookup("initialPointsMethod"));
|
||||
const word methodName(initialPointsDict.get<word>("initialPointsMethod"));
|
||||
|
||||
Info<< nl << "Selecting initialPointsMethod "
|
||||
<< methodName << endl;
|
||||
|
||||
@ -40,7 +40,6 @@ SourceFiles
|
||||
#include "backgroundMeshDecomposition.H"
|
||||
#include "dictionary.H"
|
||||
#include "Random.H"
|
||||
#include "Switch.H"
|
||||
#include "autoPtr.H"
|
||||
#include "runTimeSelectionTables.H"
|
||||
|
||||
@ -80,7 +79,7 @@ protected:
|
||||
// the local target cell size. Store square of value.
|
||||
scalar minimumSurfaceDistanceCoeffSqr_;
|
||||
|
||||
Switch fixInitialPoints_;
|
||||
bool fixInitialPoints_;
|
||||
|
||||
|
||||
private:
|
||||
@ -194,7 +193,7 @@ public:
|
||||
return detailsDict_;
|
||||
}
|
||||
|
||||
Switch fixInitialPoints() const
|
||||
bool fixInitialPoints() const
|
||||
{
|
||||
return fixInitialPoints_;
|
||||
}
|
||||
|
||||
@ -150,7 +150,7 @@ Foam::CV2D::CV2D
|
||||
),
|
||||
z_
|
||||
(
|
||||
point
|
||||
Foam::point
|
||||
(
|
||||
cvMeshDict.subDict("surfaceConformation").lookup("locationInMesh")
|
||||
).z()
|
||||
@ -260,7 +260,7 @@ void Foam::CV2D::insertGrid()
|
||||
{
|
||||
for (int j=0; j<nj; j++)
|
||||
{
|
||||
point p(x0 + i*deltax, y0 + j*deltay, 0);
|
||||
Foam::point p(x0 + i*deltax, y0 + j*deltay, 0);
|
||||
|
||||
if (meshControls().randomiseInitialGrid())
|
||||
{
|
||||
|
||||
@ -347,9 +347,9 @@ public:
|
||||
|
||||
// Conversion functions between point2D, point and Point
|
||||
|
||||
inline const point2D& toPoint2D(const point&) const;
|
||||
inline const point2D& toPoint2D(const Foam::point&) const;
|
||||
inline const point2DField toPoint2D(const pointField&) const;
|
||||
inline point toPoint3D(const point2D&) const;
|
||||
inline Foam::point toPoint3D(const point2D&) const;
|
||||
|
||||
#ifdef CGAL_INEXACT
|
||||
typedef const point2D& point2DFromPoint;
|
||||
@ -361,7 +361,7 @@ public:
|
||||
|
||||
inline point2DFromPoint toPoint2D(const Point&) const;
|
||||
inline PointFromPoint2D toPoint(const point2D&) const;
|
||||
inline point toPoint3D(const Point&) const;
|
||||
inline Foam::point toPoint3D(const Point&) const;
|
||||
|
||||
|
||||
// Point insertion
|
||||
|
||||
@ -121,7 +121,7 @@ inline const Foam::cv2DControls& Foam::CV2D::meshControls() const
|
||||
}
|
||||
|
||||
|
||||
inline const Foam::point2D& Foam::CV2D::toPoint2D(const point& p) const
|
||||
inline const Foam::point2D& Foam::CV2D::toPoint2D(const Foam::point& p) const
|
||||
{
|
||||
return reinterpret_cast<const point2D&>(p);
|
||||
}
|
||||
@ -140,7 +140,7 @@ inline const Foam::point2DField Foam::CV2D::toPoint2D(const pointField& p) const
|
||||
|
||||
inline Foam::point Foam::CV2D::toPoint3D(const point2D& p) const
|
||||
{
|
||||
return point(p.x(), p.y(), z_);
|
||||
return Foam::point(p.x(), p.y(), z_);
|
||||
}
|
||||
|
||||
|
||||
@ -175,7 +175,7 @@ inline Foam::CV2D::PointFromPoint2D Foam::CV2D::toPoint(const point2D& p) const
|
||||
|
||||
inline Foam::point Foam::CV2D::toPoint3D(const Point& P) const
|
||||
{
|
||||
return point(CGAL::to_double(P.x()), CGAL::to_double(P.y()), z_);
|
||||
return Foam::point(CGAL::to_double(P.x()), CGAL::to_double(P.y()), z_);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -210,8 +210,8 @@ void Foam::CV2D::extractPatches
|
||||
|| (vB->internalOrBoundaryPoint() && !vA->internalOrBoundaryPoint())
|
||||
)
|
||||
{
|
||||
point ptA = toPoint3D(vA->point());
|
||||
point ptB = toPoint3D(vB->point());
|
||||
Foam::point ptA = toPoint3D(vA->point());
|
||||
Foam::point ptB = toPoint3D(vB->point());
|
||||
|
||||
label patchIndex = qSurf_.findPatch(ptA, ptB);
|
||||
|
||||
|
||||
@ -81,7 +81,7 @@ int main(int argc, char *argv[])
|
||||
);
|
||||
const dictionary& extrusionDict(controlDict.subDict("extrusion"));
|
||||
|
||||
Switch extrude(extrusionDict.lookup("extrude"));
|
||||
const bool extrude = extrusionDict.get<bool>("extrude");
|
||||
const bool overwrite = args.found("overwrite");
|
||||
|
||||
// Read and triangulation
|
||||
|
||||
@ -295,7 +295,7 @@ void Foam::CV2D::markNearBoundaryPoints()
|
||||
{
|
||||
if (vit->internalPoint())
|
||||
{
|
||||
point vert(toPoint3D(vit->point()));
|
||||
Foam::point vert(toPoint3D(vit->point()));
|
||||
|
||||
pointIndexHit pHit;
|
||||
label hitSurface = -1;
|
||||
|
||||
@ -109,8 +109,8 @@ void Foam::CV2D::insertFeaturePoints()
|
||||
{
|
||||
const edge& e = feMesh.edges()[edgeI];
|
||||
|
||||
const point& ep0 = points[e.start()];
|
||||
const point& ep1 = points[e.end()];
|
||||
const Foam::point& ep0 = points[e.start()];
|
||||
const Foam::point& ep1 = points[e.end()];
|
||||
|
||||
const linePointRef line(ep0, ep1);
|
||||
|
||||
|
||||
@ -39,7 +39,7 @@ bool Foam::CV2D::dualCellSurfaceIntersection
|
||||
{
|
||||
if (!is_infinite(ec))
|
||||
{
|
||||
point e0 = toPoint3D(circumcenter(ec->first));
|
||||
Foam::point e0 = toPoint3D(circumcenter(ec->first));
|
||||
|
||||
// If edge end is outside bounding box then edge cuts boundary
|
||||
if (!qSurf_.globalBounds().contains(e0))
|
||||
@ -47,7 +47,8 @@ bool Foam::CV2D::dualCellSurfaceIntersection
|
||||
return true;
|
||||
}
|
||||
|
||||
point e1 = toPoint3D(circumcenter(ec->first->neighbor(ec->second)));
|
||||
Foam::point e1 =
|
||||
toPoint3D(circumcenter(ec->first->neighbor(ec->second)));
|
||||
|
||||
// If other edge end is outside bounding box then edge cuts boundary
|
||||
if (!qSurf_.globalBounds().contains(e1))
|
||||
|
||||
@ -141,12 +141,13 @@ autoPtr<refinementSurfaces> createRefinementSurfaces
|
||||
// Invert surfaceCellSize to get the refinementLevel
|
||||
|
||||
const word scsFuncName =
|
||||
shapeDict.lookup("surfaceCellSizeFunction");
|
||||
shapeDict.get<word>("surfaceCellSizeFunction");
|
||||
|
||||
const dictionary& scsDict =
|
||||
shapeDict.optionalSubDict(scsFuncName + "Coeffs");
|
||||
|
||||
const scalar surfaceCellSize =
|
||||
readScalar(scsDict.lookup("surfaceCellSizeCoeff"));
|
||||
scsDict.get<scalar>("surfaceCellSizeCoeff");
|
||||
|
||||
const label refLevel = sizeCoeffToRefinement
|
||||
(
|
||||
@ -222,7 +223,7 @@ autoPtr<refinementSurfaces> createRefinementSurfaces
|
||||
);
|
||||
|
||||
const word scsFuncName =
|
||||
shapeControlRegionDict.lookup
|
||||
shapeControlRegionDict.get<word>
|
||||
(
|
||||
"surfaceCellSizeFunction"
|
||||
);
|
||||
@ -233,10 +234,7 @@ autoPtr<refinementSurfaces> createRefinementSurfaces
|
||||
);
|
||||
|
||||
const scalar surfaceCellSize =
|
||||
readScalar
|
||||
(
|
||||
scsDict.lookup("surfaceCellSizeCoeff")
|
||||
);
|
||||
scsDict.get<scalar>("surfaceCellSizeCoeff");
|
||||
|
||||
const label refLevel = sizeCoeffToRefinement
|
||||
(
|
||||
@ -780,10 +778,10 @@ int main(int argc, char *argv[])
|
||||
const scalar mergeDist = getMergeDistance
|
||||
(
|
||||
mesh,
|
||||
readScalar(meshDict.lookup("mergeTolerance"))
|
||||
meshDict.get<scalar>("mergeTolerance")
|
||||
);
|
||||
|
||||
const Switch keepPatches(meshDict.lookupOrDefault("keepPatches", false));
|
||||
const bool keepPatches(meshDict.lookupOrDefault("keepPatches", false));
|
||||
|
||||
|
||||
// Read decomposePar dictionary
|
||||
@ -958,7 +956,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
// Calculate current ratio of hex cells v.s. wanted cell size
|
||||
const scalar defaultCellSize =
|
||||
readScalar(motionDict.lookup("defaultCellSize"));
|
||||
motionDict.get<scalar>("defaultCellSize");
|
||||
|
||||
const scalar initialCellSize = ::pow(meshPtr().V()[0], 1.0/3.0);
|
||||
|
||||
@ -1020,7 +1018,7 @@ int main(int argc, char *argv[])
|
||||
if (patchInfo.set(globalRegioni))
|
||||
{
|
||||
patchTypes[geomi][regioni] =
|
||||
word(patchInfo[globalRegioni].lookup("type"));
|
||||
patchInfo[globalRegioni].get<word>("type");
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -1449,11 +1447,11 @@ int main(int argc, char *argv[])
|
||||
// Now do the real work -refinement -snapping -layers
|
||||
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
const Switch wantRefine(meshDict.lookup("castellatedMesh"));
|
||||
const Switch wantSnap(meshDict.lookup("snap"));
|
||||
const Switch wantLayers(meshDict.lookup("addLayers"));
|
||||
const bool wantRefine(meshDict.get<bool>("castellatedMesh"));
|
||||
const bool wantSnap(meshDict.get<bool>("snap"));
|
||||
const bool wantLayers(meshDict.get<bool>("addLayers"));
|
||||
|
||||
const Switch mergePatchFaces
|
||||
const bool mergePatchFaces
|
||||
(
|
||||
meshDict.lookupOrDefault("mergePatchFaces", true)
|
||||
);
|
||||
|
||||
@ -457,16 +457,16 @@ int main(int argc, char *argv[])
|
||||
const word dictName("createBafflesDict");
|
||||
#include "setSystemMeshDictionaryIO.H"
|
||||
|
||||
Switch internalFacesOnly(false);
|
||||
bool internalFacesOnly(false);
|
||||
|
||||
Switch noFields(false);
|
||||
bool noFields(false);
|
||||
|
||||
PtrList<faceSelection> selectors;
|
||||
{
|
||||
Info<< "Reading baffle criteria from " << dictName << nl << endl;
|
||||
IOdictionary dict(dictIO);
|
||||
|
||||
dict.lookup("internalFacesOnly") >> internalFacesOnly;
|
||||
internalFacesOnly = dict.get<bool>("internalFacesOnly");
|
||||
noFields = dict.lookupOrDefault("noFields", false);
|
||||
|
||||
const dictionary& selectionsDict = dict.subDict("baffles");
|
||||
@ -730,10 +730,9 @@ int main(int argc, char *argv[])
|
||||
// master and slave in different groupNames
|
||||
// (ie 3D thermal baffles)
|
||||
|
||||
Switch sameGroup
|
||||
(
|
||||
patchSource.lookupOrDefault("sameGroup", true)
|
||||
);
|
||||
const bool sameGroup =
|
||||
patchSource.lookupOrDefault("sameGroup", true);
|
||||
|
||||
if (!sameGroup)
|
||||
{
|
||||
groupNameMaster = groupName + "Group_master";
|
||||
@ -813,7 +812,6 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
|
||||
|
||||
createFaces
|
||||
(
|
||||
internalFacesOnly,
|
||||
@ -910,10 +908,8 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
const dictionary& patchSource = dict.subDict("patchPairs");
|
||||
|
||||
Switch sameGroup
|
||||
(
|
||||
patchSource.lookupOrDefault("sameGroup", true)
|
||||
);
|
||||
const bool sameGroup =
|
||||
patchSource.lookupOrDefault("sameGroup", true);
|
||||
|
||||
const word& groupName = selectors[selectorI].name();
|
||||
|
||||
|
||||
@ -41,7 +41,6 @@ SourceFiles
|
||||
#include "autoPtr.H"
|
||||
#include "boolList.H"
|
||||
#include "labelList.H"
|
||||
#include "Switch.H"
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
@ -71,7 +70,7 @@ protected:
|
||||
const dictionary dict_;
|
||||
|
||||
//- Switch direction?
|
||||
const Switch flip_;
|
||||
const bool flip_;
|
||||
|
||||
public:
|
||||
|
||||
|
||||
@ -540,8 +540,7 @@ int main(int argc, char *argv[])
|
||||
IOdictionary dict(dictIO);
|
||||
|
||||
// Whether to synchronise points
|
||||
const Switch pointSync(dict.lookup("pointSync"));
|
||||
|
||||
const bool pointSync(dict.get<bool>("pointSync"));
|
||||
|
||||
const polyBoundaryMesh& patches = mesh.boundaryMesh();
|
||||
|
||||
|
||||
@ -50,7 +50,7 @@ Usage
|
||||
Write differences with respect to the specified dictionary
|
||||
(or sub entry if -entry specified)
|
||||
|
||||
- \par -diffEtc \<dictionary\>
|
||||
- \par -diff-etc \<dictionary\>
|
||||
Write differences with respect to the specified dictionary
|
||||
(or sub entry if -entry specified)
|
||||
|
||||
@ -94,13 +94,13 @@ Usage
|
||||
|
||||
- Write the differences with respect to a template dictionary:
|
||||
\verbatim
|
||||
foamDictionary 0/U -diffEtc templates/closedVolume/0/U
|
||||
foamDictionary 0/U -diff-etc templates/closedVolume/0/U
|
||||
\endverbatim
|
||||
|
||||
- Write the differences in boundaryField with respect to a
|
||||
template dictionary:
|
||||
\verbatim
|
||||
foamDictionary 0/U -diffEtc templates/closedVolume/0/U \
|
||||
foamDictionary 0/U -diff-etc templates/closedVolume/0/U \
|
||||
-entry boundaryField
|
||||
\endverbatim
|
||||
|
||||
@ -217,11 +217,9 @@ const dictionary& lookupScopedDict
|
||||
if (!eptr || !eptr->isDict())
|
||||
{
|
||||
FatalIOErrorInFunction(dict)
|
||||
<< "keyword " << subDictName
|
||||
<< " is undefined in dictionary "
|
||||
<< dict.name() << " or is not a dictionary"
|
||||
<< endl
|
||||
<< "Valid keywords are " << dict.keys()
|
||||
<< "'" << subDictName << "' not found in dictionary "
|
||||
<< dict.name() << " or is not a dictionary" << nl
|
||||
<< "Known entries are " << dict.keys()
|
||||
<< exit(FatalIOError);
|
||||
}
|
||||
|
||||
@ -300,10 +298,12 @@ int main(int argc, char *argv[])
|
||||
);
|
||||
argList::addOption
|
||||
(
|
||||
"diffEtc",
|
||||
"diff-etc",
|
||||
"dict",
|
||||
"As per -diff, but locate the file as per foamEtcFile"
|
||||
);
|
||||
argList::addOptionCompat("diff-etc", {"diffEtc", 1712});
|
||||
|
||||
argList::addBoolOption
|
||||
(
|
||||
"includes",
|
||||
@ -371,10 +371,10 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
|
||||
|
||||
// Has "diff" or "diffEtc"
|
||||
// Has "diff" or "diff-etc"
|
||||
bool optDiff = false;
|
||||
|
||||
// Reference dictionary for -diff / -diffEtc
|
||||
// Reference dictionary for -diff / -diff-etc
|
||||
dictionary diffDict;
|
||||
{
|
||||
fileName diffFileName;
|
||||
@ -392,7 +392,7 @@ int main(int argc, char *argv[])
|
||||
diffDict.read(diffFile, true);
|
||||
optDiff = true;
|
||||
}
|
||||
else if (args.readIfPresent("diffEtc", diffFileName))
|
||||
else if (args.readIfPresent("diff-etc", diffFileName))
|
||||
{
|
||||
fileName foundName = findEtcFile(diffFileName);
|
||||
if (foundName.empty())
|
||||
|
||||
@ -55,8 +55,8 @@ Usage
|
||||
}
|
||||
|
||||
|
||||
// Input file
|
||||
inputFile "postProcessing/faceSource1/surface/patch/patch.case";
|
||||
// Input files list
|
||||
files ("postProcessing/faceSource1/surface/patch/patch.case";)
|
||||
|
||||
// Surface reader
|
||||
reader ensight;
|
||||
|
||||
@ -37,7 +37,6 @@ Description
|
||||
#include "triSurfaceSearch.H"
|
||||
#include "argList.H"
|
||||
#include "Fstream.H"
|
||||
#include "Switch.H"
|
||||
#include "IOdictionary.H"
|
||||
#include "boundBox.H"
|
||||
#include "indexedOctree.H"
|
||||
@ -102,10 +101,8 @@ int main(int argc, char *argv[])
|
||||
<< exit(FatalError);
|
||||
}
|
||||
|
||||
Switch addFaceNeighbours
|
||||
(
|
||||
meshSubsetDict.lookup("addFaceNeighbours")
|
||||
);
|
||||
const bool addFaceNeighbours =
|
||||
meshSubsetDict.get<bool>("addFaceNeighbours");
|
||||
|
||||
const bool invertSelection =
|
||||
meshSubsetDict.lookupOrDefault("invertSelection", false);
|
||||
@ -231,7 +228,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
fileName surfName(surfDict.lookup("name"));
|
||||
|
||||
Switch outside(surfDict.lookup("outside"));
|
||||
const bool outside(surfDict.get<bool>("outside"));
|
||||
|
||||
if (outside)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user