Removed unnecessary return statement
[foam-extend-3.2.git] / applications / solvers / compressible / sonicDyMFoam / limitU.H
blobd7eaeb3d9c53e0f2e34fa3f18f16678aa1f425ff
2     // Bound the velocity
3     volScalarField magU = mag(U);
5     if (max(magU) > UMax)
6     {
7         volScalarField Ulimiter =
8             pos(magU - UMax)*UMax/(magU + smallU)
9           + neg(magU - UMax);
11         Ulimiter.max(scalar(0));
12         Ulimiter.min(scalar(1));
14         U *= Ulimiter;
15         U.correctBoundaryConditions();
16     }