createFields.H
Go to the documentation of this file.
1 Info<< "Reading thermophysical properties\n" << endl;
2 
3 autoPtr<psiThermo> pThermo
4 (
6 );
7 psiThermo& thermo = pThermo();
8 thermo.validate(args.executable(), "h", "e");
9 
10 volScalarField& p = thermo.p();
11 
13 (
14  IOobject
15  (
16  "rho",
17  runTime.timeName(),
18  mesh,
19  IOobject::READ_IF_PRESENT,
20  IOobject::AUTO_WRITE
21  ),
22  thermo.rho()
23 );
24 
25 Info<< "Reading field U\n" << endl;
27 (
28  IOobject
29  (
30  "U",
31  runTime.timeName(),
32  mesh,
33  IOobject::MUST_READ,
34  IOobject::AUTO_WRITE
35  ),
36  mesh
37 );
38 
39 #include "compressibleCreatePhi.H"
40 
42 (
43  dimensionedScalar::lookupOrDefault
44  (
45  "rhoMax",
46  pimple.dict(),
47  dimDensity,
48  GREAT
49  )
50 );
51 
53 (
54  dimensionedScalar::lookupOrDefault
55  (
56  "rhoMin",
57  pimple.dict(),
58  dimDensity,
59  0
60  )
61 );
62 
63 Info<< "Creating turbulence model\n" << endl;
64 autoPtr<compressible::turbulenceModel> turbulence
65 (
67  (
68  rho,
69  U,
70  phi,
71  thermo
72  )
73 );
74 
75 mesh.setFluxRequired(p.name());
76 
77 Info<< "Creating field dpdt\n" << endl;
79 (
80  IOobject
81  (
82  "dpdt",
83  runTime.timeName(),
84  mesh
85  ),
86  mesh,
87  dimensionedScalar("dpdt", p.dimensions()/dimTime, 0)
88 );
89 
90 Info<< "Creating field kinetic energy K\n" << endl;
91 volScalarField K("K", 0.5*magSqr(U));
92 
93 #include "createMRF.H"
autoPtr< compressible::turbulenceModel > turbulence
Definition: createFields.H:23
surfaceScalarField & phi
PtrList< dimensionedScalar > rhoMax(fluidRegions.size())
PtrList< dimensionedScalar > rhoMin(fluidRegions.size())
const dictionary & pimple
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:253
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:55
CGAL::Exact_predicates_exact_constructions_kernel K
const word & executable() const
Name of executable without the path.
Definition: argListI.H:30
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh >> &tdf1, const word &name, const dimensionSet &dimensions)
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:52
rho
Definition: createFields.H:81
dynamicFvMesh & mesh
volVectorField U(IOobject("U", runTime.timeName(), runTime, IOobject::NO_READ, IOobject::NO_WRITE), mesh, dimensionedVector("zero", dimVelocity, Zero))
volScalarField & dpdt
dimensioned< scalar > magSqr(const dimensioned< Type > &)
const dimensionSet dimDensity
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
const dimensionSet dimTime(0, 0, 1, 0, 0, 0, 0)
Definition: dimensionSets.H:51
messageStream Info
Info<< "Reading thermophysical properties\n"<< endl;autoPtr< psiThermo > pThermo(psiThermo::New(mesh))
Foam::argList args(argc, argv)
Creates and initialises the face-flux field phi.