diff --git a/applications/utilities/preProcessing/applyBoundaryLayer/applyBoundaryLayer.C b/applications/utilities/preProcessing/applyBoundaryLayer/applyBoundaryLayer.C index 756b92cd494f8a4f2920a45ab259634f5ba0ea74..4c16ae0e541b6fdccd4adaa916ceca13583beef8 100644 --- a/applications/utilities/preProcessing/applyBoundaryLayer/applyBoundaryLayer.C +++ b/applications/utilities/preProcessing/applyBoundaryLayer/applyBoundaryLayer.C @@ -98,12 +98,11 @@ int main(int argc, char *argv[]) // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - Info<< "Time = " << runTime.timeName() << nl << endl; - // Modify velocity by applying a 1/7th power law boundary-layer // u/U0 = (y/ybl)^(1/7) // assumes U0 is the same as the current cell velocity + Info<< "Setting boundary layer velocity" << nl << endl; scalar yblv = ybl.value(); forAll(U, celli) { @@ -117,9 +116,15 @@ int main(int argc, char *argv[]) U.write(); // Update/re-write phi - phi = fvc::interpolate(U) & mesh.Sf(); + #include "createPhi.H" phi.write(); + singlePhaseTransportModel laminarTransport(U, phi); + + autoPtr<incompressible::turbulenceModel> turbulence + ( + incompressible::turbulenceModel::New(U, phi, laminarTransport) + ); if (isA<incompressible::RASModel>(turbulence())) { @@ -153,7 +158,6 @@ int main(int argc, char *argv[]) // Turbulence epsilon - tmp<volScalarField> tepsilon = turbulence->epsilon(); volScalarField& epsilon = tepsilon(); scalar ce0 = ::pow(Cmu, 0.75)/kappa; diff --git a/applications/utilities/preProcessing/applyBoundaryLayer/createFields.H b/applications/utilities/preProcessing/applyBoundaryLayer/createFields.H index 8b4e6565a9cdae4d7ada263101ab48d63f0d63d4..e7d72692fc1f640e0b25c6023d0eaccf729f61b4 100644 --- a/applications/utilities/preProcessing/applyBoundaryLayer/createFields.H +++ b/applications/utilities/preProcessing/applyBoundaryLayer/createFields.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -37,15 +37,6 @@ License mesh ); - #include "createPhi.H" - - singlePhaseTransportModel laminarTransport(U, phi); - - autoPtr<incompressible::turbulenceModel> turbulence - ( - incompressible::turbulenceModel::New(U, phi, laminarTransport) - ); - Info<< "Calculating wall distance field" << endl; volScalarField y(wallDist(mesh).y());