FreeFOAM The Cross-Platform CFD Toolkit
createFields.H
Go to the documentation of this file.
1  Info<< "Reading thermophysical properties\n" << endl;
2 
3  autoPtr<basicPsiThermo> pThermo
4  (
5  basicPsiThermo::New(mesh)
6  );
7  basicPsiThermo& thermo = pThermo();
8 
10  (
11  IOobject
12  (
13  "rho",
14  runTime.timeName(),
15  mesh,
16  IOobject::READ_IF_PRESENT,
17  IOobject::AUTO_WRITE
18  ),
19  thermo.rho()
20  );
21 
22  volScalarField& p = thermo.p();
23  volScalarField& h = thermo.h();
24  const volScalarField& psi = thermo.psi();
25 
26  Info<< "Reading field U\n" << endl;
28  (
29  IOobject
30  (
31  "U",
32  runTime.timeName(),
33  mesh,
34  IOobject::MUST_READ,
35  IOobject::AUTO_WRITE
36  ),
37  mesh
38  );
39 
41 
42 
43  label pRefCell = 0;
44  scalar pRefValue = 0.0;
45  setRefCell(p, mesh.solutionDict().subDict("SIMPLE"), pRefCell, pRefValue);
46 
48  (
49  mesh.solutionDict().subDict("SIMPLE").lookup("rhoMax")
50  );
51 
53  (
54  mesh.solutionDict().subDict("SIMPLE").lookup("rhoMin")
55  );
56 
57  Info<< "Creating turbulence model\n" << endl;
58  autoPtr<compressible::RASModel> turbulence
59  (
60  compressible::RASModel::New
61  (
62  rho,
63  U,
64  phi,
65  thermo
66  )
67  );
68 
70 
71 // ************************ vim: set sw=4 sts=4 et: ************************ //