Merge branch 'master' of ssh://git.code.sf.net/p/foam-extend/foam-extend-3.2
[foam-extend-3.2.git] / tutorials / basic / potentialFoam / cylinder / analyticalCylinder / createFields.H
blob3b8dcd64ed0918b4aa3e5d6f208fd314e898086f
1 Info<< "Reading field U\n" << endl;
2 volVectorField U
4     IOobject
5     (
6         "U",
7         runTime.timeName(),
8         mesh,
9         IOobject::MUST_READ,
10         IOobject::NO_WRITE
11     ),
12     mesh
15 Info<< "Reading inlet velocity  uInfX\n" << endl;
17 dimensionedScalar uInfX
19     "uInfx",
20     dimensionSet(0, 1, -1, 0, 0),
21     U.boundaryField()[3][0].x()
23 Info << "U at inlet = " << uInfX.value() << " m/s" << endl;
25 dimensionedScalar radius
27     "radius",
28     dimensionSet(0, 1, 0, 0, 0),
29     mag(U.mesh().boundary()[4].Cf()[0])
32 Info << "Cylinder radius = " << radius.value() << " m" << endl;
34 volVectorField UA
36     IOobject
37     (
38         "UA",
39         runTime.timeName(),
40         mesh,
41         IOobject::NO_READ,
42         IOobject::AUTO_WRITE
43     ),
44     U