createFields.H
Go to the documentation of this file.
1 #include "createRDeltaT.H"
2 
3 Info<< "Reading thermophysical properties\n" << endl;
4 
5 autoPtr<fluidThermo> pThermo
6 (
8 );
9 fluidThermo& thermo = pThermo();
10 thermo.validate(args.executable(), "h", "e");
11 
12 volScalarField& p = thermo.p();
13 
15 (
16  IOobject
17  (
18  "rho",
19  runTime.timeName(),
20  mesh,
21  IOobject::READ_IF_PRESENT,
22  IOobject::AUTO_WRITE
23  ),
24  thermo.rho()
25 );
26 
27 Info<< "Reading field U\n" << endl;
29 (
30  IOobject
31  (
32  "U",
33  runTime.timeName(),
34  mesh,
35  IOobject::MUST_READ,
36  IOobject::AUTO_WRITE
37  ),
38  mesh
39 );
40 
41 #include "compressibleCreatePhi.H"
42 
44 (
45  p,
46  rho,
47  pimple.dict(),
48  thermo.incompressible()
49 );
50 
51 mesh.setFluxRequired(p.name());
52 
53 Info<< "Creating turbulence model\n" << endl;
54 autoPtr<compressible::momentumTransportModel> turbulence
55 (
57  (
58  rho,
59  U,
60  phi,
61  thermo
62  )
63 );
64 
65 Info<< "Creating thermophysical transport model\n" << endl;
66 autoPtr<fluidThermophysicalTransportModel> thermophysicalTransport
67 (
69 );
70 
71 Info<< "Creating field dpdt\n" << endl;
73 (
74  IOobject
75  (
76  "dpdt",
77  runTime.timeName(),
78  mesh
79  ),
80  mesh,
81  dimensionedScalar(p.dimensions()/dimTime, 0)
82 );
83 
84 Info<< "Creating field kinetic energy K\n" << endl;
85 volScalarField K("K", 0.5*magSqr(U));
86 
88 
89 #include "createMRF.H"
90 #include "createFvOptions.H"
const word & executable() const
Name of executable without the path.
Definition: argListI.H:36
pimpleNoLoopControl & pimple
engineTime & runTime
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:251
dimensioned< Type > domainIntegrate(const GeometricField< Type, fvPatchField, volMesh > &vf)
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:58
CGAL::Exact_predicates_exact_constructions_kernel K
phi
Definition: pEqn.H:104
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:57
volScalarField & dpdt
rho
Definition: createFields.H:81
dynamicFvMesh & mesh
autoPtr< BasicCompressibleMomentumTransportModel > New(const volScalarField &rho, const volVectorField &U, const surfaceScalarField &phi, const typename BasicCompressibleMomentumTransportModel::transportModel &transport)
pressureControl & pressureControl
dimensioned< scalar > magSqr(const dimensioned< Type > &)
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::momentumTransportModel > turbulence(compressible::momentumTransportModel::New(rho, U, phi, thermo))
Definition: createFields.H:94
Info<< "Reading thermophysical properties\"<< endl;autoPtr< rhoReactionThermo > pThermo(rhoReactionThermo::New(mesh))
Info<< "Creating thermophysical transport model\"<< endl;autoPtr< fluidThermophysicalTransportModel > thermophysicalTransport(fluidThermophysicalTransportModel::New(turbulence(), thermo))
volVectorField U(IOobject("U", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::NO_WRITE), mesh, dimensionedVector(dimVelocity, Zero))
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
Foam::argList args(argc, argv)
Creates and initialises the face-flux field phi.