initial commit for version 1.6.x patch release
[OpenFOAM-1.6.x.git] / applications / solvers / heatTransfer / buoyantBoussinesqPisoFoam / createFields.H
blobdde0e38b339348ac1693d4bfdf3da9889610a354
1     Info<< "Reading thermophysical properties\n" << endl;
3     Info<< "Reading field T\n" << endl;
4     volScalarField T
5     (
6         IOobject
7         (
8             "T",
9             runTime.timeName(),
10             mesh,
11             IOobject::MUST_READ,
12             IOobject::AUTO_WRITE
13         ),
14         mesh
15     );
17     Info<< "Reading field p\n" << endl;
18     volScalarField p
19     (
20         IOobject
21         (
22             "p",
23             runTime.timeName(),
24             mesh,
25             IOobject::MUST_READ,
26             IOobject::AUTO_WRITE
27         ),
28         mesh
29     );
31     Info<< "Reading field U\n" << endl;
32     volVectorField U
33     (
34         IOobject
35         (
36             "U",
37             runTime.timeName(),
38             mesh,
39             IOobject::MUST_READ,
40             IOobject::AUTO_WRITE
41         ),
42         mesh
43     );
45 #   include "createPhi.H"
47 #   include "readTransportProperties.H"
49     Info<< "Creating turbulence model\n" << endl;
50     autoPtr<incompressible::RASModel> turbulence
51     (
52         incompressible::RASModel::New(U, phi, laminarTransport)
53     );
55     label pRefCell = 0;
56     scalar pRefValue = 0.0;
57     setRefCell
58     (
59         p,
60         mesh.solutionDict().subDict("PISO"),
61         pRefCell,
62         pRefValue
63     );
66     // Kinematic density for buoyancy force
67     volScalarField rhok
68     (
69         IOobject
70         (
71             "rhok",
72             runTime.timeName(),
73             mesh
74         ),
75         1.0 - beta*(T - TRef)
76     );