Commit c909a5df authored by Andrew Heather's avatar Andrew Heather
Browse files

GIT: resolved merge conflict

parents 9258b558 616b91c0
......@@ -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;
}
......
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"));
runTime.controlDict().lookup("adjustTimeStep") >> adjustTimeStep;
runTime.controlDict().read("adjustTimeStep", adjustTimeStep);
maxDeltaT = readScalar(runTime.controlDict().lookup("maxDeltaT"));
runTime.controlDict().read("maxDeltaT", maxDeltaT);
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;
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>
......
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;
......
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
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment