Fixing indentation in applications/solvers/solidMechanics
[foam-extend-3.2.git] / applications / solvers / multiphase / settlingFoam / wallViscosity.H
blob665d4bbf74bca783cb38080d2bfc2474a982b511
2     scalar Cmu25 = ::pow(Cmu, 0.25);
4     const fvPatchList& patches = mesh.boundary();
6     forAll(patches, patchi)
7     {
8         const fvPatch& curPatch = patches[patchi];
10         if (isType<wallFvPatch>(curPatch))
11         {
12             const scalarField& rhow = rho.boundaryField()[patchi];
14             const scalarField muw = mul.boundaryField()[patchi];
15             scalarField& mutw = mut.boundaryField()[patchi];
17             forAll(curPatch, facei)
18             {
19                 label faceCelli = curPatch.faceCells()[facei];
21                 scalar yPlus =
22                     Cmu25*y[patchi][facei]*::sqrt(k[faceCelli])
23                    /(muw[facei]/rhow[facei]);
25                 if (yPlus > 11.6)
26                 {
27                     mutw[facei] =
28                         muw[facei]
29                        *(yPlus*kappa/::log(E*yPlus) - 1);
30                 }
31                 else
32                 {
33                     mutw[facei] = 0.0;
34                 }
35             }
36         }
37     }