Files
openfoam/applications/solvers/Lagrangian/kinematicParcelFoam/createFields.H
2008-08-26 11:44:42 +01:00

69 lines
1.3 KiB
C

Info<< "Reading thermophysical properties\n" << endl;
autoPtr<basicThermo> thermo
(
basicThermo::New(mesh)
);
volScalarField rho
(
IOobject
(
"rho",
runTime.timeName(),
mesh,
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
thermo->rho()
);
Info<< "\nReading field U\n" << endl;
volVectorField U
(
IOobject
(
"U",
runTime.timeName(),
mesh,
IOobject::MUST_READ,
IOobject::AUTO_WRITE
),
mesh
);
# include "compressibleCreatePhi.H"
Info<< "Creating turbulence model\n" << endl;
autoPtr<compressible::RASModel> turbulence
(
compressible::RASModel::New
(
rho,
U,
phi,
thermo()
)
);
pointMesh pMesh(mesh);
volPointInterpolation vpi(mesh, pMesh);
word kinematicCloudName("kinematicCloud");
if (args.options().found("cloudName"))
{
kinematicCloudName = args.options()["cloudName"];
}
Info<< "Constructing kinematicCloud " << kinematicCloudName << endl;
basicKinematicCloud kinematicCloud
(
kinematicCloudName,
vpi,
rho,
U,
thermo().mu(),
g
);