1 Info<< "Reading field U\n" << endl;
16 Info<< "Creating face flux\n" << endl;
17 surfaceScalarField phi
28 dimensionedScalar("zero", mesh.Sf().dimensions()*U.dimensions(), 0.0)
32 singlePhaseTransportModel laminarTransport(U, phi);
34 autoPtr<incompressible::RASModel> turbulence
36 incompressible::RASModel::New(U, phi, laminarTransport)
40 IOdictionary transportProperties
44 "transportProperties",
52 dimensionedVector Ubar
54 transportProperties.lookup("Ubar")
57 vector flowDirection = (Ubar/mag(Ubar)).value();
58 tensor flowMask = sqr(flowDirection);
61 // Search for wall patches faces and store normals
64 vector wallNormal(vector::zero);
66 const fvPatchList& patches = mesh.boundary();
68 forAll(patches, patchi)
70 const fvPatch& currPatch = patches[patchi];
72 if (isA<wallFvPatch>(currPatch))
74 forAll(currPatch, facei)
81 - mesh.Sf().boundaryField()[patchi][facei]
82 /mesh.magSf().boundaryField()[patchi][facei];
84 else if (nWallFaces == 2)
87 mesh.Sf().boundaryField()[patchi][facei]
88 /mesh.magSf().boundaryField()[patchi][facei];
90 //- Check that wall faces are parallel
93 mag(wallNormal & wallNormal2) > 1.01
94 ||mag(wallNormal & wallNormal2) < 0.99
97 Info<< "boundaryFoam: wall faces are not parallel"
104 Info<< "boundaryFoam: number of wall faces > 2"
106 << abort(FatalError);
113 //- create position array for graph generation
114 scalarField y = wallNormal & mesh.C().internalField();
117 dimensionedVector gradP
120 dimensionSet(0, 1, -2, 0, 0),