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