createFields.H
Go to the documentation of this file.
1 #include "readGravitationalAcceleration.H"
2 
3 Info<< "Reading thermophysical properties\n" << endl;
4 
5 autoPtr<psiThermo> pThermo
6 (
8 );
9 psiThermo& thermo = pThermo();
10 
12 (
13  IOobject
14  (
15  "rho",
16  runTime.timeName(),
17  mesh,
18  IOobject::NO_READ,
19  IOobject::AUTO_WRITE
20  ),
21  thermo.rho()
22 );
23 
24 Info<< "\nReading field U\n" << endl;
26 (
27  IOobject
28  (
29  "U",
30  runTime.timeName(),
31  mesh,
32  IOobject::MUST_READ,
33  IOobject::AUTO_WRITE
34  ),
35  mesh
36 );
37 
38 #include "compressibleCreatePhi.H"
39 
40 Info<< "Creating turbulence model\n" << endl;
41 autoPtr<compressible::turbulenceModel> turbulence
42 (
44  (
45  rho,
46  U,
47  phi,
48  thermo
49  )
50 );
51 
52 const word kinematicCloudName
53 (
54  args.getOrDefault<word>("cloud", "kinematicCloud")
55 );
56 
57 Info<< "Constructing kinematicCloud " << kinematicCloudName << endl;
58 basicKinematicCloud kinematicCloud
59 (
61  rho,
62  U,
63  thermo.mu(),
64  g
65 );
runTime
engineTime & runTime
Definition: createEngineTime.H:13
U
volVectorField U(IOobject("U", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::NO_WRITE), mesh, dimensionedVector(dimVelocity, Zero))
turbulence
Info<< "Reading field U\n"<< endl;volVectorField U(IOobject("U", runTime.timeName(), mesh, IOobject::MUST_READ, IOobject::AUTO_WRITE), mesh);volScalarField rho(IOobject("rho", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::AUTO_WRITE), thermo.rho());volVectorField rhoU(IOobject("rhoU", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::NO_WRITE), rho *U);volScalarField rhoE(IOobject("rhoE", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::NO_WRITE), rho *(e+0.5 *magSqr(U)));surfaceScalarField pos(IOobject("pos", runTime.timeName(), mesh), mesh, dimensionedScalar("pos", dimless, 1.0));surfaceScalarField neg(IOobject("neg", runTime.timeName(), mesh), mesh, dimensionedScalar("neg", dimless, -1.0));surfaceScalarField phi("phi", fvc::flux(rhoU));Info<< "Creating turbulence model\n"<< endl;autoPtr< compressible::turbulenceModel > turbulence(compressible::turbulenceModel::New(rho, U, phi, thermo))
Definition: createFields.H:94
Foam::argList::getOrDefault
T getOrDefault(const word &optName, const T &deflt) const
Get a value from the named option if present, or return default.
Definition: argListI.H:307
thermo
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
rho
rho
Definition: createFields.H:81
Foam::endl
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:369
basicKinematicCloud
Cloud class to introduce kinematic parcels.
Foam::Info
messageStream Info
Information stream (stdout output on master, null elsewhere)
phi
surfaceScalarField & phi
Definition: setRegionFluidFields.H:8
Foam::volScalarField
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:57
mesh
dynamicFvMesh & mesh
Definition: createDynamicFvMesh.H:6
g
const uniformDimensionedVectorField & g
Definition: createFluidFields.H:26
compressibleCreatePhi.H
Creates and initialises the face-flux field phi.
Foam::volVectorField
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:62
Foam::New
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh >> &tdf1, const word &name, const dimensionSet &dimensions)
Global function forwards to reuseTmpDimensionedField::New.
Definition: DimensionedFieldReuseFunctions.H:105
kinematicCloudName
const word kinematicCloudName(args.getOrDefault< word >("cloud", "kinematicCloud"))
args
Foam::argList args(argc, argv)
pThermo
Info<< "Reading thermophysical properties\n"<< endl;autoPtr< psiReactionThermo > pThermo(psiReactionThermo::New(mesh))