CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   Custom Field Functions (https://www.cfd-online.com/Forums/fluent/38671-custom-field-functions.html)

bov November 19, 2005 19:28

Custom Field Functions
 
Does anyone know about any peculiarities of the LOG function under the CFF menu?

I try to define the function

cf = 0.08/log(0.06*Rex*F) where F is a constant and Rex is a linear non-zero function of x. When I try to plot the function I get a division by zero error. But I am able to export it. Any suggestions?

lcw November 20, 2005 10:52

Re: Custom Field Functions
 
have a try! cf = 0.08/(log(0.06*F)+logRex)

RoM November 21, 2005 01:36

Re: Custom Field Functions
 
For (0.06*Rex*F)=1 you will get a division by zero.

RoM

bov November 21, 2005 08:13

Re: Custom Field Functions
 
Icw, thank you for your reply. I appreciate your help. I tried entring the formula in the form you specified, but I am getting the same error.

bov November 21, 2005 08:15

Re: Custom Field Functions
 
RoM, thank you for your reply. Could you please explain why that makes sense that this function produces a division by zero error? How do I fix it? The formulation 0.08/(log(ReX)+log(0.06*Fre)) does not resolve the division by zero error. Thanks again.

RoM November 21, 2005 08:31

Re: Custom Field Functions
 
I just wanted to point out that log 1 = 0. I dont know what physical meaning stands behind this singularity in your function. You could use Icw's formulation and define 2 cffs, one for log(ReX) and the other log(0.06*Fre). Plot them and look in which regions of your domain log(ReX)+log(0.06*Fre)=1. Maybe this will help to judge whats going on and if there is any physical meaning behind.

Good Luck, RoM


All times are GMT -4. The time now is 16:33.