createFields.H
Go to the documentation of this file.
1 #include "createRDeltaT.H"
2 
3 Info<< "Reading thermophysical properties\n" << endl;
4 
5 autoPtr<psiThermo> pThermo
6 (
8 );
9 psiThermo& thermo = pThermo();
10 
11 volScalarField& e = thermo.he();
12 
13 Info<< "Reading field U\n" << endl;
15 (
16  IOobject
17  (
18  "U",
19  runTime.timeName(),
20  mesh,
21  IOobject::MUST_READ,
22  IOobject::AUTO_WRITE
23  ),
24  mesh
25 );
26 
28 (
29  IOobject
30  (
31  "rho",
32  runTime.timeName(),
33  mesh,
34  IOobject::NO_READ,
35  IOobject::AUTO_WRITE
36  ),
37  thermo.rho()
38 );
39 
40 volVectorField rhoU
41 (
42  IOobject
43  (
44  "rhoU",
45  runTime.timeName(),
46  mesh,
47  IOobject::NO_READ,
48  IOobject::NO_WRITE
49  ),
50  rho*U
51 );
52 
54 (
55  IOobject
56  (
57  "rhoE",
58  runTime.timeName(),
59  mesh,
60  IOobject::NO_READ,
61  IOobject::NO_WRITE
62  ),
63  rho*(e + 0.5*magSqr(U))
64 );
65 
67 (
68  IOobject
69  (
70  "pos",
71  runTime.timeName(),
72  mesh
73  ),
74  mesh,
76 );
77 
79 (
80  IOobject
81  (
82  "neg",
83  runTime.timeName(),
84  mesh
85  ),
86  mesh,
88 );
89 
90 surfaceScalarField phi("phi", fvc::flux(rhoU));
91 
92 Info<< "Creating turbulence model\n" << endl;
93 autoPtr<compressible::turbulenceModel> turbulence
94 (
96  (
97  rho,
98  U,
99  phi,
100  thermo
101  )
102 );
Info<< "Reading initial conditions.\"<< endl;IOdictionary initialConditions(IOobject("initialConditions", runTime.constant(), mesh, IOobject::MUST_READ_IF_MODIFIED, IOobject::NO_WRITE));scalar p0=readScalar(initialConditions.lookup("p"));scalar T0=readScalar(initialConditions.lookup("T"));# 24 "/home/ubuntu/OpenFOAM-7/applications/solvers/combustion/chemFoam/createFields.H" 2 Info<< "Reading thermophysical properties\"<< endl;autoPtr< rhoReactionThermo > pThermo(rhoReactionThermo::New(mesh))
surfaceScalarField & phi
volScalarField & rhoE
engineTime & runTime
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:256
Info<< "Reading field U\"<< 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(dimless, 1.0));surfaceScalarField neg(IOobject("neg", runTime.timeName(), mesh), mesh, dimensionedScalar(dimless, -1.0));surfaceScalarField phi("phi", fvc::flux(rhoU));Info<< "Creating turbulence model\"<< endl;autoPtr< compressible::turbulenceModel > turbulence(compressible::turbulenceModel::New(rho, U, phi, thermo))
Definition: createFields.H:94
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:55
dimensionedScalar neg(const dimensionedScalar &ds)
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
dimensionedScalar pos(const dimensionedScalar &ds)
dynamicFvMesh & mesh
dimensioned< scalar > magSqr(const dimensioned< Type > &)
volVectorField U(IOobject("U", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::NO_WRITE), mesh, dimensionedVector(dimVelocity, Zero))
const dimensionSet dimless(0, 0, 0, 0, 0, 0, 0)
Definition: dimensionSets.H:47
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
messageStream Info
tmp< surfaceScalarField > flux(const volVectorField &vvf)
Return the face-flux field obtained from the given volVectorField.
Definition: fvcFlux.C:32
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField