mirror of
https://github.com/ParticulateFlow/CFDEMcoupling-PFM.git
synced 2025-12-08 06:37:44 +00:00
@ -1,3 +0,0 @@
|
|||||||
rcfdemSolverHeattransfer.C
|
|
||||||
|
|
||||||
EXE=$(CFDEM_APP_DIR)/rcfdemSolverHeattransfer
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
include $(CFDEM_ADD_LIBS_DIR)/additionalLibs
|
|
||||||
|
|
||||||
EXE_INC = \
|
|
||||||
-I$(CFDEM_OFVERSION_DIR) \
|
|
||||||
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
|
||||||
-I$(LIB_SRC)/meshTools/lnInclude \
|
|
||||||
-I$(LIB_SRC)/TurbulenceModels/turbulenceModels/lnInclude \
|
|
||||||
-I$(LIB_SRC)/TurbulenceModels/incompressible/lnInclude \
|
|
||||||
-I$(LIB_SRC)/transportModels \
|
|
||||||
-I$(LIB_SRC)/transportModels/incompressible/singlePhaseTransportModel \
|
|
||||||
-I$(CFDEM_SRC_DIR)/lagrangian/cfdemParticle/lnInclude \
|
|
||||||
-I$(CFDEM_SRC_DIR)/lagrangian/cfdemParticle/cfdTools \
|
|
||||||
-I$(CFDEM_SRC_DIR)/recurrence/lnInclude \
|
|
||||||
-I$(CFDEM_SRC_DIR)/lagrangian/cfdemParticle/derived/cfdemCloudRec \
|
|
||||||
|
|
||||||
EXE_LIBS = \
|
|
||||||
-L$(CFDEM_LIB_DIR)\
|
|
||||||
-lrecurrence \
|
|
||||||
-lturbulenceModels \
|
|
||||||
-lincompressibleTurbulenceModels \
|
|
||||||
-lincompressibleTransportModels \
|
|
||||||
-lfiniteVolume \
|
|
||||||
-lmeshTools \
|
|
||||||
-lfvOptions \
|
|
||||||
-l$(CFDEM_LIB_NAME) \
|
|
||||||
$(CFDEM_ADD_LIB_PATHS) \
|
|
||||||
$(CFDEM_ADD_LIBS)
|
|
||||||
@ -1,40 +0,0 @@
|
|||||||
volScalarField rhoeps = rhoRec*voidfractionRec;
|
|
||||||
|
|
||||||
particleCloud.energyContributions(Qsource);
|
|
||||||
|
|
||||||
particleCloud.energyCoefficients(QCoeff);
|
|
||||||
|
|
||||||
K = 0.5*magSqr(URec);
|
|
||||||
|
|
||||||
addSource = fvc::ddt(rhoeps, K) + fvc::div(phiRec, K) +
|
|
||||||
fvc::div
|
|
||||||
(
|
|
||||||
fvc::absolute(phiRec/fvc::interpolate(rhoRec), voidfractionRec*URec), pRec
|
|
||||||
);
|
|
||||||
|
|
||||||
|
|
||||||
fvScalarMatrix TEqn =
|
|
||||||
(
|
|
||||||
fvm::ddt(rhoeps, T)
|
|
||||||
+ fvm::div(phiRec, T)
|
|
||||||
+ addSource/Cv
|
|
||||||
- fvm::laplacian(voidfractionRec*thCond/Cv, T)
|
|
||||||
- Qsource/Cv
|
|
||||||
- fvm::Sp(QCoeff/Cv, T)
|
|
||||||
==
|
|
||||||
fvOptions(rhoeps, T) // no fvOptions support yet
|
|
||||||
);
|
|
||||||
|
|
||||||
//TEqn.relax(relaxCoeff);
|
|
||||||
|
|
||||||
fvOptions.constrain(TEqn); // no fvOptions support yet
|
|
||||||
|
|
||||||
TEqn.solve();
|
|
||||||
|
|
||||||
particleCloud.clockM().start(31,"postFlow");
|
|
||||||
counter++;
|
|
||||||
|
|
||||||
if((counter - couplingSubStep) % dtDEM2dtCFD == 0)
|
|
||||||
particleCloud.postFlow();
|
|
||||||
|
|
||||||
particleCloud.clockM().stop("postFlow");
|
|
||||||
@ -1,206 +0,0 @@
|
|||||||
// dummy fields
|
|
||||||
Info << "\nCreating dummy pressure field\n" << endl;
|
|
||||||
volScalarField pRec
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"pRec",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::MUST_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh
|
|
||||||
);
|
|
||||||
|
|
||||||
// recurrence fields
|
|
||||||
Info << "\nCreating recurrence fields.\n" << endl;
|
|
||||||
|
|
||||||
volScalarField rhoRec
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"rhoRec",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::MUST_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh//,
|
|
||||||
//dimensionedScalar("rhoRec", dimensionSet(1, -3, 0, 0, 0), 1.0)
|
|
||||||
);
|
|
||||||
|
|
||||||
volVectorField URec
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"URec",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::MUST_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh
|
|
||||||
);
|
|
||||||
|
|
||||||
volScalarField voidfractionRec
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"voidfractionRec",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::MUST_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh
|
|
||||||
);
|
|
||||||
|
|
||||||
volVectorField UsRec
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"UsRec",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::MUST_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh
|
|
||||||
);
|
|
||||||
|
|
||||||
// heat transfer fields
|
|
||||||
Info << "\nCreating heat transfer fields.\n" << endl;
|
|
||||||
|
|
||||||
volScalarField Qsource
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"Qsource",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::NO_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh,
|
|
||||||
dimensionedScalar("zero", dimensionSet(1,-1,-3,0,0,0,0), 0.0)
|
|
||||||
);
|
|
||||||
|
|
||||||
volScalarField QCoeff
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"QCoeff",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::NO_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh,
|
|
||||||
dimensionedScalar("zero", dimensionSet(1,-1,-3,-1,0,0,0), 0.0)
|
|
||||||
);
|
|
||||||
|
|
||||||
volScalarField thCond
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"thCond",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::READ_IF_PRESENT,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh,
|
|
||||||
dimensionedScalar("zero", dimensionSet(1,1,-3,-1,0,0,0), 0.0),
|
|
||||||
"zeroGradient"
|
|
||||||
);
|
|
||||||
|
|
||||||
volScalarField T
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"T",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::MUST_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh
|
|
||||||
);
|
|
||||||
|
|
||||||
// calculated fields
|
|
||||||
Info << "\nCreating fields subject to calculation\n" << endl;
|
|
||||||
volScalarField voidfraction
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"voidfraction",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::NO_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
voidfractionRec
|
|
||||||
);
|
|
||||||
|
|
||||||
volVectorField Us
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"Us",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::NO_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
UsRec
|
|
||||||
);
|
|
||||||
|
|
||||||
// write fields for t=t_start
|
|
||||||
voidfraction.write();
|
|
||||||
Us.write();
|
|
||||||
//===============================
|
|
||||||
|
|
||||||
|
|
||||||
Info << "Calculating face flux field phiRec\n" << endl;
|
|
||||||
surfaceScalarField phiRec
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"phiRec",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::READ_IF_PRESENT,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
linearInterpolate(URec*voidfractionRec*rhoRec) & mesh.Sf()
|
|
||||||
);
|
|
||||||
phiRec.write();
|
|
||||||
|
|
||||||
|
|
||||||
singlePhaseTransportModel laminarTransport(URec, phiRec);
|
|
||||||
|
|
||||||
autoPtr<incompressible::turbulenceModel> turbulence
|
|
||||||
(
|
|
||||||
incompressible::turbulenceModel::New(URec, phiRec, laminarTransport)
|
|
||||||
);
|
|
||||||
|
|
||||||
const IOdictionary& transportProps = mesh.lookupObject<IOdictionary>("transportProperties");
|
|
||||||
dimensionedScalar Cv(transportProps.lookup("Cv"));
|
|
||||||
|
|
||||||
volScalarField addSource
|
|
||||||
(
|
|
||||||
IOobject
|
|
||||||
(
|
|
||||||
"addSource",
|
|
||||||
runTime.timeName(),
|
|
||||||
mesh,
|
|
||||||
IOobject::NO_READ,
|
|
||||||
IOobject::AUTO_WRITE
|
|
||||||
),
|
|
||||||
mesh,
|
|
||||||
dimensionedScalar("zero", dimensionSet(1,-1,-3,0,0,0,0), 0.0)
|
|
||||||
);
|
|
||||||
|
|
||||||
Info << "Creating field kinetic energy K\n" << endl;
|
|
||||||
volScalarField K("K", 0.5*magSqr(URec));
|
|
||||||
@ -1,128 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------*\
|
|
||||||
CFDEMcoupling academic - Open Source CFD-DEM coupling
|
|
||||||
|
|
||||||
Contributing authors:
|
|
||||||
Thomas Lichtenegger
|
|
||||||
Copyright (C) 2015- Johannes Kepler University, Linz
|
|
||||||
-------------------------------------------------------------------------------
|
|
||||||
License
|
|
||||||
This file is part of CFDEMcoupling academic.
|
|
||||||
|
|
||||||
CFDEMcoupling academic is free software: you can redistribute it and/or modify it
|
|
||||||
under the terms of the GNU General Public License as published by
|
|
||||||
the Free Software Foundation, either version 3 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
CFDEMcoupling academic is distributed in the hope that it will be useful, but WITHOUT
|
|
||||||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
||||||
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
||||||
for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
|
||||||
along with CFDEMcoupling academic. If not, see <http://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
Application
|
|
||||||
rcfdemSolverHeattransfer
|
|
||||||
|
|
||||||
Description
|
|
||||||
Solves heat transfer between fluid and particles based on rCFD
|
|
||||||
|
|
||||||
\*---------------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
#include "fvCFD.H"
|
|
||||||
#include "singlePhaseTransportModel.H"
|
|
||||||
#include "turbulentTransportModel.H"
|
|
||||||
#include "fvOptions.H"
|
|
||||||
|
|
||||||
#include "cfdemCloudRec.H"
|
|
||||||
#include "recBase.H"
|
|
||||||
#include "recModel.H"
|
|
||||||
|
|
||||||
#include "cfdemCloudEnergy.H"
|
|
||||||
#include "clockModel.H"
|
|
||||||
#include "thermCondModel.H"
|
|
||||||
#include "energyModel.H"
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
||||||
|
|
||||||
int main(int argc, char *argv[])
|
|
||||||
{
|
|
||||||
#include "postProcess.H"
|
|
||||||
#include "setRootCase.H"
|
|
||||||
#include "createTime.H"
|
|
||||||
#include "createMesh.H"
|
|
||||||
#include "createControl.H"
|
|
||||||
#include "createFields.H"
|
|
||||||
#include "createFvOptions.H"
|
|
||||||
|
|
||||||
cfdemCloudRec<cfdemCloudEnergy> particleCloud(mesh);
|
|
||||||
recBase recurrenceBase(mesh);
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
||||||
|
|
||||||
Info << "\nCalculating particle trajectories based on recurrence statistics\n" << endl;
|
|
||||||
|
|
||||||
label recTimeIndex = 0;
|
|
||||||
scalar recTimeStep = recurrenceBase.recM().recTimeStep();
|
|
||||||
scalar startTime = runTime.startTime().value();
|
|
||||||
|
|
||||||
// control coupling behavior in case of substepping
|
|
||||||
// assumes constant timestep size
|
|
||||||
label counter = 0;
|
|
||||||
label couplingSubStep = recurrenceBase.couplingSubStep();//5;//3;
|
|
||||||
double dtProp = particleCloud.dataExchangeM().couplingTime() / runTime.deltaTValue();
|
|
||||||
label dtDEM2dtCFD = int(dtProp + 0.5);
|
|
||||||
Info << "deltaT_DEM / deltaT_CFD = " << dtDEM2dtCFD << endl;
|
|
||||||
if (dtDEM2dtCFD > 1)
|
|
||||||
Info << "coupling at substep " << couplingSubStep << endl;
|
|
||||||
|
|
||||||
|
|
||||||
while (runTime.run())
|
|
||||||
{
|
|
||||||
runTime++;
|
|
||||||
|
|
||||||
// do stuff (every lagrangian time step)
|
|
||||||
particleCloud.clockM().start(1,"Global");
|
|
||||||
|
|
||||||
Info << "Time = " << runTime.timeName() << nl << endl;
|
|
||||||
|
|
||||||
particleCloud.clockM().start(2,"Coupling");
|
|
||||||
|
|
||||||
particleCloud.evolve(voidfraction,Us,URec);
|
|
||||||
|
|
||||||
particleCloud.clockM().stop("Coupling");
|
|
||||||
|
|
||||||
particleCloud.clockM().start(26,"Flow");
|
|
||||||
#include "TEqImp.H"
|
|
||||||
particleCloud.clockM().stop("Flow");
|
|
||||||
|
|
||||||
particleCloud.clockM().start(32,"ReadFields");
|
|
||||||
if ( runTime.timeOutputValue() - startTime - (recTimeIndex+1)*recTimeStep + 1.0e-5 > 0.0 )
|
|
||||||
{
|
|
||||||
recurrenceBase.updateRecFields();
|
|
||||||
#include "updateFields.H"
|
|
||||||
recTimeIndex++;
|
|
||||||
}
|
|
||||||
particleCloud.clockM().stop("ReadFields");
|
|
||||||
|
|
||||||
particleCloud.clockM().start(33,"Output");
|
|
||||||
runTime.write();
|
|
||||||
particleCloud.clockM().stop("Output");
|
|
||||||
|
|
||||||
particleCloud.clockM().stop("Global");
|
|
||||||
|
|
||||||
Info << "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
|
|
||||||
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
|
|
||||||
<< nl << endl;
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
Info << "End\n" << endl;
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
|
||||||
@ -1,14 +0,0 @@
|
|||||||
recurrenceBase.recM().exportVolScalarField("voidfraction",voidfractionRec);
|
|
||||||
recurrenceBase.recM().exportVolScalarField("rho",rhoRec);
|
|
||||||
recurrenceBase.recM().exportVolScalarField("p",pRec);
|
|
||||||
recurrenceBase.recM().exportVolVectorField("Us",UsRec);
|
|
||||||
recurrenceBase.recM().exportVolVectorField("U",URec);
|
|
||||||
recurrenceBase.recM().exportSurfaceScalarField("phi",phiRec);
|
|
||||||
|
|
||||||
{
|
|
||||||
volScalarField& NuField(const_cast<volScalarField&>(mesh.lookupObject<volScalarField> ("NuField")));
|
|
||||||
recurrenceBase.recM().exportVolScalarField("NuField",NuField);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#include "updateRho.H"
|
|
||||||
@ -1,32 +0,0 @@
|
|||||||
// work-around for transient properties
|
|
||||||
// needs to be specified for each case
|
|
||||||
|
|
||||||
// case 1
|
|
||||||
|
|
||||||
forAll(rhoRec,cellI)
|
|
||||||
{
|
|
||||||
if (mesh.C()[cellI].z() < 0.00228)
|
|
||||||
rhoRec[cellI] = 1.18+(1.085-1.18)*Foam::exp(-0.065*runTime.timeOutputValue());
|
|
||||||
else if (mesh.C()[cellI].z() < 0.00456)
|
|
||||||
rhoRec[cellI] = 1.18+(1.01-1.18)*Foam::exp(-0.05*runTime.timeOutputValue());
|
|
||||||
else if (mesh.C()[cellI].z() < 0.00684)
|
|
||||||
rhoRec[cellI] = 1.18+(0.98-1.18)*Foam::exp(-0.0425*runTime.timeOutputValue());
|
|
||||||
else
|
|
||||||
rhoRec[cellI] = 1.18+(0.955-1.18)*Foam::exp(-0.0425*runTime.timeOutputValue());
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// case 2
|
|
||||||
/*
|
|
||||||
forAll(rhoRec,cellI)
|
|
||||||
{
|
|
||||||
if (mesh.C()[cellI].z() < 0.00228)
|
|
||||||
rhoRec[cellI] = 1.18+(1.115-1.18)*Foam::exp(-0.065*runTime.timeOutputValue());
|
|
||||||
else if (mesh.C()[cellI].z() < 0.00456)
|
|
||||||
rhoRec[cellI] = 1.18+(1.04-1.18)*Foam::exp(-0.05*runTime.timeOutputValue());
|
|
||||||
else if (mesh.C()[cellI].z() < 0.00684)
|
|
||||||
rhoRec[cellI] = 1.18+(1.005-1.18)*Foam::exp(-0.0425*runTime.timeOutputValue());
|
|
||||||
else
|
|
||||||
rhoRec[cellI] = 1.18+(0.96-1.18)*Foam::exp(-0.0425*runTime.timeOutputValue());
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
@ -18,7 +18,6 @@ This section lists all CFDEMcoupling solvers alphabetically.
|
|||||||
rStatAnalysis,
|
rStatAnalysis,
|
||||||
rcfdemSolverBase,
|
rcfdemSolverBase,
|
||||||
rcfdemSolverCoupledHeattransfer,
|
rcfdemSolverCoupledHeattransfer,
|
||||||
rcfdemSolverHeattransfer,
|
|
||||||
rcfdemSolverRhoSteadyPimple,
|
rcfdemSolverRhoSteadyPimple,
|
||||||
recSolverTurbTransport,
|
recSolverTurbTransport,
|
||||||
rtfmSolverSpecies,
|
rtfmSolverSpecies,
|
||||||
|
|||||||
@ -22,11 +22,14 @@ particleCellVolumeProps
|
|||||||
lowerThreshold scalar2;
|
lowerThreshold scalar2;
|
||||||
startTime scalar3;
|
startTime scalar3;
|
||||||
verbose;
|
verbose;
|
||||||
|
writeToFile switch1;
|
||||||
\} :pre
|
\} :pre
|
||||||
|
|
||||||
{scalar1} = only cells with a field value (magnitude) lower than this upper threshold are considered :l
|
{scalar1} = only cells with a field value (magnitude) lower than this upper threshold are considered :l
|
||||||
{scalar2} = only cells with a field value (magnitude) greater than this lower threshold are considered :l
|
{scalar2} = only cells with a field value (magnitude) greater than this lower threshold are considered :l
|
||||||
{scalar3} = (optional, default 0) start time of volume calculation and output :l
|
{scalar3} = (optional, default 0) start time of volume calculation and output :l
|
||||||
|
{verbose} = (optional, default false) keyword only (mostly used for debugging) :l
|
||||||
|
{switch1} = (optional, default false) switch for file output :l
|
||||||
:ule
|
:ule
|
||||||
|
|
||||||
[Examples:]
|
[Examples:]
|
||||||
|
|||||||
@ -30,6 +30,7 @@ volWeightedAverageProps
|
|||||||
upperThreshold scalar1;
|
upperThreshold scalar1;
|
||||||
lowerThreshold scalar2;
|
lowerThreshold scalar2;
|
||||||
verbose;
|
verbose;
|
||||||
|
writeToFile switch1;
|
||||||
\} :pre
|
\} :pre
|
||||||
|
|
||||||
{time} = (optional, default 0.) time to start the averaging :ulb,l
|
{time} = (optional, default 0.) time to start the averaging :ulb,l
|
||||||
@ -38,6 +39,7 @@ volWeightedAverageProps
|
|||||||
{scalar1} = only cells with a field value (magnitude) lower than this upper threshold are considered :l
|
{scalar1} = only cells with a field value (magnitude) lower than this upper threshold are considered :l
|
||||||
{scalar2} = only cells with a field value (magnitude) greater than this lower threshold are considered :l
|
{scalar2} = only cells with a field value (magnitude) greater than this lower threshold are considered :l
|
||||||
{verbose} = (optional, default false) keyword only (mostly used for debugging) :l
|
{verbose} = (optional, default false) keyword only (mostly used for debugging) :l
|
||||||
|
{switch1} = (optional, default false) switch for file output :l
|
||||||
:ule
|
:ule
|
||||||
|
|
||||||
[Examples:]
|
[Examples:]
|
||||||
|
|||||||
@ -17,7 +17,7 @@
|
|||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|
||||||
export CFDEM_PROJECT=CFDEM
|
export CFDEM_PROJECT=CFDEM
|
||||||
export CFDEM_VERSION=20.05
|
export CFDEM_VERSION=20.09
|
||||||
|
|
||||||
################################################################################
|
################################################################################
|
||||||
# USER EDITABLE PART: Changes made here may be lost with the next upgrade
|
# USER EDITABLE PART: Changes made here may be lost with the next upgrade
|
||||||
@ -199,6 +199,9 @@ alias cfdemCleanCFDEM='bash $CFDEM_PROJECT_DIR/etc/cleanCFDEMcoupling.sh'
|
|||||||
#- shortcut to compile LIGGGHTS + sublibraries
|
#- shortcut to compile LIGGGHTS + sublibraries
|
||||||
alias cfdemCompLIG='bash $CFDEM_PROJECT_DIR/etc/compileLIGGGHTS.sh'
|
alias cfdemCompLIG='bash $CFDEM_PROJECT_DIR/etc/compileLIGGGHTS.sh'
|
||||||
|
|
||||||
|
#- shortcut to compile LIGGGHTS sublibraries
|
||||||
|
alias cfdemCompLIGlib='bash $CFDEM_PROJECT_DIR/etc/compileLIGGGHTS_lib.sh'
|
||||||
|
|
||||||
#- shortcut to compile CFDEMcoupling +LIGGGHTS
|
#- shortcut to compile CFDEMcoupling +LIGGGHTS
|
||||||
alias cfdemCompCFDEMall='bash $CFDEM_PROJECT_DIR/etc/compileCFDEMcoupling_all.sh'
|
alias cfdemCompCFDEMall='bash $CFDEM_PROJECT_DIR/etc/compileCFDEMcoupling_all.sh'
|
||||||
|
|
||||||
|
|||||||
@ -15,7 +15,7 @@
|
|||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|
||||||
setenv CFDEM_PROJECT CFDEM
|
setenv CFDEM_PROJECT CFDEM
|
||||||
setenv CFDEM_VERSION 20.05
|
setenv CFDEM_VERSION 20.09
|
||||||
|
|
||||||
################################################################################
|
################################################################################
|
||||||
# USER EDITABLE PART: Changes made here may be lost with the next upgrade
|
# USER EDITABLE PART: Changes made here may be lost with the next upgrade
|
||||||
@ -232,6 +232,9 @@ alias cfdemCleanCFDEM 'bash $CFDEM_PROJECT_DIR/etc/cleanCFDEMcoupling.sh'
|
|||||||
#- shortcut to compile LIGGGHTS + sublibraries
|
#- shortcut to compile LIGGGHTS + sublibraries
|
||||||
alias cfdemCompLIG 'bash $CFDEM_PROJECT_DIR/etc/compileLIGGGHTS.sh'
|
alias cfdemCompLIG 'bash $CFDEM_PROJECT_DIR/etc/compileLIGGGHTS.sh'
|
||||||
|
|
||||||
|
#- shortcut to compile LIGGGHTS sublibraries
|
||||||
|
alias cfdemCompLIGlib 'bash $CFDEM_PROJECT_DIR/etc/compileLIGGGHTS_lib.sh'
|
||||||
|
|
||||||
#- shortcut to compile CFDEMcoupling +LIGGGHTS
|
#- shortcut to compile CFDEMcoupling +LIGGGHTS
|
||||||
alias cfdemCompCFDEMall 'bash $CFDEM_PROJECT_DIR/etc/compileCFDEMcoupling_all.sh'
|
alias cfdemCompCFDEMall 'bash $CFDEM_PROJECT_DIR/etc/compileCFDEMcoupling_all.sh'
|
||||||
|
|
||||||
|
|||||||
@ -1,5 +1,4 @@
|
|||||||
rcfdemSolverRhoSteadyPimple/dir
|
rcfdemSolverRhoSteadyPimple/dir
|
||||||
rcfdemSolverHeattransfer/dir
|
|
||||||
rcfdemSolverCoupledHeattransfer/dir
|
rcfdemSolverCoupledHeattransfer/dir
|
||||||
rStatAnalysis/dir
|
rStatAnalysis/dir
|
||||||
rcfdemSolverBase/dir
|
rcfdemSolverBase/dir
|
||||||
|
|||||||
@ -34,8 +34,8 @@ Description
|
|||||||
#ifndef versionInfo_H
|
#ifndef versionInfo_H
|
||||||
#define versionInfo_H
|
#define versionInfo_H
|
||||||
|
|
||||||
word CFDEMversion="PFM 20.05";
|
word CFDEMversion="PFM 20.09";
|
||||||
word compatibleLIGGGHTSversion="PFM 20.05";
|
word compatibleLIGGGHTSversion="PFM 20.09";
|
||||||
word OFversion="6";
|
word OFversion="6";
|
||||||
|
|
||||||
Info << "\nCFDEMcoupling version: " << CFDEMversion << endl;
|
Info << "\nCFDEMcoupling version: " << CFDEMversion << endl;
|
||||||
|
|||||||
@ -84,10 +84,12 @@ cfdemCloud::cfdemCloud
|
|||||||
ignore_(couplingProperties_.found("ignore")),
|
ignore_(couplingProperties_.found("ignore")),
|
||||||
allowCFDsubTimestep_(true),
|
allowCFDsubTimestep_(true),
|
||||||
limitDEMForces_(couplingProperties_.found("limitDEMForces")),
|
limitDEMForces_(couplingProperties_.found("limitDEMForces")),
|
||||||
|
phaseInForces_(couplingProperties_.found("phaseInForcesTime")),
|
||||||
getParticleDensities_(couplingProperties_.lookupOrDefault<bool>("getParticleDensities",false)),
|
getParticleDensities_(couplingProperties_.lookupOrDefault<bool>("getParticleDensities",false)),
|
||||||
getParticleEffVolFactors_(couplingProperties_.lookupOrDefault<bool>("getParticleEffVolFactors",false)),
|
getParticleEffVolFactors_(couplingProperties_.lookupOrDefault<bool>("getParticleEffVolFactors",false)),
|
||||||
getParticleTypes_(couplingProperties_.lookupOrDefault<bool>("getParticleTypes",false)),
|
getParticleTypes_(couplingProperties_.lookupOrDefault<bool>("getParticleTypes",false)),
|
||||||
maxDEMForce_(0.),
|
maxDEMForce_(0.),
|
||||||
|
phaseInForcesTime_(couplingProperties_.lookupOrDefault<scalar>("phaseInForcesTime",0.0)),
|
||||||
modelType_(couplingProperties_.lookup("modelType")),
|
modelType_(couplingProperties_.lookup("modelType")),
|
||||||
positions_(NULL),
|
positions_(NULL),
|
||||||
velocities_(NULL),
|
velocities_(NULL),
|
||||||
@ -368,6 +370,12 @@ cfdemCloud::cfdemCloud
|
|||||||
if (verbose_) Info << "nPatchesNonCyclic=" << nPatchesNonCyclic << ", nPatchesCyclic=" << nPatchesCyclic << endl;
|
if (verbose_) Info << "nPatchesNonCyclic=" << nPatchesNonCyclic << ", nPatchesCyclic=" << nPatchesCyclic << endl;
|
||||||
Warning << "Periodic handing is disabled because the domain is not fully periodic!\n" << endl;
|
Warning << "Periodic handing is disabled because the domain is not fully periodic!\n" << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// check if phasing-in time existing and is meaningful
|
||||||
|
if (phaseInForces_ && phaseInForcesTime_ < SMALL)
|
||||||
|
{
|
||||||
|
FatalError << "phasing-in time too small" << endl;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * //
|
||||||
@ -468,6 +476,19 @@ void cfdemCloud::setForces()
|
|||||||
}
|
}
|
||||||
Info << "largest particle-fluid interaction on particle: " << maxF << endl;
|
Info << "largest particle-fluid interaction on particle: " << maxF << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (phaseInForces_)
|
||||||
|
{
|
||||||
|
scalar tfrac = (mesh_.time().timeOutputValue()-mesh_.time().startTime().value())/phaseInForcesTime_;
|
||||||
|
if (tfrac <= 1.0)
|
||||||
|
{
|
||||||
|
for (int index = 0;index < numberOfParticles(); ++index)
|
||||||
|
{
|
||||||
|
for(int i=0;i<3;i++) DEMForces_[index][i] *= tfrac;
|
||||||
|
Cds_[index][0] *= tfrac;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void cfdemCloud::setParticleForceField()
|
void cfdemCloud::setParticleForceField()
|
||||||
|
|||||||
@ -96,6 +96,8 @@ protected:
|
|||||||
|
|
||||||
const bool limitDEMForces_;
|
const bool limitDEMForces_;
|
||||||
|
|
||||||
|
const bool phaseInForces_;
|
||||||
|
|
||||||
const bool getParticleDensities_;
|
const bool getParticleDensities_;
|
||||||
|
|
||||||
const bool getParticleEffVolFactors_;
|
const bool getParticleEffVolFactors_;
|
||||||
@ -104,6 +106,8 @@ protected:
|
|||||||
|
|
||||||
scalar maxDEMForce_;
|
scalar maxDEMForce_;
|
||||||
|
|
||||||
|
scalar phaseInForcesTime_;
|
||||||
|
|
||||||
const word modelType_;
|
const word modelType_;
|
||||||
|
|
||||||
double **positions_; // particle positions
|
double **positions_; // particle positions
|
||||||
|
|||||||
@ -966,6 +966,10 @@ void twoWayOne2One::extractCollected(T*& src, T**& dst, int width) const
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int twoWayOne2One::getNumberOfParticles() const
|
||||||
|
{
|
||||||
|
return particleCloud_.numberOfParticles();
|
||||||
|
}
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
|||||||
@ -208,6 +208,8 @@ public:
|
|||||||
template <typename T>
|
template <typename T>
|
||||||
void extractCollected(T*&, T**&, int width=1) const;
|
void extractCollected(T*&, T**&, int width=1) const;
|
||||||
|
|
||||||
|
int getNumberOfParticles() const;
|
||||||
|
|
||||||
scalar getCG() const { return lmp->force->cg(); }
|
scalar getCG() const { return lmp->force->cg(); }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@ -54,7 +54,11 @@ FinesFields::FinesFields
|
|||||||
velFieldName_(propsDict_.lookupOrDefault<word>("velFieldName","U")),
|
velFieldName_(propsDict_.lookupOrDefault<word>("velFieldName","U")),
|
||||||
U_(sm.mesh().lookupObject<volVectorField> (velFieldName_)),
|
U_(sm.mesh().lookupObject<volVectorField> (velFieldName_)),
|
||||||
voidfractionFieldName_(propsDict_.lookupOrDefault<word>("voidfractionFieldName","voidfraction")),
|
voidfractionFieldName_(propsDict_.lookupOrDefault<word>("voidfractionFieldName","voidfraction")),
|
||||||
|
#if OPENFOAM_VERSION_MAJOR < 5
|
||||||
|
voidfraction_(const_cast<volScalarField&>(sm.mesh().lookupObject<volScalarField>(voidfractionFieldName_))),
|
||||||
|
#else
|
||||||
voidfraction_(sm.mesh().lookupObjectRef<volScalarField> (voidfractionFieldName_)),
|
voidfraction_(sm.mesh().lookupObjectRef<volScalarField> (voidfractionFieldName_)),
|
||||||
|
#endif
|
||||||
UsFieldName_(propsDict_.lookupOrDefault<word>("granVelFieldName","Us")),
|
UsFieldName_(propsDict_.lookupOrDefault<word>("granVelFieldName","Us")),
|
||||||
UsField_(sm.mesh().lookupObject<volVectorField> (UsFieldName_)),
|
UsField_(sm.mesh().lookupObject<volVectorField> (UsFieldName_)),
|
||||||
pFieldName_(propsDict_.lookupOrDefault<word>("pFieldName","p")),
|
pFieldName_(propsDict_.lookupOrDefault<word>("pFieldName","p")),
|
||||||
@ -224,7 +228,7 @@ FinesFields::FinesFields
|
|||||||
g_("g",dimensionSet(0,1,-2,0,0),vector(0,0,-9.81)),
|
g_("g",dimensionSet(0,1,-2,0,0),vector(0,0,-9.81)),
|
||||||
alphaDynMax_(0.1),
|
alphaDynMax_(0.1),
|
||||||
alphaMax_(propsDict_.lookupOrDefault<scalar>("alphaMax",0.95)),
|
alphaMax_(propsDict_.lookupOrDefault<scalar>("alphaMax",0.95)),
|
||||||
alphaMinClog_(propsDict_.lookupOrDefault<scalar>("alphaMinClog",0.3)),
|
alphaMinClog_(propsDict_.lookupOrDefault<scalar>("alphaMinClog",0.1)),
|
||||||
critVoidfraction_(propsDict_.lookupOrDefault<scalar>("critVoidfraction", 0.05)),
|
critVoidfraction_(propsDict_.lookupOrDefault<scalar>("critVoidfraction", 0.05)),
|
||||||
deltaT_(voidfraction_.mesh().time().deltaTValue()),
|
deltaT_(voidfraction_.mesh().time().deltaTValue()),
|
||||||
depositionLength_(0.0),
|
depositionLength_(0.0),
|
||||||
@ -412,7 +416,7 @@ void FinesFields::calcSource()
|
|||||||
{
|
{
|
||||||
fKin = 0.0;
|
fKin = 0.0;
|
||||||
fStick = 0.0;
|
fStick = 0.0;
|
||||||
if (clogKin_ && alphaP_[cellI] > alphaMinClog_) // no kinetic cloggig in dilute regions
|
if (clogKin_ && alphaP_[cellI] > alphaMinClog_) // no cloggig in dilute regions
|
||||||
{
|
{
|
||||||
// calculate everything in units auf dSauter
|
// calculate everything in units auf dSauter
|
||||||
critpore = nCrit_*dFine_.value()/dSauter_[cellI];
|
critpore = nCrit_*dFine_.value()/dSauter_[cellI];
|
||||||
@ -428,7 +432,7 @@ void FinesFields::calcSource()
|
|||||||
else if (fKin > 1.0) fKin = 1.0;
|
else if (fKin > 1.0) fKin = 1.0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (clogStick_)
|
if (clogStick_ && alphaP_[cellI] > alphaMinClog_) // no cloggig in dilute regions
|
||||||
{
|
{
|
||||||
magU = mag(uReconstructed_()[cellI]); // use U reconstructed from phi to suppress oscillations at interfaces
|
magU = mag(uReconstructed_()[cellI]); // use U reconstructed from phi to suppress oscillations at interfaces
|
||||||
// fStick = 1.0 / ( 1.0 + magU/uBind_) * alphaP_[cellI] / 0.65;
|
// fStick = 1.0 / ( 1.0 + magU/uBind_) * alphaP_[cellI] / 0.65;
|
||||||
|
|||||||
@ -66,7 +66,9 @@ SchillerNaumannDrag::SchillerNaumannDrag
|
|||||||
propsDict_(dict.subDict(typeName + "Props")),
|
propsDict_(dict.subDict(typeName + "Props")),
|
||||||
verbose_(propsDict_.found("verbose")),
|
verbose_(propsDict_.found("verbose")),
|
||||||
velFieldName_(propsDict_.lookup("velFieldName")),
|
velFieldName_(propsDict_.lookup("velFieldName")),
|
||||||
U_(sm.mesh().lookupObject<volVectorField> (velFieldName_))
|
U_(sm.mesh().lookupObject<volVectorField> (velFieldName_)),
|
||||||
|
scaleDia_(1.),
|
||||||
|
scaleDrag_(1.)
|
||||||
{
|
{
|
||||||
//Append the field names to be probed
|
//Append the field names to be probed
|
||||||
particleCloud_.probeM().initialize(typeName, typeName+".logDat");
|
particleCloud_.probeM().initialize(typeName, typeName+".logDat");
|
||||||
@ -85,7 +87,12 @@ SchillerNaumannDrag::SchillerNaumannDrag
|
|||||||
// read those switches defined above, if provided in dict
|
// read those switches defined above, if provided in dict
|
||||||
forceSubM(0).readSwitches();
|
forceSubM(0).readSwitches();
|
||||||
|
|
||||||
particleCloud_.checkCG(false);
|
particleCloud_.checkCG(true);
|
||||||
|
|
||||||
|
if (propsDict_.found("scale"))
|
||||||
|
scaleDia_ = scalar(readScalar(propsDict_.lookup("scale")));
|
||||||
|
if (propsDict_.found("scaleDrag"))
|
||||||
|
scaleDrag_ = scalar(readScalar(propsDict_.lookup("scaleDrag")));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -99,6 +106,16 @@ SchillerNaumannDrag::~SchillerNaumannDrag()
|
|||||||
|
|
||||||
void SchillerNaumannDrag::setForce() const
|
void SchillerNaumannDrag::setForce() const
|
||||||
{
|
{
|
||||||
|
if (scaleDia_ > 1.0)
|
||||||
|
{
|
||||||
|
Info << "SchillerNaumann using scale = " << scaleDia_ << endl;
|
||||||
|
}
|
||||||
|
else if (particleCloud_.cg() > 1.0)
|
||||||
|
{
|
||||||
|
scaleDia_ = particleCloud_.cg();
|
||||||
|
Info << "SchillerNaumann using scale from liggghts cg = " << scaleDia_ << endl;
|
||||||
|
}
|
||||||
|
|
||||||
#include "setupProbeModel.H"
|
#include "setupProbeModel.H"
|
||||||
|
|
||||||
const volScalarField& nufField = forceSubM(0).nuField();
|
const volScalarField& nufField = forceSubM(0).nuField();
|
||||||
@ -117,6 +134,7 @@ void SchillerNaumannDrag::setForce() const
|
|||||||
vector Us = particleCloud_.velocity(index);
|
vector Us = particleCloud_.velocity(index);
|
||||||
vector Ur = U_[cellI]-Us;
|
vector Ur = U_[cellI]-Us;
|
||||||
scalar ds = 2*particleCloud_.radius(index);
|
scalar ds = 2*particleCloud_.radius(index);
|
||||||
|
scalar ds_scaled = ds/scaleDia_;
|
||||||
scalar nuf = nufField[cellI];
|
scalar nuf = nufField[cellI];
|
||||||
scalar rho = rhoField[cellI];
|
scalar rho = rhoField[cellI];
|
||||||
scalar voidfraction = particleCloud_.voidfraction(index);
|
scalar voidfraction = particleCloud_.voidfraction(index);
|
||||||
@ -127,30 +145,33 @@ void SchillerNaumannDrag::setForce() const
|
|||||||
if (magUr > 0)
|
if (magUr > 0)
|
||||||
{
|
{
|
||||||
// calc particle Re Nr
|
// calc particle Re Nr
|
||||||
Rep = ds*magUr/nuf;
|
Rep = ds_scaled*magUr/nuf;
|
||||||
|
|
||||||
// calc fluid drag Coeff
|
// calc fluid drag Coeff
|
||||||
Cd = max(0.44,24.0/Rep*(1.0+0.15*pow(Rep,0.687)));
|
Cd = max(0.44,24.0/Rep*(1.0+0.15*pow(Rep,0.687)));
|
||||||
|
|
||||||
// calc particle's drag
|
// calc particle's drag
|
||||||
drag = 0.125*Cd*rho*M_PI*ds*ds*magUr*Ur;
|
drag = 0.125*Cd*rho*M_PI*ds*ds*scaleDia_*magUr*Ur*scaleDrag_;
|
||||||
|
|
||||||
if (modelType_=="B")
|
if (modelType_=="B")
|
||||||
drag /= voidfraction;
|
drag /= voidfraction;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(verbose_ && index >100 && index <102)
|
if(verbose_ && index >=100 && index <102)
|
||||||
{
|
{
|
||||||
Info << "index = " << index << endl;
|
Pout << "cellI = " << cellI << endl;
|
||||||
Info << "Us = " << Us << endl;
|
Pout << "index = " << index << endl;
|
||||||
Info << "Ur = " << Ur << endl;
|
Pout << "Ufluid = " << U_[cellI] << endl;
|
||||||
Info << "ds = " << ds << endl;
|
Pout << "Us = " << Us << endl;
|
||||||
Info << "rho = " << rho << endl;
|
Pout << "Ur = " << Ur << endl;
|
||||||
Info << "nuf = " << nuf << endl;
|
Pout << "ds = " << ds << endl;
|
||||||
Info << "voidfraction = " << voidfraction << endl;
|
Pout << "ds/scale = " << ds_scaled << endl;
|
||||||
Info << "Rep = " << Rep << endl;
|
Pout << "rho = " << rho << endl;
|
||||||
Info << "Cd = " << Cd << endl;
|
Pout << "nuf = " << nuf << endl;
|
||||||
Info << "drag = " << drag << endl;
|
Pout << "voidfraction = " << voidfraction << endl;
|
||||||
|
Pout << "Rep = " << Rep << endl;
|
||||||
|
Pout << "Cd = " << Cd << endl;
|
||||||
|
Pout << "drag = " << drag << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
//Set value fields and write the probe
|
//Set value fields and write the probe
|
||||||
|
|||||||
@ -66,6 +66,10 @@ private:
|
|||||||
|
|
||||||
const volVectorField& U_;
|
const volVectorField& U_;
|
||||||
|
|
||||||
|
mutable scalar scaleDia_;
|
||||||
|
|
||||||
|
mutable scalar scaleDrag_;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
//- Runtime type information
|
//- Runtime type information
|
||||||
|
|||||||
@ -94,8 +94,17 @@ particleCellVolume::particleCellVolume
|
|||||||
),
|
),
|
||||||
upperThreshold_(readScalar(propsDict_.lookup("upperThreshold"))),
|
upperThreshold_(readScalar(propsDict_.lookup("upperThreshold"))),
|
||||||
lowerThreshold_(readScalar(propsDict_.lookup("lowerThreshold"))),
|
lowerThreshold_(readScalar(propsDict_.lookup("lowerThreshold"))),
|
||||||
verbose_(propsDict_.found("verbose"))
|
verbose_(propsDict_.found("verbose")),
|
||||||
|
writeToFile_(propsDict_.lookupOrDefault<Switch>("writeToFile",false)),
|
||||||
|
filePtr_()
|
||||||
{
|
{
|
||||||
|
// create the path and output file
|
||||||
|
if(writeToFile_)
|
||||||
|
{
|
||||||
|
fileName path(particleCloud_.IOM().createTimeDir("postProcessing/particleCellVolume"));
|
||||||
|
filePtr_.set(new OFstream(path/"particleCellVolume.txt"));
|
||||||
|
filePtr_() << "# time | total particle volume in cells | total volume of cells with particles | average volume fraction | min(voidfraction) | max(voidfraction)" << endl;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -120,6 +129,8 @@ void particleCellVolume::setForce() const
|
|||||||
|
|
||||||
scalar fieldValue=-1;
|
scalar fieldValue=-1;
|
||||||
scalar cellVol=-1;
|
scalar cellVol=-1;
|
||||||
|
scalar minFieldVal=1e18;
|
||||||
|
scalar maxFieldVal=-1e18;
|
||||||
|
|
||||||
forAll(field,cellI)
|
forAll(field,cellI)
|
||||||
{
|
{
|
||||||
@ -129,6 +140,8 @@ void particleCellVolume::setForce() const
|
|||||||
cellVol = mesh_.V()[cellI];
|
cellVol = mesh_.V()[cellI];
|
||||||
scalarField_[cellI] = (1-fieldValue) * cellVol;
|
scalarField_[cellI] = (1-fieldValue) * cellVol;
|
||||||
scalarField2_[cellI] = cellVol;
|
scalarField2_[cellI] = cellVol;
|
||||||
|
minFieldVal = min(minFieldVal, fieldValue);
|
||||||
|
maxFieldVal = max(maxFieldVal, fieldValue);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -138,6 +151,8 @@ void particleCellVolume::setForce() const
|
|||||||
}
|
}
|
||||||
scalarField_.ref() = gSum(scalarField_);
|
scalarField_.ref() = gSum(scalarField_);
|
||||||
scalarField2_.ref() = gSum(scalarField2_);
|
scalarField2_.ref() = gSum(scalarField2_);
|
||||||
|
reduce(minFieldVal, minOp<scalar>());
|
||||||
|
reduce(maxFieldVal, maxOp<scalar>());
|
||||||
|
|
||||||
if(verbose_)
|
if(verbose_)
|
||||||
{
|
{
|
||||||
@ -147,8 +162,20 @@ void particleCellVolume::setForce() const
|
|||||||
<< ", and > " << lowerThreshold_
|
<< ", and > " << lowerThreshold_
|
||||||
<< ",\n the total volume of cells holding particles = " << scalarField2_[0]
|
<< ",\n the total volume of cells holding particles = " << scalarField2_[0]
|
||||||
<< ",\n this results in an average volume fraction of:" << scalarField_[0]/(scalarField2_[0]+SMALL)
|
<< ",\n this results in an average volume fraction of:" << scalarField_[0]/(scalarField2_[0]+SMALL)
|
||||||
|
<< ",\n the min occurring " << scalarFieldName_ << " is:" << minFieldVal
|
||||||
|
<< ",\n the max occurring " << scalarFieldName_ << " is:" << maxFieldVal
|
||||||
<< endl;
|
<< endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(writeToFile_)
|
||||||
|
{
|
||||||
|
filePtr_() << mesh_.time().value() << " "
|
||||||
|
<< scalarField_[0] << " "
|
||||||
|
<< scalarField2_[0] << " "
|
||||||
|
<< scalarField_[0]/(scalarField2_[0]+SMALL) << " "
|
||||||
|
<< minFieldVal << " "
|
||||||
|
<< maxFieldVal << endl;
|
||||||
|
}
|
||||||
}// end if time >= startTime_
|
}// end if time >= startTime_
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -74,6 +74,10 @@ private:
|
|||||||
|
|
||||||
const Switch verbose_;
|
const Switch verbose_;
|
||||||
|
|
||||||
|
const Switch writeToFile_;
|
||||||
|
|
||||||
|
mutable autoPtr<OFstream> filePtr_;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
//- Runtime type information
|
//- Runtime type information
|
||||||
|
|||||||
@ -69,7 +69,9 @@ volWeightedAverage::volWeightedAverage
|
|||||||
vectorFieldNames_(propsDict_.lookup("vectorFieldNames")),
|
vectorFieldNames_(propsDict_.lookup("vectorFieldNames")),
|
||||||
upperThreshold_(readScalar(propsDict_.lookup("upperThreshold"))),
|
upperThreshold_(readScalar(propsDict_.lookup("upperThreshold"))),
|
||||||
lowerThreshold_(readScalar(propsDict_.lookup("lowerThreshold"))),
|
lowerThreshold_(readScalar(propsDict_.lookup("lowerThreshold"))),
|
||||||
verbose_(propsDict_.found("verbose"))
|
verbose_(propsDict_.found("verbose")),
|
||||||
|
writeToFile_(propsDict_.lookupOrDefault<Switch>("writeToFile", false)),
|
||||||
|
filePtr_()
|
||||||
{
|
{
|
||||||
// create vol weighted average scalar fields
|
// create vol weighted average scalar fields
|
||||||
scalarFields_.setSize(scalarFieldNames_.size());
|
scalarFields_.setSize(scalarFieldNames_.size());
|
||||||
@ -124,6 +126,13 @@ volWeightedAverage::volWeightedAverage
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// create the path and output file
|
||||||
|
if(writeToFile_)
|
||||||
|
{
|
||||||
|
fileName path(particleCloud_.IOM().createTimeDir("postProcessing/volWeightedAverage"));
|
||||||
|
filePtr_.set(new OFstream(path/"volWeightedAverage.txt"));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -141,6 +150,8 @@ void volWeightedAverage::setForce() const
|
|||||||
{
|
{
|
||||||
if(verbose_) Info << "volWeightedAverage.C - setForce()" << endl;
|
if(verbose_) Info << "volWeightedAverage.C - setForce()" << endl;
|
||||||
|
|
||||||
|
if(writeToFile_) filePtr_() << mesh_.time().value() << " ";
|
||||||
|
|
||||||
for (int i=0;i < scalarFieldNames_.size(); i++)
|
for (int i=0;i < scalarFieldNames_.size(); i++)
|
||||||
{
|
{
|
||||||
// get reference to actual field
|
// get reference to actual field
|
||||||
@ -171,7 +182,7 @@ void volWeightedAverage::setForce() const
|
|||||||
MPI_Allreduce(&totVol, &totVol_all, 3, MPI_DOUBLE, MPI_SUM, MPI_COMM_WORLD);
|
MPI_Allreduce(&totVol, &totVol_all, 3, MPI_DOUBLE, MPI_SUM, MPI_COMM_WORLD);
|
||||||
integralValue = gSum(scalarFields_[i]);
|
integralValue = gSum(scalarFields_[i]);
|
||||||
volWeightedAverage = integralValue / (totVol_all+SMALL);
|
volWeightedAverage = integralValue / (totVol_all+SMALL);
|
||||||
scalarFields_[i].ref() = volWeightedAverage;
|
scalarFields_[i].primitiveFieldRef() = volWeightedAverage;
|
||||||
|
|
||||||
if(verbose_)
|
if(verbose_)
|
||||||
{
|
{
|
||||||
@ -184,6 +195,8 @@ void volWeightedAverage::setForce() const
|
|||||||
<< ",\n considering cells where the field < " << upperThreshold_
|
<< ",\n considering cells where the field < " << upperThreshold_
|
||||||
<< ", and > " << lowerThreshold_ << endl;
|
<< ", and > " << lowerThreshold_ << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(writeToFile_) filePtr_() << volWeightedAverage << " ";
|
||||||
}
|
}
|
||||||
|
|
||||||
for (int i=0;i < vectorFieldNames_.size(); i++)
|
for (int i=0;i < vectorFieldNames_.size(); i++)
|
||||||
@ -225,7 +238,11 @@ void volWeightedAverage::setForce() const
|
|||||||
<< ",\n considering cells where the mag(field) < " << upperThreshold_
|
<< ",\n considering cells where the mag(field) < " << upperThreshold_
|
||||||
<< ", and > " << lowerThreshold_ << endl;
|
<< ", and > " << lowerThreshold_ << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(writeToFile_) filePtr_() << volWeightedAverage << " ";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(writeToFile_) filePtr_() << endl;
|
||||||
}// end if time >= startTime_
|
}// end if time >= startTime_
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -76,6 +76,10 @@ private:
|
|||||||
|
|
||||||
const Switch verbose_;
|
const Switch verbose_;
|
||||||
|
|
||||||
|
const Switch writeToFile_;
|
||||||
|
|
||||||
|
mutable autoPtr<OFstream> filePtr_;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
//- Runtime type information
|
//- Runtime type information
|
||||||
|
|||||||
@ -261,9 +261,9 @@ void trilinearVoidFraction::setvoidFraction(double** const& mask,double**& voidf
|
|||||||
// find x,y,z
|
// find x,y,z
|
||||||
// TODO changes needed here when generalized for quader cells
|
// TODO changes needed here when generalized for quader cells
|
||||||
offsetOrigin = particleCloud_.mesh().C()[i000] - (partPos + posShift);
|
offsetOrigin = particleCloud_.mesh().C()[i000] - (partPos + posShift);
|
||||||
x = mag(offsetOrigin[0]) / cellLength_;
|
x = std::min(1.0, mag(offsetOrigin[0]) / cellLength_);
|
||||||
y = mag(offsetOrigin[1]) / cellLength_;
|
y = std::min(1.0, mag(offsetOrigin[1]) / cellLength_);
|
||||||
z = mag(offsetOrigin[2]) / cellLength_;
|
z = std::min(1.0, mag(offsetOrigin[2]) / cellLength_);
|
||||||
|
|
||||||
// calculate the mapping coeffs
|
// calculate the mapping coeffs
|
||||||
C000 = (1 - x) * (1 - y) * (1 - z);
|
C000 = (1 - x) * (1 - y) * (1 - z);
|
||||||
@ -350,12 +350,6 @@ void trilinearVoidFraction::setvoidFraction(double** const& mask,double**& voidf
|
|||||||
alphaLimited = true;
|
alphaLimited = true;
|
||||||
}
|
}
|
||||||
if(index==0 && alphaLimited) Info<<"alpha limited to" <<alphaMin_<<endl;*/
|
if(index==0 && alphaLimited) Info<<"alpha limited to" <<alphaMin_<<endl;*/
|
||||||
|
|
||||||
// store voidFraction for each particle
|
|
||||||
voidfractions[index][0] = voidfractionNext_[cellI];
|
|
||||||
|
|
||||||
// store cellweight for each particle - this should not live here
|
|
||||||
particleWeights[index][0] = 1.;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
voidfractionNext_.correctBoundaryConditions();
|
voidfractionNext_.correctBoundaryConditions();
|
||||||
@ -363,23 +357,18 @@ void trilinearVoidFraction::setvoidFraction(double** const& mask,double**& voidf
|
|||||||
// bring voidfraction from Eulerian Field to particle array
|
// bring voidfraction from Eulerian Field to particle array
|
||||||
for (int index = 0; index < particleCloud_.numberOfParticles(); ++index)
|
for (int index = 0; index < particleCloud_.numberOfParticles(); ++index)
|
||||||
{
|
{
|
||||||
label cellID = particleCloud_.cellIDs()[index][0];
|
for (int subcell = 0; subcell < maxCellsPerParticle_; ++subcell)
|
||||||
|
{
|
||||||
|
label cellID = particleCloud_.cellIDs()[index][subcell];
|
||||||
|
|
||||||
if (cellID >= 0)
|
if (cellID >= 0)
|
||||||
{
|
{
|
||||||
voidfractions[index][0] = voidfractionNext_[i000];
|
voidfractions[index][subcell] = voidfractionNext_[cellID];
|
||||||
voidfractions[index][1] = voidfractionNext_[i100];
|
|
||||||
voidfractions[index][2] = voidfractionNext_[i110];
|
|
||||||
voidfractions[index][3] = voidfractionNext_[i010];
|
|
||||||
voidfractions[index][4] = voidfractionNext_[i001];
|
|
||||||
voidfractions[index][5] = voidfractionNext_[i101];
|
|
||||||
voidfractions[index][6] = voidfractionNext_[i111];
|
|
||||||
voidfractions[index][7] = voidfractionNext_[i011];
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
for (int i = 0; i < 8; ++i)
|
voidfractions[index][subcell] = -1.;
|
||||||
voidfractions[index][i] = -1.;
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -0,0 +1,122 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: 1.4 |
|
||||||
|
| \\ / A nd | Web: http://www.openfoam.org |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
|
||||||
|
root "";
|
||||||
|
case "";
|
||||||
|
instance "";
|
||||||
|
local "";
|
||||||
|
|
||||||
|
class dictionary;
|
||||||
|
object couplingProperties;
|
||||||
|
}
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
//===========================================================================//
|
||||||
|
// sub-models & settings
|
||||||
|
|
||||||
|
syncMode false;
|
||||||
|
|
||||||
|
modelType "A";
|
||||||
|
|
||||||
|
couplingInterval 100;
|
||||||
|
|
||||||
|
voidFractionModel divided;
|
||||||
|
|
||||||
|
locateModel engineSearchMany2Many;
|
||||||
|
|
||||||
|
meshMotionModel noMeshMotion;
|
||||||
|
|
||||||
|
regionModel allRegion;
|
||||||
|
|
||||||
|
IOModel basicIO;
|
||||||
|
|
||||||
|
probeModel off;
|
||||||
|
|
||||||
|
dataExchangeModel twoWayOne2One;
|
||||||
|
|
||||||
|
averagingModel dense;
|
||||||
|
|
||||||
|
clockModel standardClock;
|
||||||
|
|
||||||
|
smoothingModel off;
|
||||||
|
|
||||||
|
forceModels
|
||||||
|
(
|
||||||
|
gradPForce
|
||||||
|
viscForce
|
||||||
|
KochHillDrag
|
||||||
|
);
|
||||||
|
|
||||||
|
momCoupleModels
|
||||||
|
(
|
||||||
|
implicitCouple
|
||||||
|
);
|
||||||
|
|
||||||
|
turbulenceModelType "turbulenceProperties";
|
||||||
|
|
||||||
|
//===========================================================================//
|
||||||
|
// sub-model properties
|
||||||
|
|
||||||
|
dividedProps
|
||||||
|
{
|
||||||
|
alphaMin 0.01;
|
||||||
|
scaleUpVol 1.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
engineSearchMany2ManyProps
|
||||||
|
{
|
||||||
|
engineProps
|
||||||
|
{
|
||||||
|
treeSearch true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
twoWayOne2OneProps
|
||||||
|
{
|
||||||
|
liggghtsPath "../DEM/in.liggghts_run";
|
||||||
|
verbose true;
|
||||||
|
}
|
||||||
|
|
||||||
|
gradPForceProps
|
||||||
|
{
|
||||||
|
pFieldName "p";
|
||||||
|
voidfractionFieldName "voidfraction";
|
||||||
|
velocityFieldName "U";
|
||||||
|
interpolation true;
|
||||||
|
}
|
||||||
|
|
||||||
|
viscForceProps
|
||||||
|
{
|
||||||
|
velocityFieldName "U";
|
||||||
|
interpolation true;
|
||||||
|
}
|
||||||
|
|
||||||
|
KochHillDragProps
|
||||||
|
{
|
||||||
|
verbose true;
|
||||||
|
velFieldName "U";
|
||||||
|
voidfractionFieldName "voidfraction";
|
||||||
|
interpolation true;
|
||||||
|
implForceDEM true;
|
||||||
|
}
|
||||||
|
|
||||||
|
implicitCoupleProps
|
||||||
|
{
|
||||||
|
velFieldName "U";
|
||||||
|
granVelFieldName "Us";
|
||||||
|
voidfractionFieldName "voidfraction";
|
||||||
|
}
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -0,0 +1,67 @@
|
|||||||
|
# Pour granular particles into a cylinder, then induce flow
|
||||||
|
log ../DEM/log.liggghts
|
||||||
|
thermo_log ../DEM/post/thermo.txt
|
||||||
|
|
||||||
|
atom_style granular
|
||||||
|
atom_modify map array
|
||||||
|
communicate single vel yes
|
||||||
|
|
||||||
|
boundary m m m
|
||||||
|
newton off
|
||||||
|
|
||||||
|
units si
|
||||||
|
processors 2 2 1
|
||||||
|
|
||||||
|
# read the restart file
|
||||||
|
read_restart ../DEM/post/restart/liggghts.restart
|
||||||
|
|
||||||
|
neighbor 0.0005 bin
|
||||||
|
neigh_modify delay 0
|
||||||
|
|
||||||
|
# Material properties required for granular pair styles
|
||||||
|
|
||||||
|
fix m1 all property/global youngsModulus peratomtype 5.e6
|
||||||
|
fix m2 all property/global poissonsRatio peratomtype 0.45
|
||||||
|
fix m3 all property/global coefficientRestitution peratomtypepair 1 0.3
|
||||||
|
fix m4 all property/global coefficientFriction peratomtypepair 1 0.5
|
||||||
|
|
||||||
|
# pair style
|
||||||
|
pair_style gran model hertz tangential history
|
||||||
|
pair_coeff * *
|
||||||
|
|
||||||
|
# timestep, gravity
|
||||||
|
timestep 0.00001
|
||||||
|
fix gravi all gravity 9.81 vector 0.0 0.0 -1.0
|
||||||
|
|
||||||
|
# walls
|
||||||
|
fix zwalls1 all wall/gran model hertz tangential history primitive type 1 zplane 0.0
|
||||||
|
fix zwalls2 all wall/gran model hertz tangential history primitive type 1 zplane 0.0553
|
||||||
|
fix cylwalls all wall/gran model hertz tangential history primitive type 1 zcylinder 0.01385 0. 0.
|
||||||
|
|
||||||
|
# change the particles density
|
||||||
|
set group all density 2000
|
||||||
|
|
||||||
|
# cfd coupling
|
||||||
|
fix cfd all couple/cfd couple_every 100 one2one
|
||||||
|
fix cfd2 all couple/cfd/force/implicit
|
||||||
|
#fix cfd2 all couple/cfd/force/implicit/accumulated #CrankNicolson 0.5
|
||||||
|
|
||||||
|
# apply nve integration to all particles that are inserted as single particles
|
||||||
|
fix integr all nve/sphere
|
||||||
|
|
||||||
|
# center of mass
|
||||||
|
compute centerOfMass all com
|
||||||
|
|
||||||
|
# compute total dragforce
|
||||||
|
compute dragtotal all reduce sum f_dragforce[1] f_dragforce[2] f_dragforce[3]
|
||||||
|
|
||||||
|
# screen output
|
||||||
|
compute rke all erotate/sphere
|
||||||
|
thermo_style custom step atoms ke c_rke vol c_centerOfMass[3] c_dragtotal[1] c_dragtotal[2] c_dragtotal[3]
|
||||||
|
thermo 10
|
||||||
|
thermo_modify lost ignore norm no
|
||||||
|
compute_modify thermo_temp dynamic yes
|
||||||
|
|
||||||
|
dump dmp all custom 5000 ../DEM/post/dump*.liggghts_run id type x y z vx vy vz fx fy fz f_dragforce[1] f_dragforce[2] f_dragforce[3] radius
|
||||||
|
|
||||||
|
run 1
|
||||||
16
tutorials/cfdemSolverPiso/ErgunTestMPI/prerun_one2one.sh
Executable file
16
tutorials/cfdemSolverPiso/ErgunTestMPI/prerun_one2one.sh
Executable file
@ -0,0 +1,16 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
cp ./CFD/constant/couplingProperties.one2one ./CFD/constant/couplingProperties
|
||||||
|
cp ./DEM/in.liggghts_run.one2one ./DEM/in.liggghts_run
|
||||||
|
|
||||||
|
#- define variables
|
||||||
|
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||||
|
|
||||||
|
# check if mesh was built
|
||||||
|
if [ -f "$casePath/CFD/constant/polyMesh/boundary" ]; then
|
||||||
|
echo "mesh was built before - using old mesh"
|
||||||
|
else
|
||||||
|
echo "mesh needs to be built"
|
||||||
|
cd $casePath/CFD
|
||||||
|
blockMesh
|
||||||
|
fi
|
||||||
@ -14,6 +14,15 @@
|
|||||||
"nprocs" : 4,
|
"nprocs" : 4,
|
||||||
"pre_scripts" : ["prerun.sh"],
|
"pre_scripts" : ["prerun.sh"],
|
||||||
"post_scripts" : ["postrun.sh"]
|
"post_scripts" : ["postrun.sh"]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name" : "cfdemrun-one2one",
|
||||||
|
"depends_on" : "liggghts-init",
|
||||||
|
"solver" : "cfdemSolverPiso",
|
||||||
|
"type" : "CFDEMcoupling/mpi",
|
||||||
|
"nprocs" : 4,
|
||||||
|
"pre_scripts" : ["prerun_one2one.sh"],
|
||||||
|
"post_scripts" : ["postrun.sh"]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
22
tutorials/cfdemSolverPiso/voidfractionTest/Allrun.sh
Executable file
22
tutorials/cfdemSolverPiso/voidfractionTest/Allrun.sh
Executable file
@ -0,0 +1,22 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#===================================================================#
|
||||||
|
# allrun script for testcase as part of test routine
|
||||||
|
# run voidfractionTest
|
||||||
|
# Christoph Goniva - Jan. 2016
|
||||||
|
#===================================================================#
|
||||||
|
|
||||||
|
#- define variables
|
||||||
|
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||||
|
|
||||||
|
# check if mesh was built
|
||||||
|
if [ -f "$casePath/CFD/constant/polyMesh/points" ]; then
|
||||||
|
echo "mesh was built before - using old mesh"
|
||||||
|
else
|
||||||
|
echo "mesh needs to be built"
|
||||||
|
cd $casePath/CFD
|
||||||
|
blockMesh
|
||||||
|
fi
|
||||||
|
|
||||||
|
#- run parallel CFD-DEM
|
||||||
|
. $casePath/parCFDDEMrun.sh
|
||||||
32
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/Ksl
Normal file
32
tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/Ksl
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: 1.6 |
|
||||||
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class volScalarField;
|
||||||
|
location "0";
|
||||||
|
object Ksl;
|
||||||
|
}
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
dimensions [1 -3 -1 0 0 0 0];
|
||||||
|
|
||||||
|
internalField uniform 0;
|
||||||
|
|
||||||
|
boundaryField
|
||||||
|
{
|
||||||
|
"(inlet|outlet|walls)"
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
22
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/UsRec → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/U
Executable file → Normal file
22
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/UsRec → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/U
Executable file → Normal file
@ -11,7 +11,7 @@ FoamFile
|
|||||||
format ascii;
|
format ascii;
|
||||||
class volVectorField;
|
class volVectorField;
|
||||||
location "0";
|
location "0";
|
||||||
object Us;
|
object U;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
@ -21,24 +21,20 @@ internalField uniform (0 0 0);
|
|||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
walls
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
nozzle
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type fixedValue;
|
||||||
|
value uniform (0 0 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet
|
outlet
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
|
value uniform (0 0 0);
|
||||||
|
}
|
||||||
|
walls
|
||||||
|
{
|
||||||
|
type fixedValue;
|
||||||
|
value uniform (0 0 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
18
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/Us → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/Us
Executable file → Normal file
18
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/Us → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/Us
Executable file → Normal file
@ -21,24 +21,10 @@ internalField uniform (0 0 0);
|
|||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
walls
|
"(inlet|outlet|walls)"
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
nozzle
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
inlet
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
|
|
||||||
outlet
|
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
|
value uniform (0 0 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
21
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/addSource → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/p
Executable file → Normal file
21
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/addSource → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/p
Executable file → Normal file
@ -2,7 +2,7 @@
|
|||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 1.6 |
|
| \\ / O peration | Version: 1.6 |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
@ -10,11 +10,11 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
object addSource;
|
object p;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
dimensions [1 -1 -3 0 0 0 0];
|
dimensions [0 2 -2 0 0 0 0];
|
||||||
|
|
||||||
internalField uniform 0;
|
internalField uniform 0;
|
||||||
|
|
||||||
@ -25,7 +25,6 @@ boundaryField
|
|||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
value uniform 0;
|
value uniform 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
@ -33,15 +32,15 @@ boundaryField
|
|||||||
}
|
}
|
||||||
outlet
|
outlet
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type totalPressure;
|
||||||
value uniform 0;
|
p0 uniform 0;
|
||||||
}
|
U U;
|
||||||
nozzle
|
phi phi;
|
||||||
{
|
rho rho;
|
||||||
type zeroGradient;
|
psi none;
|
||||||
|
gamma 1;
|
||||||
value uniform 0;
|
value uniform 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
23
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/rho → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/rho
Executable file → Normal file
23
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/rho → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/rho
Executable file → Normal file
@ -10,35 +10,20 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
object rho;
|
object p;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
dimensions [1 -3 0 0 0 0 0];
|
dimensions [1 -3 0 0 0 0 0];
|
||||||
|
|
||||||
internalField uniform 1.1885;
|
internalField uniform 10;
|
||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
walls
|
"(inlet|outlet|walls)"
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
nozzle
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
inlet
|
|
||||||
{
|
|
||||||
type fixedValue;
|
|
||||||
value uniform 1.1885;
|
|
||||||
}
|
|
||||||
|
|
||||||
outlet
|
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
|
value uniform 10;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
25
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/rhoRec → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/voidfraction
Executable file → Normal file
25
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/rhoRec → tutorials/cfdemSolverPiso/voidfractionTest/CFD/0/voidfraction
Executable file → Normal file
@ -10,35 +10,20 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
object rho;
|
object voidfraction;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
dimensions [1 -3 0 0 0 0 0];
|
dimensions [0 0 0 0 0 0 0];
|
||||||
|
|
||||||
internalField uniform 1.1885;
|
internalField uniform 1;
|
||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
walls
|
"(inlet|outlet|walls)"
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
nozzle
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
inlet
|
|
||||||
{
|
|
||||||
type fixedValue;
|
|
||||||
value uniform 1.1885;
|
|
||||||
}
|
|
||||||
|
|
||||||
outlet
|
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
|
value uniform 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
137
tutorials/cfdemSolverPiso/voidfractionTest/CFD/constant/couplingProperties
Executable file
137
tutorials/cfdemSolverPiso/voidfractionTest/CFD/constant/couplingProperties
Executable file
@ -0,0 +1,137 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: 1.4 |
|
||||||
|
| \\ / A nd | Web: http://www.openfoam.org |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
|
||||||
|
root "";
|
||||||
|
case "";
|
||||||
|
instance "";
|
||||||
|
local "";
|
||||||
|
|
||||||
|
class dictionary;
|
||||||
|
object couplingProperties;
|
||||||
|
}
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
//===========================================================================//
|
||||||
|
// sub-models & settings
|
||||||
|
|
||||||
|
solveFlow off;
|
||||||
|
|
||||||
|
useDDTvoidfraction;
|
||||||
|
|
||||||
|
modelType B;
|
||||||
|
|
||||||
|
couplingInterval 100;
|
||||||
|
|
||||||
|
voidFractionModel trilinear;
|
||||||
|
|
||||||
|
locateModel engine;
|
||||||
|
|
||||||
|
meshMotionModel noMeshMotion;
|
||||||
|
|
||||||
|
IOModel basicIO;
|
||||||
|
|
||||||
|
probeModel off;
|
||||||
|
|
||||||
|
dataExchangeModel twoWayMPI;
|
||||||
|
|
||||||
|
averagingModel dense;
|
||||||
|
|
||||||
|
clockModel off;
|
||||||
|
|
||||||
|
smoothingModel off;
|
||||||
|
|
||||||
|
forceModels
|
||||||
|
(
|
||||||
|
DiFeliceDrag
|
||||||
|
Archimedes
|
||||||
|
noDrag
|
||||||
|
particleCellVolume
|
||||||
|
volWeightedAverage
|
||||||
|
);
|
||||||
|
|
||||||
|
momCoupleModels
|
||||||
|
(
|
||||||
|
implicitCouple
|
||||||
|
);
|
||||||
|
|
||||||
|
turbulenceModelType "turbulenceProperties";
|
||||||
|
|
||||||
|
//===========================================================================//
|
||||||
|
// sub-model properties
|
||||||
|
|
||||||
|
noDragProps
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
particleCellVolumeProps
|
||||||
|
{
|
||||||
|
upperThreshold 1e20;
|
||||||
|
lowerThreshold 0.;
|
||||||
|
verbose true;
|
||||||
|
writeToFile true;
|
||||||
|
}
|
||||||
|
|
||||||
|
volWeightedAverageProps
|
||||||
|
{
|
||||||
|
scalarFieldNames
|
||||||
|
(
|
||||||
|
ddtVoidfraction
|
||||||
|
);
|
||||||
|
vectorFieldNames
|
||||||
|
(
|
||||||
|
);
|
||||||
|
upperThreshold 1e20;
|
||||||
|
lowerThreshold 0;
|
||||||
|
writeToFile true;
|
||||||
|
verbose true;
|
||||||
|
}
|
||||||
|
|
||||||
|
implicitCoupleProps
|
||||||
|
{
|
||||||
|
velFieldName "U";
|
||||||
|
granVelFieldName "Us";
|
||||||
|
voidfractionFieldName "voidfraction";
|
||||||
|
}
|
||||||
|
|
||||||
|
DiFeliceDragProps
|
||||||
|
{
|
||||||
|
velFieldName "U";
|
||||||
|
voidfractionFieldName "voidfraction";
|
||||||
|
granVelFieldName "Us";
|
||||||
|
verbose false;
|
||||||
|
}
|
||||||
|
|
||||||
|
ArchimedesProps
|
||||||
|
{
|
||||||
|
densityFieldName "rho";
|
||||||
|
gravityFieldName "g";
|
||||||
|
}
|
||||||
|
|
||||||
|
twoWayMPIProps
|
||||||
|
{
|
||||||
|
liggghtsPath "../DEM/in.liggghts_run";
|
||||||
|
}
|
||||||
|
|
||||||
|
trilinearProps
|
||||||
|
{
|
||||||
|
alphaMin 0.3; // unused!
|
||||||
|
}
|
||||||
|
|
||||||
|
engineProps
|
||||||
|
{
|
||||||
|
treeSearch true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
2
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/constant/g → tutorials/cfdemSolverPiso/voidfractionTest/CFD/constant/g
Executable file → Normal file
2
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/constant/g → tutorials/cfdemSolverPiso/voidfractionTest/CFD/constant/g
Executable file → Normal file
@ -16,7 +16,7 @@ FoamFile
|
|||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
dimensions [0 1 -2 0 0 0 0];
|
dimensions [0 1 -2 0 0 0 0];
|
||||||
value ( 0 0 -9.81 );
|
value ( 0 -9.81 0);
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
@ -26,17 +26,7 @@ FoamFile
|
|||||||
liggghtsCommandModels
|
liggghtsCommandModels
|
||||||
(
|
(
|
||||||
runLiggghts
|
runLiggghts
|
||||||
writeLiggghts
|
|
||||||
);
|
);
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
|
|
||||||
/*runLiggghtsProps
|
|
||||||
{
|
|
||||||
preNo false;
|
|
||||||
}
|
|
||||||
|
|
||||||
writeLiggghtsProps
|
|
||||||
{
|
|
||||||
writeLast off;
|
|
||||||
overwrite off;
|
|
||||||
}*/
|
|
||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 2.3.0 |
|
| \\ / O peration | Version: 1.6 |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -14,14 +14,25 @@ FoamFile
|
|||||||
object transportProperties;
|
object transportProperties;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
transportModel Newtonian;
|
transportModel Newtonian;
|
||||||
|
|
||||||
nu nu [ 0 2 -1 0 0 0 0 ] 1.6e-05;
|
nu nu [ 0 2 -1 0 0 0 0 ] 1e-05;
|
||||||
|
|
||||||
kf kf [ 1 1 -3 -1 0 0 0 ] 0.026;
|
CrossPowerLawCoeffs
|
||||||
|
{
|
||||||
|
nu0 nu0 [ 0 2 -1 0 0 0 0 ] 1e-06;
|
||||||
|
nuInf nuInf [ 0 2 -1 0 0 0 0 ] 1e-06;
|
||||||
|
m m [ 0 0 1 0 0 0 0 ] 1;
|
||||||
|
n n [ 0 0 0 0 0 0 0 ] 1;
|
||||||
|
}
|
||||||
|
|
||||||
Cp Cp [ 0 2 -2 -1 0 0 0 ] 1005;
|
BirdCarreauCoeffs
|
||||||
|
{
|
||||||
Cv Cv [ 0 2 -2 -1 0 0 0 ] 718;
|
nu0 nu0 [ 0 2 -1 0 0 0 0 ] 1e-06;
|
||||||
|
nuInf nuInf [ 0 2 -1 0 0 0 0 ] 1e-06;
|
||||||
|
k k [ 0 0 1 0 0 0 0 ] 0;
|
||||||
|
n n [ 0 0 0 0 0 0 0 ] 1;
|
||||||
|
}
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 2.3.0 |
|
| \\ / O peration | Version: 1.6 |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -0,0 +1,59 @@
|
|||||||
|
%test
|
||||||
|
close all;
|
||||||
|
clear;
|
||||||
|
clc;
|
||||||
|
|
||||||
|
%====================================%
|
||||||
|
% simulation data
|
||||||
|
%====================================%
|
||||||
|
path = '../postProcessing/particleCellVolume/0/particleCellVolume.txt';
|
||||||
|
data = load(path);
|
||||||
|
Vp_sim = data(:,2);
|
||||||
|
t_sim = data(:,1);
|
||||||
|
|
||||||
|
path = '../postProcessing/volWeightedAverage/0/volWeightedAverage.txt';
|
||||||
|
data = load(path);
|
||||||
|
volAvDdtVoidFraction_sim = data(:,2);
|
||||||
|
t_sim = data(:,1);
|
||||||
|
|
||||||
|
%====================================%
|
||||||
|
dp=2*0.0015;
|
||||||
|
vp=0.3
|
||||||
|
deltaT=0.001 % coupling time
|
||||||
|
%====================================%
|
||||||
|
% analytical calculation
|
||||||
|
%====================================%
|
||||||
|
Vp=dp*dp*dp*pi/6;
|
||||||
|
np=1000;
|
||||||
|
Vptot=np*Vp
|
||||||
|
|
||||||
|
kernelSize=8
|
||||||
|
Vc=(0.1/10)^3*kernelSize
|
||||||
|
Vp=dp^3*pi/6
|
||||||
|
deltaVpdt=Vp*(deltaT*vp)/dp
|
||||||
|
avg_ddt_voidfraction=deltaVpdt/(Vc*deltaT)
|
||||||
|
|
||||||
|
%====================================%
|
||||||
|
% plot data
|
||||||
|
%====================================%
|
||||||
|
figure(1)
|
||||||
|
plot(t_sim,(Vp_sim./Vptot)*100,'r-')
|
||||||
|
hold on;
|
||||||
|
%legend("error")
|
||||||
|
title("particle volume represented in cells");
|
||||||
|
grid on;
|
||||||
|
xlabel("time in s");
|
||||||
|
ylabel("particle cell volume / particle volume in %");
|
||||||
|
print('-dpng','-r450', 'particleCellVolume')
|
||||||
|
|
||||||
|
figure(2)
|
||||||
|
plot(t_sim,volAvDdtVoidFraction_sim,'r-',[min(t_sim),max(t_sim)],[avg_ddt_voidfraction,avg_ddt_voidfraction],'b-')
|
||||||
|
grid on;
|
||||||
|
%axis([0,max(t_sim),0,100])
|
||||||
|
hold on;
|
||||||
|
legend("simulation",'analytic')
|
||||||
|
title("average ddt(voidfraction)");
|
||||||
|
grid on;
|
||||||
|
xlabel("time in s");
|
||||||
|
ylabel("average ddt(voidfraction)");
|
||||||
|
print('-dpng','-r450', 'averageDDTvoidfraction')
|
||||||
73
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/thDiff → tutorials/cfdemSolverPiso/voidfractionTest/CFD/system/blockMeshDict
Executable file → Normal file
73
tutorials/rcfdemSolverHeattransfer/fluidizedBed/CFD/0/thDiff → tutorials/cfdemSolverPiso/voidfractionTest/CFD/system/blockMeshDict
Executable file → Normal file
@ -9,44 +9,55 @@ FoamFile
|
|||||||
{
|
{
|
||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class dictionary;
|
||||||
object thDiff;
|
object blockMeshDict;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
dimensions [0 2 -1 0 0 0 0];
|
convertToMeters 1;
|
||||||
|
|
||||||
internalField uniform 0.0;
|
vertices
|
||||||
|
(
|
||||||
|
(0.0 0 0.0)
|
||||||
|
(0.1 0 0.0)
|
||||||
|
(0.1 0.1 0.0)
|
||||||
|
(0.0 0.1 0.0)
|
||||||
|
(0.0 0 1.0)
|
||||||
|
(0.1 0 1.0)
|
||||||
|
(0.1 0.1 1.0)
|
||||||
|
(0.0 0.1 1.0)
|
||||||
|
);
|
||||||
|
|
||||||
boundaryField
|
blocks
|
||||||
{
|
(
|
||||||
walls
|
hex (0 1 2 3 4 5 6 7) (10 10 100) simpleGrading (1 1 1)
|
||||||
{
|
);
|
||||||
type fixedValue;
|
|
||||||
// value uniform 2.9703e-05;
|
|
||||||
value uniform 6e-05;
|
|
||||||
}
|
|
||||||
nozzle
|
|
||||||
{
|
|
||||||
type fixedValue;
|
|
||||||
// value uniform 2.9703e-05;
|
|
||||||
value uniform 6e-05;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
edges
|
||||||
|
(
|
||||||
|
);
|
||||||
|
|
||||||
inlet
|
patches
|
||||||
{
|
(
|
||||||
type fixedValue;
|
patch inlet
|
||||||
value uniform 2.9703e-05;
|
(
|
||||||
}
|
(3 7 6 2)
|
||||||
|
)
|
||||||
|
patch outlet
|
||||||
|
(
|
||||||
|
(1 5 4 0)
|
||||||
|
)
|
||||||
|
wall walls
|
||||||
|
(
|
||||||
|
(0 4 7 3)
|
||||||
|
(2 6 5 1)
|
||||||
|
(0 3 2 1)
|
||||||
|
(4 5 6 7)
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
outlet
|
mergePatchPairs
|
||||||
{
|
(
|
||||||
type fixedValue;
|
);
|
||||||
value uniform 2.9703e-05;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
|
|
||||||
|
|
||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 2.3.0 |
|
| \\ / O peration | Version: 1.6 |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -15,7 +15,7 @@ FoamFile
|
|||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
application pisoFoam;
|
application cfdemSolverPiso;
|
||||||
|
|
||||||
startFrom startTime;
|
startFrom startTime;
|
||||||
|
|
||||||
@ -23,13 +23,13 @@ startTime 0;
|
|||||||
|
|
||||||
stopAt endTime;
|
stopAt endTime;
|
||||||
|
|
||||||
endTime 10.0;
|
endTime 0.2;
|
||||||
|
|
||||||
deltaT 0.00025;
|
deltaT 0.001;
|
||||||
|
|
||||||
writeControl timeStep;
|
writeControl adjustableRunTime;
|
||||||
|
|
||||||
writeInterval 4000;
|
writeInterval 0.001;
|
||||||
|
|
||||||
purgeWrite 0;
|
purgeWrite 0;
|
||||||
|
|
||||||
@ -37,51 +37,40 @@ writeFormat ascii;
|
|||||||
|
|
||||||
writePrecision 6;
|
writePrecision 6;
|
||||||
|
|
||||||
writeCompression off;
|
writeCompression uncompressed;
|
||||||
|
|
||||||
timeFormat general;
|
timeFormat general;
|
||||||
|
|
||||||
timePrecision 6;
|
timePrecision 6;
|
||||||
|
|
||||||
runTimeModifiable true;
|
runTimeModifiable yes;
|
||||||
|
|
||||||
libs (
|
adjustTimeStep no;
|
||||||
// "libOpenFOAM.so"
|
|
||||||
// "libsimpleSwakFunctionObjects.so"
|
maxCo 1;
|
||||||
// "libswakFunctionObjects.so"
|
|
||||||
// "libgroovyBC.so"
|
maxDeltaT 1;
|
||||||
// "libgroovyStandardBCs.so"
|
|
||||||
);
|
|
||||||
|
|
||||||
functions
|
functions
|
||||||
{
|
{
|
||||||
|
probes
|
||||||
probes1
|
|
||||||
{
|
{
|
||||||
type probes;
|
type probes;
|
||||||
|
functionObjectLibs ( "libsampling.so" );
|
||||||
functionObjectLibs ("libsampling.so");
|
// directory for probe data
|
||||||
|
name probes;
|
||||||
#include "probesDict";
|
probeLocations
|
||||||
}
|
(
|
||||||
|
(0.05001 0.05001 0.5)
|
||||||
/* temperatureSum
|
|
||||||
{
|
|
||||||
type patchExpression;
|
|
||||||
outputControl timeStep;
|
|
||||||
outputInterval 40;
|
|
||||||
accumulations (
|
|
||||||
sum
|
|
||||||
);
|
);
|
||||||
patches (
|
|
||||||
outlet
|
// fields to be probed
|
||||||
);
|
fields ( volAverage_ddtVoidfraction voidfraction );
|
||||||
expression "phi*T";
|
|
||||||
verbose false;
|
// write at same frequency as fields
|
||||||
|
writeControl timeStep;//outputTime;
|
||||||
|
writeInterval 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
*/
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 2.3.0 |
|
| \\ / O peration | Version: 1.6 |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -15,49 +15,61 @@ FoamFile
|
|||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
application pisoFoam;
|
application cfdemSolverPiso;
|
||||||
|
|
||||||
startFrom startTime;
|
startFrom startTime;
|
||||||
|
|
||||||
startTime -5;
|
startTime 0;
|
||||||
|
|
||||||
stopAt endTime;
|
stopAt endTime;
|
||||||
|
|
||||||
endTime -0.005;
|
endTime 0.2;
|
||||||
|
|
||||||
deltaT 0.00005;
|
deltaT 0.001;
|
||||||
|
|
||||||
writeControl timeStep;
|
writeControl adjustableRunTime;
|
||||||
|
|
||||||
writeInterval 100;
|
writeInterval 0.001;
|
||||||
|
|
||||||
purgeWrite 2;
|
purgeWrite 0;
|
||||||
|
|
||||||
writeFormat ascii;
|
writeFormat ascii;
|
||||||
|
|
||||||
writePrecision 6;
|
writePrecision 6;
|
||||||
|
|
||||||
writeCompression off;
|
writeCompression uncompressed;
|
||||||
|
|
||||||
timeFormat general;
|
timeFormat general;
|
||||||
|
|
||||||
timePrecision 6;
|
timePrecision 6;
|
||||||
|
|
||||||
runTimeModifiable true;
|
runTimeModifiable yes;
|
||||||
|
|
||||||
libs (
|
adjustTimeStep no;
|
||||||
|
|
||||||
);
|
maxCo 1;
|
||||||
|
|
||||||
|
maxDeltaT 1;
|
||||||
|
|
||||||
functions
|
functions
|
||||||
{
|
{
|
||||||
probes1
|
probes
|
||||||
{
|
{
|
||||||
type probes;
|
type probes;
|
||||||
|
functionObjectLibs ( "libsampling.so" );
|
||||||
|
// directory for probe data
|
||||||
|
name probes;
|
||||||
|
probeLocations
|
||||||
|
(
|
||||||
|
(0.05001 0.05001 0.5)
|
||||||
|
);
|
||||||
|
|
||||||
functionObjectLibs ("libsampling.so");
|
// fields to be probed
|
||||||
|
fields ( volAverage_ddtVoidfraction voidfraction );
|
||||||
|
|
||||||
#include "probesDict";
|
// write at same frequency as fields
|
||||||
|
writeControl timeStep;//outputTime;
|
||||||
|
writeInterval 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 2.3.0 |
|
| \\ / O peration | Version: 1.6 |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -10,18 +10,24 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class dictionary;
|
class dictionary;
|
||||||
object mirrorMeshDict;
|
location "system";
|
||||||
|
object decomposeParDict;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
planeType pointAndNormal;
|
numberOfSubdomains 2;
|
||||||
|
|
||||||
pointAndNormalDict
|
method simple;
|
||||||
|
|
||||||
|
simpleCoeffs
|
||||||
{
|
{
|
||||||
basePoint (0 0 0);
|
n ( 1 1 2 );
|
||||||
normalVector (-1 0 0);
|
delta 0.001;
|
||||||
}
|
}
|
||||||
|
|
||||||
planeTolerance 1e-3;
|
distributed no;
|
||||||
|
|
||||||
|
roots ( );
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 2.3.0 |
|
| \\ / O peration | Version: 1.6 |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -23,6 +23,8 @@ ddtSchemes
|
|||||||
gradSchemes
|
gradSchemes
|
||||||
{
|
{
|
||||||
default Gauss linear;
|
default Gauss linear;
|
||||||
|
grad(p) Gauss linear;
|
||||||
|
grad(U) Gauss linear;
|
||||||
}
|
}
|
||||||
|
|
||||||
divSchemes
|
divSchemes
|
||||||
@ -34,14 +36,24 @@ divSchemes
|
|||||||
div(phi,R) Gauss limitedLinear 1;
|
div(phi,R) Gauss limitedLinear 1;
|
||||||
div(R) Gauss linear;
|
div(R) Gauss linear;
|
||||||
div(phi,nuTilda) Gauss limitedLinear 1;
|
div(phi,nuTilda) Gauss limitedLinear 1;
|
||||||
|
div((nuEff*dev(grad(U).T()))) Gauss linear;
|
||||||
div((nuEff*dev(T(grad(U))))) Gauss linear;
|
div((nuEff*dev(T(grad(U))))) Gauss linear;
|
||||||
div(phi,T) Gauss limitedLinear 1;
|
div((viscousTerm*dev(grad(U).T()))) Gauss linear;
|
||||||
// div(phi,T) Gauss upwind;
|
div((nu*dev(grad(U).T()))) Gauss linear;
|
||||||
}
|
}
|
||||||
|
|
||||||
laplacianSchemes
|
laplacianSchemes
|
||||||
{
|
{
|
||||||
default Gauss linear corrected;
|
default Gauss linear corrected;
|
||||||
|
laplacian(viscousTerm,U) Gauss linear corrected;
|
||||||
|
laplacian(nu,U) Gauss linear corrected;
|
||||||
|
laplacian(nuEff,U) Gauss linear corrected;
|
||||||
|
laplacian((1|A(U)),p) Gauss linear corrected;
|
||||||
|
laplacian((voidfraction2|A(U)),p) Gauss linear corrected;
|
||||||
|
laplacian(DkEff,k) Gauss linear corrected;
|
||||||
|
laplacian(DepsilonEff,epsilon) Gauss linear corrected;
|
||||||
|
laplacian(DREff,R) Gauss linear corrected;
|
||||||
|
laplacian(DnuTildaEff,nuTilda) Gauss linear corrected;
|
||||||
}
|
}
|
||||||
|
|
||||||
interpolationSchemes
|
interpolationSchemes
|
||||||
@ -58,7 +70,6 @@ fluxRequired
|
|||||||
{
|
{
|
||||||
default no;
|
default no;
|
||||||
p ;
|
p ;
|
||||||
T ;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 2.3.0 |
|
| \\ / O peration | Version: 1.6 |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -19,45 +19,40 @@ solvers
|
|||||||
{
|
{
|
||||||
p
|
p
|
||||||
{
|
{
|
||||||
solver GAMG;
|
solver PCG;
|
||||||
|
preconditioner DIC;
|
||||||
tolerance 1e-06;
|
tolerance 1e-06;
|
||||||
relTol 0.1;
|
relTol 0.1;
|
||||||
smoother GaussSeidel;
|
|
||||||
nPreSweeps 0;
|
|
||||||
nPostSweeps 2;
|
|
||||||
cacheAgglomeration on;
|
|
||||||
agglomerator faceAreaPair;
|
|
||||||
nCellsInCoarsestLevel 10;
|
|
||||||
mergeLevels 1;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pFinal
|
pFinal
|
||||||
{
|
{
|
||||||
$p;
|
solver PCG;
|
||||||
|
preconditioner DIC;
|
||||||
tolerance 1e-06;
|
tolerance 1e-06;
|
||||||
relTol 0;
|
relTol 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
"(U|k|epsilon|R|nuTilda|c)"
|
"(U|k|epsilon|R|nuTilda)"
|
||||||
{
|
{
|
||||||
solver smoothSolver;
|
solver PBiCG;
|
||||||
smoother GaussSeidel;
|
preconditioner DILU;
|
||||||
tolerance 1e-05;
|
tolerance 1e-05;
|
||||||
relTol 0;
|
relTol 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
T
|
"(voidfraction|Ksl|UsNext|voidfractionNext|sSmoothField|vSmoothField|fSmooth)"
|
||||||
{
|
{
|
||||||
solver PBiCG;
|
solver PCG;
|
||||||
preconditioner DILU;
|
preconditioner DIC;
|
||||||
tolerance 1e-8;
|
tolerance 1e-09;
|
||||||
relTol 0;
|
relTol 1e-06;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
PISO
|
PISO
|
||||||
{
|
{
|
||||||
nCorrectors 2;
|
nCorrectors 4;
|
||||||
nNonOrthogonalCorrectors 0;
|
nNonOrthogonalCorrectors 0;
|
||||||
pRefCell 0;
|
pRefCell 0;
|
||||||
pRefValue 0;
|
pRefValue 0;
|
||||||
@ -0,0 +1,76 @@
|
|||||||
|
echo both
|
||||||
|
log ../DEM/log.liggghts
|
||||||
|
thermo_log ../DEM/post/thermo.txt
|
||||||
|
|
||||||
|
atom_style granular
|
||||||
|
atom_modify map array sort 0 0
|
||||||
|
communicate single vel yes
|
||||||
|
|
||||||
|
boundary f f f
|
||||||
|
newton off
|
||||||
|
|
||||||
|
units si
|
||||||
|
|
||||||
|
region reg block 0.0 0.1 0.0 0.1 0.0 1.0 units box
|
||||||
|
create_box 1 reg
|
||||||
|
|
||||||
|
neighbor 0.003 bin
|
||||||
|
neigh_modify delay 0 binsize 0.01
|
||||||
|
|
||||||
|
|
||||||
|
# material properties required for granular pair style
|
||||||
|
fix m1 all property/global youngsModulus peratomtype 5.e6
|
||||||
|
fix m2 all property/global poissonsRatio peratomtype 0.45
|
||||||
|
fix m3 all property/global coefficientRestitution peratomtypepair 1 0.3
|
||||||
|
fix m4 all property/global coefficientFriction peratomtypepair 1 0.5
|
||||||
|
|
||||||
|
# pair style
|
||||||
|
pair_style gran model hertz tangential history
|
||||||
|
pair_coeff * *
|
||||||
|
|
||||||
|
# timestep, gravity
|
||||||
|
timestep 0.00001
|
||||||
|
fix gravi all gravity 0.0 vector 0.0 0.0 -1.0
|
||||||
|
|
||||||
|
# walls
|
||||||
|
fix xwalls1 all wall/gran model hertz tangential history primitive type 1 xplane 0.0
|
||||||
|
fix xwalls2 all wall/gran model hertz tangential history primitive type 1 xplane 0.1
|
||||||
|
fix ywalls1 all wall/gran model hertz tangential history primitive type 1 yplane 0.0
|
||||||
|
fix ywalls2 all wall/gran model hertz tangential history primitive type 1 yplane 0.1
|
||||||
|
fix zwalls1 all wall/gran model hertz tangential history primitive type 1 zplane 0.01
|
||||||
|
|
||||||
|
# create particles
|
||||||
|
region bc block 0.0 0.1 0.0 0.1 0.53 1.0 units box
|
||||||
|
fix pts1 all particletemplate/sphere 15485863 atom_type 1 density constant 3000 radius constant 0.0015
|
||||||
|
fix pdd1 all particledistribution/discrete 15485867 1 pts1 1.0
|
||||||
|
|
||||||
|
fix ins all insert/pack seed 32452843 distributiontemplate pdd1 vel constant 0. 0. -0.3 &
|
||||||
|
insert_every once overlapcheck yes all_in yes particles_in_region 1000 region bc
|
||||||
|
|
||||||
|
# cfd coupling
|
||||||
|
fix cfd1 all couple/cfd couple_every 100 mpi
|
||||||
|
fix cfd2 all couple/cfd/force
|
||||||
|
|
||||||
|
variable vx equal vx[1]
|
||||||
|
variable vy equal vy[1]
|
||||||
|
variable vz equal vz[1]
|
||||||
|
variable time equal step*dt
|
||||||
|
|
||||||
|
fix extra all print 100 "${time} ${vx} ${vy} ${vz}" file ../DEM/post/velocity.txt title "#" screen no
|
||||||
|
|
||||||
|
# apply nve integration to all particles that are inserted as single particles
|
||||||
|
fix integr all nve/sphere
|
||||||
|
|
||||||
|
# screen output
|
||||||
|
compute rke all erotate/sphere
|
||||||
|
thermo_style custom step atoms ke c_rke vol
|
||||||
|
thermo 1000
|
||||||
|
thermo_modify lost ignore norm no
|
||||||
|
compute_modify thermo_temp dynamic yes
|
||||||
|
|
||||||
|
# insert the first particles so that dump is not empty
|
||||||
|
run 0
|
||||||
|
dump dmp all custom 1000 ../DEM/post/dump.liggghts_run id type x y z vx vy vz &
|
||||||
|
fx fy fz omegax omegay omegaz radius
|
||||||
|
|
||||||
|
run 0 upto
|
||||||
97
tutorials/cfdemSolverPiso/voidfractionTest/parCFDDEMrun.sh
Normal file
97
tutorials/cfdemSolverPiso/voidfractionTest/parCFDDEMrun.sh
Normal file
@ -0,0 +1,97 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#===================================================================#
|
||||||
|
# allrun script for testcase as part of test routine
|
||||||
|
# run voidfractionTest CFD part
|
||||||
|
# Christoph Goniva - Feb. 2011
|
||||||
|
#===================================================================#
|
||||||
|
|
||||||
|
#- source CFDEM env vars
|
||||||
|
. ~/.bashrc
|
||||||
|
|
||||||
|
#- include functions
|
||||||
|
source $CFDEM_PROJECT_DIR/etc/functions.sh
|
||||||
|
|
||||||
|
#--------------------------------------------------------------------------------#
|
||||||
|
#- define variables
|
||||||
|
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||||
|
logpath=$casePath
|
||||||
|
headerText="run_parallel_cfdemSolverPiso_voidfractionTest_CFDDEM"
|
||||||
|
logfileName="log_$headerText"
|
||||||
|
solverName="cfdemSolverPiso"
|
||||||
|
nrProcs="2"
|
||||||
|
machineFileName="none" # yourMachinefileName | none
|
||||||
|
debugMode="off" # on | off| strict
|
||||||
|
reconstuctCase="false"
|
||||||
|
testHarnessPath="$CFDEM_TEST_HARNESS_PATH"
|
||||||
|
runOctave="true"
|
||||||
|
cleanUp="true"
|
||||||
|
postproc="false"
|
||||||
|
#--------------------------------------------------------------------------------#
|
||||||
|
|
||||||
|
#- call function to run a parallel CFD-DEM case
|
||||||
|
parCFDDEMrun $logpath $logfileName $casePath $headerText $solverName $nrProcs $machineFileName $debugMode $reconstuctCase
|
||||||
|
|
||||||
|
if [ $runOctave == "true" ]
|
||||||
|
then
|
||||||
|
#- change path
|
||||||
|
cd octave
|
||||||
|
|
||||||
|
#- rmove old graph
|
||||||
|
rm averageDDTvoidfraction.png
|
||||||
|
|
||||||
|
#- run octave
|
||||||
|
octave --no-gui particleCellVolume.m
|
||||||
|
|
||||||
|
#- show plot
|
||||||
|
eog averageDDTvoidfraction.png
|
||||||
|
|
||||||
|
#- copy log file to test harness
|
||||||
|
cp ../../$logfileName $testHarnessPath
|
||||||
|
cp averageDDTvoidfraction.png $testHarnessPath
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ $postproc == "true" ]
|
||||||
|
then
|
||||||
|
|
||||||
|
#- keep terminal open (if started in new terminal)
|
||||||
|
echo "simulation finished? ...press enter to proceed"
|
||||||
|
read
|
||||||
|
|
||||||
|
#- get VTK data from liggghts dump file
|
||||||
|
cd $casePath/DEM/post
|
||||||
|
python -i $CFDEM_LPP_DIR/lpp.py dump.liggghts_run
|
||||||
|
|
||||||
|
#- get VTK data from CFD sim
|
||||||
|
cd $casePath/CFD
|
||||||
|
foamToVTK #- serial run of foamToVTK
|
||||||
|
|
||||||
|
#- start paraview
|
||||||
|
paraview
|
||||||
|
|
||||||
|
#- keep terminal open (if started in new terminal)
|
||||||
|
echo "...press enter to clean up case"
|
||||||
|
echo "press Ctr+C to keep data"
|
||||||
|
read
|
||||||
|
fi
|
||||||
|
|
||||||
|
#- clean up case
|
||||||
|
if [ $cleanUp == "true" ]
|
||||||
|
then
|
||||||
|
echo "deleting data at: $casePath ?:\n"
|
||||||
|
read
|
||||||
|
source $WM_PROJECT_DIR/bin/tools/CleanFunctions
|
||||||
|
cd $casePath/CFD
|
||||||
|
cleanCase
|
||||||
|
cd $casePath
|
||||||
|
rm -r $casePath/CFD/particleProbes
|
||||||
|
rm -r $casePath/CFD/postProcessing
|
||||||
|
rm -r $casePath/CFD/clockData
|
||||||
|
rm -r $casePath/DEM/post/*
|
||||||
|
rm -r $casePath/DEM/liggghts.restartCFDEM*
|
||||||
|
echo "done"
|
||||||
|
fi
|
||||||
|
|
||||||
|
#- preserve post directory
|
||||||
|
touch $casePath/DEM/post/.gitignore
|
||||||
|
|
||||||
2
tutorials/cfdemSolverPiso/voidfractionTest/postrun.sh
Executable file
2
tutorials/cfdemSolverPiso/voidfractionTest/postrun.sh
Executable file
@ -0,0 +1,2 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# nothing to see here
|
||||||
13
tutorials/cfdemSolverPiso/voidfractionTest/prerun.sh
Executable file
13
tutorials/cfdemSolverPiso/voidfractionTest/prerun.sh
Executable file
@ -0,0 +1,13 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#- define variables
|
||||||
|
casePath="$(dirname "$(readlink -f ${BASH_SOURCE[0]})")"
|
||||||
|
|
||||||
|
# check if mesh was built
|
||||||
|
if [ -f "$casePath/CFD/constant/polyMesh/boundary" ]; then
|
||||||
|
echo "mesh was built before - using old mesh"
|
||||||
|
else
|
||||||
|
echo "mesh needs to be built"
|
||||||
|
cd $casePath/CFD
|
||||||
|
blockMesh
|
||||||
|
fi
|
||||||
13
tutorials/cfdemSolverPiso/voidfractionTest/run.config
Normal file
13
tutorials/cfdemSolverPiso/voidfractionTest/run.config
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
{
|
||||||
|
"type" : "CFDEMcoupling",
|
||||||
|
"runs" : [
|
||||||
|
{
|
||||||
|
"name" : "cfdemrun",
|
||||||
|
"solver" : "cfdemSolverPiso",
|
||||||
|
"type" : "CFDEMcoupling/mpi",
|
||||||
|
"nprocs" : 2,
|
||||||
|
"pre_scripts" : ["prerun.sh"],
|
||||||
|
"post_scripts" : ["postrun.sh"]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
@ -81,22 +81,14 @@ fix k0_H2 ore property/atom k0_cfd6 vector yes no no 30 23 160
|
|||||||
fix Ea_H2 ore property/atom Ea_cfd6 vector yes no no 63627 85000 105908
|
fix Ea_H2 ore property/atom Ea_cfd6 vector yes no no 63627 85000 105908
|
||||||
|
|
||||||
# particle parameters
|
# particle parameters
|
||||||
fix porosity ore property/atom porosity_ vector yes no no 0.61 0.34 0.19 0.17
|
fix porosity ore property/global porosity_ore vector 0.61 0.34 0.19 0.17
|
||||||
fix tortuosity ore property/global tortuosity_ scalar 3
|
fix tortuosity ore property/global tortuosity_ore scalar 3
|
||||||
fix pore_diameter ore property/global pore_diameter_ scalar 1.e-7
|
fix pore_diameter ore property/global pore_diameter_ore scalar 1.e-7
|
||||||
|
fix layerDensities ore property/global density_ore vector 7870. 5740. 5170. 5240.
|
||||||
|
|
||||||
# define layer properties
|
# define layer properties
|
||||||
fix LayerRelRadii ore property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
fix LayerRelRadii ore property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
||||||
|
|
||||||
### define fix for mass layer - initial testing
|
|
||||||
fix LayerMasses ore property/atom massLayer vector yes no no 0. 0. 0. 0.
|
|
||||||
fix LayerDensities ore property/global density_ore vector 7870. 5740. 5170. 5240.
|
|
||||||
|
|
||||||
## define fix for rho_eff and fracRed - initialize as zero
|
|
||||||
fix fracRed ore property/atom fracRed_ore vector yes no no 0. 0. 0.
|
|
||||||
fix rhoeff ore property/atom rhoeff vector yes no no 0. 0. 0. 0.
|
|
||||||
|
|
||||||
###############
|
###############
|
||||||
# Write data into files for post-processing
|
# Write data into files for post-processing
|
||||||
group part type 1
|
group part type 1
|
||||||
|
|||||||
@ -69,21 +69,14 @@ fix k0_H2 all property/atom k0_cfd6 vector yes no no 30 23 160
|
|||||||
fix Ea_H2 all property/atom Ea_cfd6 vector yes no no 63627 71162 92092
|
fix Ea_H2 all property/atom Ea_cfd6 vector yes no no 63627 71162 92092
|
||||||
|
|
||||||
# particle porosity/tortuosity/pore diameter
|
# particle porosity/tortuosity/pore diameter
|
||||||
fix porosity all property/atom porosity_ vector yes no no 0.65 0.31 0.16 0.15
|
fix porosity all property/global porosity_all vector 0.65 0.31 0.16 0.15
|
||||||
fix tortuosity all property/global tortuosity_ scalar 3
|
fix tortuosity all property/global tortuosity_all scalar 3
|
||||||
fix pore_diameter all property/global pore_diameter_ scalar 7e-7
|
fix pore_diameter all property/global pore_diameter_all scalar 7e-7
|
||||||
|
fix layerDensities all property/global density_all vector 7870. 5740. 5170. 5240.
|
||||||
|
|
||||||
# define layer properties
|
# define layer properties
|
||||||
fix LayerRelRadii all property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
fix LayerRelRadii all property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
||||||
|
|
||||||
# define fix for mass layer - initial testing
|
|
||||||
fix LayerMasses all property/atom massLayer vector yes no no 0. 0. 0. 0.
|
|
||||||
fix LayerDensities all property/global density_all vector 7870. 5740. 5170. 5240.
|
|
||||||
|
|
||||||
# define fix for rho_eff and fracRed - initialize as zero
|
|
||||||
fix fracRed all property/atom fracRed_all vector yes no no 0. 0. 0.
|
|
||||||
fix rhoeff all property/atom rhoeff vector yes no no 0. 0. 0. 0.
|
|
||||||
|
|
||||||
###############
|
###############
|
||||||
# Write data into files for post-processing
|
# Write data into files for post-processing
|
||||||
|
|
||||||
|
|||||||
@ -69,21 +69,14 @@ fix k0_H2 all property/atom k0_cfd6 vector yes no no 30 23 160
|
|||||||
fix Ea_H2 all property/atom Ea_cfd6 vector yes no no 63627 71162 92092
|
fix Ea_H2 all property/atom Ea_cfd6 vector yes no no 63627 71162 92092
|
||||||
|
|
||||||
# particle porosity/tortuosity/pore diameter
|
# particle porosity/tortuosity/pore diameter
|
||||||
fix porosity all property/atom porosity_ vector yes no no 0.65 0.31 0.16 0.15
|
fix porosity all property/global porosity_all vector 0.65 0.31 0.16 0.15
|
||||||
fix tortuosity all property/global tortuosity_ scalar 3
|
fix tortuosity all property/global tortuosity_all scalar 3
|
||||||
fix pore_diameter all property/global pore_diameter_ scalar 7e-7
|
fix pore_diameter all property/global pore_diameter_all scalar 7e-7
|
||||||
|
fix layerDensities all property/global density_all vector 7870. 5740. 5170. 5240.
|
||||||
|
|
||||||
# define layer properties
|
# define layer properties
|
||||||
fix LayerRelRadii all property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
fix LayerRelRadii all property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
||||||
|
|
||||||
### define fix for mass layer - initial testing
|
|
||||||
fix LayerMasses all property/atom massLayer vector yes no no 0. 0. 0. 0.
|
|
||||||
fix LayerDensities all property/global density_all vector 7870. 5740. 5170. 5240.
|
|
||||||
|
|
||||||
## define fix for rho_eff and fracRed - initialize as zero
|
|
||||||
fix fracRed all property/atom fracRed_all vector yes no no 0. 0. 0.
|
|
||||||
fix rhoeff all property/atom rhoeff vector yes no no 0. 0. 0. 0.
|
|
||||||
|
|
||||||
###############
|
###############
|
||||||
# Write data into files for post-processing
|
# Write data into files for post-processing
|
||||||
|
|
||||||
|
|||||||
@ -65,21 +65,14 @@ fix k0_CO all property/atom k0_cfd5 vector yes no no 17 25 2700
|
|||||||
fix Ea_CO all property/atom Ea_cfd5 vector yes no no 69488 73674 113859
|
fix Ea_CO all property/atom Ea_cfd5 vector yes no no 69488 73674 113859
|
||||||
|
|
||||||
# particle porosity/tortuosity/pore diameter
|
# particle porosity/tortuosity/pore diameter
|
||||||
fix porosity all property/atom porosity_ vector yes no no 0.65 0.31 0.16 0.15
|
fix porosity all property/global porosity_all vector 0.65 0.31 0.16 0.15
|
||||||
fix tortuosity all property/global tortuosity_ scalar 3
|
fix tortuosity all property/global tortuosity_all scalar 3
|
||||||
fix pore_diameter all property/global pore_diameter_ scalar 5.5e-7
|
fix pore_diameter all property/global pore_diameter_all scalar 5.5e-7
|
||||||
|
fix layerDensities all property/global density_all vector 7870. 5740. 5170. 5240.
|
||||||
|
|
||||||
# define layer properties
|
# define layer properties
|
||||||
fix LayerRelRadii all property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
fix LayerRelRadii all property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
||||||
|
|
||||||
### define fix for mass layer - initial testing
|
|
||||||
fix LayerMasses all property/atom massLayer vector yes no no 0. 0. 0. 0.
|
|
||||||
fix LayerDensities all property/global density_all vector 7870. 5740. 5170. 5240.
|
|
||||||
|
|
||||||
## define fix for rho_eff and fracRed - initialize as zero
|
|
||||||
fix fracRed all property/atom fracRed_all vector yes no no 0. 0. 0.
|
|
||||||
fix rhoeff all property/atom rhoeff vector yes no no 0. 0. 0. 0.
|
|
||||||
|
|
||||||
###############
|
###############
|
||||||
# Write data into files for post-processing
|
# Write data into files for post-processing
|
||||||
|
|
||||||
|
|||||||
@ -65,21 +65,14 @@ fix k0_CO all property/atom k0_cfd5 vector yes no no 17 25 2700
|
|||||||
fix Ea_CO all property/atom Ea_cfd5 vector yes no no 69488 73674 113859
|
fix Ea_CO all property/atom Ea_cfd5 vector yes no no 69488 73674 113859
|
||||||
|
|
||||||
# particle porosity/tortuosity/pore diameter
|
# particle porosity/tortuosity/pore diameter
|
||||||
fix porosity all property/atom porosity_ vector yes no no 0.65 0.31 0.16 0.15
|
fix porosity all property/global porosity_all vector 0.65 0.31 0.16 0.15
|
||||||
fix tortuosity all property/global tortuosity_ scalar 3
|
fix tortuosity all property/global tortuosity_all scalar 3
|
||||||
fix pore_diameter all property/global pore_diameter_ scalar 5.5e-7
|
fix pore_diameter all property/global pore_diameter_all scalar 5.5e-7
|
||||||
|
fix layerDensities all property/global density_all vector 7870. 5740. 5170. 5240.
|
||||||
|
|
||||||
# define layer properties
|
# define layer properties
|
||||||
fix LayerRelRadii all property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
fix LayerRelRadii all property/atom relRadii vector yes no no 1.0 0.998 0.995 0.98
|
||||||
|
|
||||||
### define fix for mass layer - initial testing
|
|
||||||
fix LayerMasses all property/atom massLayer vector yes no no 0. 0. 0. 0.
|
|
||||||
fix LayerDensities all property/global density_all vector 7870. 5740. 5170. 5240.
|
|
||||||
|
|
||||||
## define fix for rho_eff and fracRed - initialize as zero
|
|
||||||
fix fracRed all property/atom fracRed_all vector yes no no 0. 0. 0.
|
|
||||||
fix rhoeff all property/atom rhoeff vector yes no no 0. 0. 0. 0.
|
|
||||||
|
|
||||||
###############
|
###############
|
||||||
# Write data into files for post-processing
|
# Write data into files for post-processing
|
||||||
|
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
1.) creation of databases
|
1.) creation of databases
|
||||||
go to folder db1 and execute run.sh; once finished, execute postrun.sh; same for folder db2
|
execute createDB1.sh and createDB2.sh to create the databases for two different inlet velocities
|
||||||
2.) rCFD run
|
2.) rCFD run
|
||||||
first transfer and decompose the databases by executing prerun.sh; for the actual rCFD run, execute run.sh
|
first transfer and decompose the databases by executing prerunRCFD.sh; for the actual rCFD run, execute runRCFD.sh
|
||||||
|
|||||||
@ -0,0 +1,19 @@
|
|||||||
|
cd db$1
|
||||||
|
cd CFD
|
||||||
|
rm -r proc*
|
||||||
|
rm -r dynamicCode
|
||||||
|
rm -r postProcessing*
|
||||||
|
rm -r clockData
|
||||||
|
rm -r [0-9]*
|
||||||
|
rm -r -[0-9]*
|
||||||
|
rm -r dataBase*
|
||||||
|
rm log.*
|
||||||
|
rm *.log
|
||||||
|
|
||||||
|
cd ../DEM
|
||||||
|
cd post
|
||||||
|
rm *
|
||||||
|
cd ..
|
||||||
|
rm *.txt
|
||||||
|
rm liggghts.restartCFDEM*
|
||||||
|
cd ../..
|
||||||
@ -0,0 +1 @@
|
|||||||
|
./cleanDB.sh 1
|
||||||
@ -0,0 +1 @@
|
|||||||
|
./cleanDB.sh 2
|
||||||
@ -0,0 +1,11 @@
|
|||||||
|
./cleanRCFD_rundata.sh
|
||||||
|
|
||||||
|
cd rCFD
|
||||||
|
|
||||||
|
cd CFD
|
||||||
|
rm -r dataBase*
|
||||||
|
|
||||||
|
cd ../DEM
|
||||||
|
rm liggghts.restart
|
||||||
|
|
||||||
|
cd ../..
|
||||||
@ -0,0 +1,23 @@
|
|||||||
|
cd rCFD
|
||||||
|
|
||||||
|
cd CFD
|
||||||
|
rm -r proc*
|
||||||
|
rm -r dynamicCode
|
||||||
|
rm -r postProcessing*
|
||||||
|
rm -r clockData
|
||||||
|
rm -r [0-9]*
|
||||||
|
rm -r [0-9]*
|
||||||
|
rm log.*
|
||||||
|
rm *.log
|
||||||
|
rm recurrenceError
|
||||||
|
rm recurrenceMatrix
|
||||||
|
rm recurrencePath
|
||||||
|
|
||||||
|
|
||||||
|
cd ../DEM
|
||||||
|
cd post
|
||||||
|
rm *
|
||||||
|
cd ..
|
||||||
|
rm *.txt
|
||||||
|
rm liggghts.restartCFDEM*
|
||||||
|
cd ../..
|
||||||
@ -0,0 +1 @@
|
|||||||
|
./runDB.sh 1
|
||||||
@ -0,0 +1 @@
|
|||||||
|
./runDB.sh 2
|
||||||
@ -1,39 +0,0 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
|
||||||
| ========= | |
|
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
|
||||||
| \\ / O peration | Version: 4.0 |
|
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
|
||||||
| \\/ M anipulation | |
|
|
||||||
\*---------------------------------------------------------------------------*/
|
|
||||||
FoamFile
|
|
||||||
{
|
|
||||||
version 2.0;
|
|
||||||
format ascii;
|
|
||||||
class volVectorField;
|
|
||||||
location "-5";
|
|
||||||
object Us;
|
|
||||||
}
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
||||||
|
|
||||||
dimensions [0 1 -1 0 0 0 0];
|
|
||||||
|
|
||||||
internalField uniform (0 0 0);
|
|
||||||
|
|
||||||
boundaryField
|
|
||||||
{
|
|
||||||
walls
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
inlet
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
outlet
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
|
||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -10,7 +10,7 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
location "-5";
|
location "0";
|
||||||
object Ksl;
|
object Ksl;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: 4.x |
|
| \\ / O peration | Version: 4.0 |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -11,11 +11,11 @@ FoamFile
|
|||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
location "0";
|
location "0";
|
||||||
object QCoeff;
|
object NuField;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
dimensions [1 -1 -3 -1 0 0 0];
|
dimensions [0 0 0 0 0 0 0];
|
||||||
|
|
||||||
internalField uniform 0;
|
internalField uniform 0;
|
||||||
|
|
||||||
@ -36,11 +36,6 @@ boundaryField
|
|||||||
type calculated;
|
type calculated;
|
||||||
value uniform 0;
|
value uniform 0;
|
||||||
}
|
}
|
||||||
nozzle
|
|
||||||
{
|
|
||||||
type calculated;
|
|
||||||
value uniform 0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -10,30 +10,31 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
location "-5";
|
location "0";
|
||||||
object voidfraction;
|
object ReField;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
dimensions [0 0 0 0 0 0 0];
|
dimensions [0 0 0 0 0 0 0];
|
||||||
|
|
||||||
internalField uniform 1;
|
internalField uniform 0;
|
||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
walls
|
walls
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
}
|
}
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
type fixedValue;
|
type calculated;
|
||||||
value uniform 1;
|
value uniform 0;
|
||||||
}
|
}
|
||||||
outlet
|
outlet
|
||||||
{
|
{
|
||||||
type fixedValue;
|
type calculated;
|
||||||
value uniform 1;
|
value uniform 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -10,7 +10,7 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
location "-5";
|
location "0";
|
||||||
object T;
|
object T;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
@ -10,7 +10,7 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volVectorField;
|
class volVectorField;
|
||||||
location "-5";
|
location "0";
|
||||||
object U;
|
object U;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
@ -34,8 +34,8 @@ boundaryField
|
|||||||
|
|
||||||
2
|
2
|
||||||
(
|
(
|
||||||
(-10 (0 0 0))
|
(0 (0 0 0))
|
||||||
(-9.9 (0 0 0.4))
|
(0.5 (0 0 0.4))
|
||||||
)
|
)
|
||||||
;
|
;
|
||||||
value uniform (0 0 0.4);
|
value uniform (0 0 0.4);
|
||||||
@ -10,7 +10,7 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
location "-5";
|
location "0";
|
||||||
object addSource;
|
object addSource;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
@ -10,7 +10,7 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
location "-5";
|
location "0";
|
||||||
object p;
|
object p;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
@ -0,0 +1,39 @@
|
|||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: 4.0 |
|
||||||
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class volScalarField;
|
||||||
|
location "0";
|
||||||
|
object partTemp;
|
||||||
|
}
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
dimensions [0 0 0 1 0 0 0];
|
||||||
|
|
||||||
|
internalField uniform 0;
|
||||||
|
|
||||||
|
boundaryField
|
||||||
|
{
|
||||||
|
walls
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
}
|
||||||
|
inlet
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
}
|
||||||
|
outlet
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -0,0 +1,42 @@
|
|||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: 4.0 |
|
||||||
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class volScalarField;
|
||||||
|
location "0";
|
||||||
|
object particleRelTemp;
|
||||||
|
}
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
dimensions [0 0 0 0 0 0 0];
|
||||||
|
|
||||||
|
internalField uniform 0;
|
||||||
|
|
||||||
|
boundaryField
|
||||||
|
{
|
||||||
|
walls
|
||||||
|
{
|
||||||
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
inlet
|
||||||
|
{
|
||||||
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
outlet
|
||||||
|
{
|
||||||
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -10,7 +10,7 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
location "-5";
|
location "0";
|
||||||
object rho;
|
object rho;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
@ -17,7 +17,7 @@ FoamFile
|
|||||||
|
|
||||||
dimensions [0 0 0 0 0 0 0];
|
dimensions [0 0 0 0 0 0 0];
|
||||||
|
|
||||||
internalField uniform 1;
|
internalField uniform 1.0;
|
||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
@ -27,12 +27,12 @@ boundaryField
|
|||||||
}
|
}
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
type fixedValue;
|
type calculated;
|
||||||
value uniform 1;
|
value uniform 1;
|
||||||
}
|
}
|
||||||
outlet
|
outlet
|
||||||
{
|
{
|
||||||
type fixedValue;
|
type calculated;
|
||||||
value uniform 1;
|
value uniform 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -10,7 +10,7 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
location "-5";
|
location "0";
|
||||||
object wallQFactor;
|
object wallQFactor;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
@ -19,11 +19,11 @@ application pisoFoam;
|
|||||||
|
|
||||||
startFrom startTime;
|
startFrom startTime;
|
||||||
|
|
||||||
startTime -0.005;
|
startTime 0.0;
|
||||||
|
|
||||||
stopAt endTime;
|
stopAt endTime;
|
||||||
|
|
||||||
endTime 2.5;
|
endTime 5.0;
|
||||||
|
|
||||||
deltaT 0.00005;
|
deltaT 0.00005;
|
||||||
|
|
||||||
@ -1,508 +0,0 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
|
||||||
| ========= | |
|
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
|
||||||
| \\ / O peration | Version: 2.3.0 |
|
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
|
||||||
| \\/ M anipulation | |
|
|
||||||
\*---------------------------------------------------------------------------*/
|
|
||||||
FoamFile
|
|
||||||
{
|
|
||||||
version 2.0;
|
|
||||||
format ascii;
|
|
||||||
class dictionary;
|
|
||||||
object topoSetDict;
|
|
||||||
}
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
||||||
#include "../geometry"
|
|
||||||
actions
|
|
||||||
(
|
|
||||||
{
|
|
||||||
name c0;
|
|
||||||
type cellSet;
|
|
||||||
action new;
|
|
||||||
source boxToCell;
|
|
||||||
sourceInfo
|
|
||||||
{
|
|
||||||
box (#calc "-0.5*$nx" #calc "-0.5*$ny" -0.1)(#calc "0.5*$nx" #calc "0.5*$ny" 0.1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
{
|
|
||||||
name nozzle;
|
|
||||||
type faceSet;
|
|
||||||
action new;
|
|
||||||
source patchToFace;
|
|
||||||
sourceInfo
|
|
||||||
{
|
|
||||||
name "inlet";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
name nozzle;
|
|
||||||
type faceSet;
|
|
||||||
action subset;
|
|
||||||
source cellToFace;
|
|
||||||
sourceInfo
|
|
||||||
{
|
|
||||||
set c0;
|
|
||||||
option all;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
);
|
|
||||||
|
|
||||||
// List of actions. Each action is a dictionary with e.g.
|
|
||||||
// // name of set
|
|
||||||
// name c0;
|
|
||||||
//
|
|
||||||
// // type: pointSet/faceSet/cellSet/faceZoneSet/cellZoneSet
|
|
||||||
// type cellSet;
|
|
||||||
//
|
|
||||||
// // action to perform on set. Two types:
|
|
||||||
// // - require no source : clear/invert/remove
|
|
||||||
// // clear : clears set or zone
|
|
||||||
// // invert : select all currently non-selected elements
|
|
||||||
// // remove : removes set or zone
|
|
||||||
// // - require source : new/add/delete/subset
|
|
||||||
// // new : create new set or zone from source
|
|
||||||
// // add : add source to contents
|
|
||||||
// // delete : deletes source from contents
|
|
||||||
// // subset : keeps elements both in contents and source
|
|
||||||
// action new;
|
|
||||||
//
|
|
||||||
// The source entry varies according to the type of set:
|
|
||||||
//
|
|
||||||
// cellSet
|
|
||||||
// ~~~~~~~
|
|
||||||
//
|
|
||||||
// // Select by explicitly providing cell labels
|
|
||||||
// source labelToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// value (12 13 56); // labels of cells
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Copy elements from cellSet
|
|
||||||
// source cellToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set c1;
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Cells in cell zone
|
|
||||||
// source zoneToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// name ".*Zone"; // Name of cellZone, regular expressions allowed
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Cells on master or slave side of faceZone
|
|
||||||
// source faceZoneToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// name ".*Zone"; // Name of faceZone, regular expressions allowed
|
|
||||||
// option master; // master/slave
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on faceSet
|
|
||||||
// source faceToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set f0; // Name of faceSet
|
|
||||||
//
|
|
||||||
// //option neighbour; // cell with neighbour in faceSet
|
|
||||||
// //option owner; // ,, owner
|
|
||||||
// option any; // cell with any face in faceSet
|
|
||||||
// //option all; // cell with all faces in faceSet
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on pointSet
|
|
||||||
// source pointToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set p0;
|
|
||||||
// option any; // cell with any point in pointSet
|
|
||||||
// //option edge; // cell with an edge with both points in pointSet
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on cellShape
|
|
||||||
// source shapeToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// type hex; // hex/wedge/prism/pyr/tet/tetWedge/splitHex
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Cells with cell centre within box ('box') or multiple boxes ('boxes')
|
|
||||||
// source boxToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// box (0 0 0) (1 1 1);
|
|
||||||
// //boxes ((0 0 0) (1 1 1) (10 10 10)(11 11 11));
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Cells with cell centre within box
|
|
||||||
// // Is skewed, rotated box. Given as origin and three spanning vectors.
|
|
||||||
// source rotatedBoxToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// origin (0.2 0.2 -10);
|
|
||||||
// i (0.2 0.2 0);
|
|
||||||
// j (-0.2 0.2 0);
|
|
||||||
// k (10 10 10);
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Cells with centre within cylinder
|
|
||||||
// source cylinderToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// p1 (0.2 0.2 -10); // start point on cylinder axis
|
|
||||||
// p2 (0.2 0.2 0); // end point on cylinder axis
|
|
||||||
// radius 5.0;
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Cells with centre within sphere
|
|
||||||
// source sphereToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// centre (0.2 0.2 -10);
|
|
||||||
// radius 5.0;
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Cells with cellCentre nearest to coordinates
|
|
||||||
// source nearestToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// points ((0 0 0) (1 1 1)(2 2 2));
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on surface
|
|
||||||
// source surfaceToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// file "www.avl.com-geometry.stl";
|
|
||||||
// useSurfaceOrientation false; // use closed surface inside/outside
|
|
||||||
// // test (ignores includeCut,
|
|
||||||
// // outsidePoints)
|
|
||||||
// outsidePoints ((-99 -99 -59)); // definition of outside
|
|
||||||
// includeCut false; // cells cut by surface
|
|
||||||
// includeInside false; // cells not on outside of surf
|
|
||||||
// includeOutside false; // cells on outside of surf
|
|
||||||
// nearDistance -1; // cells with centre near surf
|
|
||||||
// // (set to -1 if not used)
|
|
||||||
// curvature 0.9; // cells within nearDistance
|
|
||||||
// // and near surf curvature
|
|
||||||
// // (set to -100 if not used)
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // values of field within certain range
|
|
||||||
// source fieldToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// fieldName U; // Note: uses mag(U) since volVectorField
|
|
||||||
// min 0.1;
|
|
||||||
// max 0.5;
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Mesh region (non-face connected part of (subset of)mesh)
|
|
||||||
// source regionToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set c0; // optional name of cellSet giving mesh subset
|
|
||||||
// insidePoints ((1 2 3)); // points inside region to select
|
|
||||||
// nErode 0; // optional number of layers to erode
|
|
||||||
// // selection
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Cells underneath plane such that volume is reached. E.g. for use
|
|
||||||
// // in setFields to set the level given a wanted volume.
|
|
||||||
// source targetVolumeToCell;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// volume 2e-05;
|
|
||||||
// normal (0 1 0); // usually in direction of gravity
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
//
|
|
||||||
//
|
|
||||||
// faceSet
|
|
||||||
// ~~~~~~~
|
|
||||||
//
|
|
||||||
// // Copy elements from faceSet
|
|
||||||
// source faceToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set f1;
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on cellSet
|
|
||||||
// source cellToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set c0;
|
|
||||||
// option all; // All faces of cells
|
|
||||||
// //option both; // Only faces whose owner&neighbour are in cellSet
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on pointSet
|
|
||||||
// source pointToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set p0;
|
|
||||||
// option any; // Faces using any point in pointSet
|
|
||||||
// //option all // Faces with all points in pointSet
|
|
||||||
// //option edge // Faces with two consecutive points in pointSet
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select by explicitly providing face labels
|
|
||||||
// source labelToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// value (12 13 56); // labels of faces
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // All faces of patch
|
|
||||||
// source patchToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// name ".*Wall"; // Name of patch or patch group,
|
|
||||||
// // (regular expressions allowed)
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // All boundary faces
|
|
||||||
// source boundaryToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // All faces of faceZone
|
|
||||||
// source zoneToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// name ".*Zone1"; // Name of faceZone, regular expressions allowed
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Faces with face centre within box ('box') or multiple boxes ('boxes')
|
|
||||||
// source boxToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// box (0 0 0) (1 1 1);
|
|
||||||
// //boxes ((0 0 0) (1 1 1) (10 10 10)(11 11 11));
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Faces with normal to within certain angle aligned with vector.
|
|
||||||
// source normalToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// normal (0 0 1); // Vector
|
|
||||||
// cos 0.01; // Tolerance (max cos of angle)
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Walk on faces in faceSet, starting from face nearest given position
|
|
||||||
// source regionToFace;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set f0;
|
|
||||||
// nearPoint (0.1 0.1 0.005);
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
//
|
|
||||||
//
|
|
||||||
// pointSet
|
|
||||||
// ~~~~~~~
|
|
||||||
//
|
|
||||||
// // Copy elements from pointSet
|
|
||||||
// source pointToPoint;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set p1;
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on cellSet
|
|
||||||
// source cellToPoint;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set c0;
|
|
||||||
// option all; // all points of cell
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on faceSet
|
|
||||||
// source faceToPoint;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set f0; // name of faceSet
|
|
||||||
// option all; // all points of face
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select by explicitly providing point labels
|
|
||||||
// source labelToPoint;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// value (12 13 56); // labels of points
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // All points in pointzone
|
|
||||||
// source zoneToPoint;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// name ".*Zone"; // name of pointZone, regular expressions allowed
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Points nearest to coordinates
|
|
||||||
// source nearestToPoint;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// points ((0 0 0) (1 1 1));
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Points with coordinate within box ('box') or multiple boxes ('boxes')
|
|
||||||
// source boxToPoint;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// box (0 0 0) (1 1 1);
|
|
||||||
// //boxes ((0 0 0) (1 1 1) (10 10 10)(11 11 11));
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on surface
|
|
||||||
// source surfaceToPoint;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// file "www.avl.com-geometry.stl";
|
|
||||||
// nearDistance 0.1; // points near to surface
|
|
||||||
// includeInside false; // points on inside of surface
|
|
||||||
// // (requires closed surface with consistent
|
|
||||||
// // normals)
|
|
||||||
// includeOutside false; // ,, outside ,,
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
//
|
|
||||||
//
|
|
||||||
//
|
|
||||||
// cellZoneSet
|
|
||||||
// ~~~~~~~~~~~
|
|
||||||
// (mirrors operations on a cellSet into a cellZone)
|
|
||||||
//
|
|
||||||
// // Select based on cellSet
|
|
||||||
// source setToCellZone;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set c0; // name of cellSet
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
//
|
|
||||||
//
|
|
||||||
// faceZoneSet
|
|
||||||
// ~~~~~~~~~~~
|
|
||||||
// // Select based on faceSet without orientation
|
|
||||||
// source setToFaceZone;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// faceSet f0; // name of faceSet
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on faceSet, using cellSet to determine orientation
|
|
||||||
// source setsToFaceZone;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// faceSet f0; // name of faceSet
|
|
||||||
// cellSet c0; // name of cellSet of slave side
|
|
||||||
// flip false; // optional: flip the faceZone (so now the cellSet
|
|
||||||
// // is the master side)
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
// // Select based on surface. Orientation from normals on surface
|
|
||||||
// {
|
|
||||||
// name fz0;
|
|
||||||
// type faceZoneSet;
|
|
||||||
// action new;
|
|
||||||
// source searchableSurfaceToFaceZone;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// surface searchableSphere;
|
|
||||||
// centre (0.05 0.05 0.005);
|
|
||||||
// radius 0.025;
|
|
||||||
// //name sphere.stl; // Optional name if surface triSurfaceMesh
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
//
|
|
||||||
//
|
|
||||||
// pointZoneSet
|
|
||||||
// ~~~~~~~~~~~~
|
|
||||||
// (mirrors operations on a pointSet into a pointZone)
|
|
||||||
//
|
|
||||||
// // Select based on pointSet
|
|
||||||
// source setToPointZone;
|
|
||||||
// sourceInfo
|
|
||||||
// {
|
|
||||||
// set p0; // name of pointSet
|
|
||||||
// }
|
|
||||||
//
|
|
||||||
//
|
|
||||||
//
|
|
||||||
/*
|
|
||||||
actions
|
|
||||||
(
|
|
||||||
// Example:pick up internal faces on outside of cellSet
|
|
||||||
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
||||||
|
|
||||||
// Load initial cellSet
|
|
||||||
{
|
|
||||||
name c0;
|
|
||||||
type cellSet;
|
|
||||||
action new;
|
|
||||||
source labelToCell;
|
|
||||||
sourceInfo
|
|
||||||
{
|
|
||||||
value (12 13 56);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Get all faces in cellSet
|
|
||||||
{
|
|
||||||
name f0;
|
|
||||||
type faceSet;
|
|
||||||
action new;
|
|
||||||
source cellToFace;
|
|
||||||
sourceInfo
|
|
||||||
{
|
|
||||||
set c0;
|
|
||||||
option all;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Determine inverse cellSet
|
|
||||||
{
|
|
||||||
name c1;
|
|
||||||
type cellSet;
|
|
||||||
action new;
|
|
||||||
source cellToCell;
|
|
||||||
sourceInfo
|
|
||||||
{
|
|
||||||
set c0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
{
|
|
||||||
name c1;
|
|
||||||
type cellSet;
|
|
||||||
action invert;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Keep in f0 all faces in c1
|
|
||||||
{
|
|
||||||
name f0;
|
|
||||||
type faceSet;
|
|
||||||
action subset;
|
|
||||||
source cellToFace;
|
|
||||||
sourceInfo
|
|
||||||
{
|
|
||||||
set c1;
|
|
||||||
option all;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
);
|
|
||||||
*/
|
|
||||||
// ************************************************************************* //
|
|
||||||
@ -1,6 +0,0 @@
|
|||||||
cd CFD
|
|
||||||
cp system/controlDict_equil system/controlDict
|
|
||||||
decomposePar -force
|
|
||||||
mpirun -np 4 cfdemSolverRhoPimple -parallel
|
|
||||||
cp system/controlDict_record system/controlDict
|
|
||||||
mpirun -np 4 cfdemSolverRhoPimple -parallel
|
|
||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
========= |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
| \\ / O peration | Version: 4.x |
|
\\ / O peration | Website: https://openfoam.org
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
\\ / A nd | Version: 6
|
||||||
| \\/ M anipulation | |
|
\\/ M anipulation |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
FoamFile
|
FoamFile
|
||||||
{
|
{
|
||||||
|
|||||||
@ -10,7 +10,7 @@ FoamFile
|
|||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class volScalarField;
|
class volScalarField;
|
||||||
location "-5";
|
location "0";
|
||||||
object Ksl;
|
object Ksl;
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
@ -0,0 +1,42 @@
|
|||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: 4.0 |
|
||||||
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class volScalarField;
|
||||||
|
location "0";
|
||||||
|
object NuField;
|
||||||
|
}
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
dimensions [0 0 0 0 0 0 0];
|
||||||
|
|
||||||
|
internalField uniform 0;
|
||||||
|
|
||||||
|
boundaryField
|
||||||
|
{
|
||||||
|
walls
|
||||||
|
{
|
||||||
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
inlet
|
||||||
|
{
|
||||||
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
outlet
|
||||||
|
{
|
||||||
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -0,0 +1,42 @@
|
|||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: 4.0 |
|
||||||
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class volScalarField;
|
||||||
|
location "0";
|
||||||
|
object ReField;
|
||||||
|
}
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
dimensions [0 0 0 0 0 0 0];
|
||||||
|
|
||||||
|
internalField uniform 0;
|
||||||
|
|
||||||
|
boundaryField
|
||||||
|
{
|
||||||
|
walls
|
||||||
|
{
|
||||||
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
inlet
|
||||||
|
{
|
||||||
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
outlet
|
||||||
|
{
|
||||||
|
type calculated;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user