createFields.H
Go to the documentation of this file.
1 Info<< "Reading field h\n" << endl;
3 (
4  IOobject
5  (
6  "h",
7  runTime.timeName(),
8  mesh,
9  IOobject::MUST_READ,
10  IOobject::AUTO_WRITE
11  ),
12  mesh
13 );
14 
15 Info<< "Reading field h0 if present\n" << endl;
17 (
18  IOobject
19  (
20  "h0",
21  runTime.findInstance("polyMesh", "points"),
22  mesh,
23  IOobject::READ_IF_PRESENT
24  ),
25  mesh,
26  dimensionedScalar("h0", dimLength, 0.0)
27 );
28 
29 Info<< "Creating field hU\n" << endl;
31 (
32  IOobject
33  (
34  "hU",
35  runTime.timeName(),
36  mesh,
37  IOobject::MUST_READ,
38  IOobject::AUTO_WRITE
39  ),
40  mesh
41 );
42 
43 Info<< "Reading field U\n" << endl;
45 (
46  IOobject
47  (
48  "U",
49  runTime.timeName(),
50  mesh,
51  IOobject::NO_READ,
52  IOobject::AUTO_WRITE
53  ),
54  hU/h
55 );
56 
57 Info<< "Creating field hTotal for post processing\n" << endl;
58 volScalarField hTotal
59 (
60  IOobject
61  (
62  "hTotal",
63  runTime.timeName(),
64  mesh,
65  IOobject::READ_IF_PRESENT,
66  IOobject::AUTO_WRITE
67  ),
68  h+h0
69 );
70 hTotal.write();
71 
72 #include "createPhi.H"
73 
74 Info<< "Creating Coriolis Force" << endl;
75 const dimensionedVector F("F", ((2.0*Omega) & gHat)*gHat);
76 
77 mesh.setFluxRequired(h.name());
volVectorField U(IOobject( "U", runTime.timeName(), runTime, IOobject::NO_READ, IOobject::NO_WRITE ), mesh, dimensionedVector("zero", dimVelocity, vector::zero), p.boundaryField().types())
Creates and initialises the face-flux field phi.
messageStream Info
dynamicFvMesh & mesh
scalar h0
const dimensionSet dimLength(0, 1, 0, 0, 0, 0, 0)
Definition: dimensionSets.H:50
const volScalarField & h
Planck constant.
Definition: createFields.H:6
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:251
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:52
dimensioned< vector > dimensionedVector
Dimensioned vector obtained from generic dimensioned type.
GeometricField< vector, fvPatchField, volMesh > volVectorField
Definition: volFieldsFwd.H:55
const dimensionedScalar F
Faraday constant: default SI units: [C/mol].
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.