Repository navigation
Expand file tree
/
Copy pathcreateFields_OpenFOAM_programming_command.H
More file actions
112 lines (83 loc) · 1.87 KB
/
Copy pathcreateFields_OpenFOAM_programming_command.H
File metadata and controls
112 lines (83 loc) · 1.87 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
/*IOobject wallShearStressMag(
"wallShearStressMag",
runTime.timeName(),
mesh,
IOobject::NO_READ,
IOobject::NO_WRITE // No need to write during the simulation, as we'll write it once outside the loop
);
IOobject u_star_1(
"u_star_1",
runTime.timeName(),
mesh,
IOobject::NO_READ,
IOobject::NO_WRITE
);*/
/*Info<< "Creating field u_star\n" << endl;
volVectorField u_star
(
IOobject
(
"u_star",
runTime.timeName(),
mesh,
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
mesh
);
*/
//------------- this part is not needed ----------------------
Info<< "Reading field U\n" << endl;
volVectorField U
(
IOobject
(
"U",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mesh
);
//---------------------------------------------------------------*/
/*------- reading wallShearStress ---------------------------*/
Info<< "Reading field wallShearStress\n" << endl;
volVectorField wallShearStress
(
IOobject
(
"wallShearStress",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::NO_WRITE //AUTO_WRITE
),
mesh
);
/*------- End reading wallShearStress ---------------------------*/
Info<< "Reading physicalProperties\n" << endl;
IOdictionary physicalProperties
(
IOobject
(
"physicalProperties",
runTime.constant(),
mesh,
IOobject::MUST_READ_IF_MODIFIED,
IOobject::NO_WRITE
)
);
Info<< "Reading diffusivity rho\n" << endl;
dimensionedScalar rho
(
physicalProperties.lookup("rho")
);
Info<< "Reading diffusivity gravity_mag\n" << endl;
dimensionedScalar gravity_mag
(
physicalProperties.lookup("gravity_mag")
);
// #include "createPhi.H"
// #include "createFvModels.H"
// #include "createFvConstraints.H"