From 004d1eb23f62121f3404ad93eab6426f12886ec1 Mon Sep 17 00:00:00 2001 From: mattijs Date: Tue, 14 Jun 2011 10:51:24 +0100 Subject: [PATCH] ENH: RASModel.C: clipping input to log --- src/turbulenceModels/compressible/RAS/RASModel/RASModel.C | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/turbulenceModels/compressible/RAS/RASModel/RASModel.C b/src/turbulenceModels/compressible/RAS/RASModel/RASModel.C index 2a7e6255..ad35e32a 100644 --- a/src/turbulenceModels/compressible/RAS/RASModel/RASModel.C +++ b/src/turbulenceModels/compressible/RAS/RASModel/RASModel.C @@ -165,7 +165,7 @@ scalar RASModel::yPlusLam(const scalar kappa, const scalar E) const for (int i=0; i<10; i++) { - ypl = log(E*ypl)/kappa; + ypl = log(max(E*ypl, 1))/kappa; } return ypl; -- 2.11.4.GIT