# Modify SST kw model in CFX

 User Name Remember Me Password
 Register Blogs Members List Search Today's Posts Mark Forums Read

 LinkBack Thread Tools Search this Thread Display Modes
 May 10, 2017, 08:25 Modify SST kw model in CFX #1 Member   Tingyun YIN Join Date: Apr 2017 Posts: 31 Rep Power: 9 Hi everyone, In CFX, The turbulent eddy viscosity μt in SST kw is given as: 1.png Now, I'm going to modify density and implement it with CEL language: LIBRARY: CEL: &replace EXPRESSIONS: modifySST = fn*Water.ke/ (Water.tef *coefficiency) coefficiency = max(1,sstrnr*F2/(0.31*Water.tef)) F2 = tanh(arg^2) arg = max(2*sqrt(Water.ke)/(0.09*Water.tef*Wall Distance ),500*kinetic viscosity/(Wall Distance^2*Water.tef) ) kinetic viscosity = Water.Dynamic Viscosity/Water.Density fn = Vapour.Density+(mixdensity-Vapour.Density)^10 / (Water.Density-Vapour.Density)^9 mixdensity = Water.Volume Fraction*Water.Density+Vapour.Volume Fraction*Vapour.Density END END END When Slover run, a problem occured: +--------------------------------------------------------------------+ | PROBLEM ENCOUNTERED WHEN EXECUTING CFX EXPRESSION LANGUAGE | | | | The CFX expression language was evaluating: | | Eddy Viscosity | | | | The problem was: | | DIVIDE-BY-ZERO | | | | FURTHER INFORMATION | | | | The problem was encountered in executing the expression for: | | arg | | The complete expression is: | | max(2*sqrt(Fluid 1.ke)/(0.09*Fluid 1.tef*Wall Distance ),500*ki \| | netic viscosity/( | | The error occurs on sub-expression: | | 2*sqrt(Fluid 1.ke)/(0.09*Fluid 1.tef*Wall Distance ) | | | | BACKGROUND INFORMATION | | | | The error was detected at one location. The same problem may be | | present at other locations - that has not been investigated. | | The following values are for the first location which has the | | problem. | | | | These values were set before reaching the current expression: | | | | Name = Expression = Value | | | | kinetic viscosity = Fluid 1.Dynamic Viscosity/F= 9.230000E-07 | | sstrnr = 11.4584 | | Wall Distance = 0.00000 | | Fluid 2.Volume Fr... = 1.000000E-15 | | Fluid 2.Density = 2.308000E-02 | | Fluid 1.tef = 258.753 | | Fluid 1.ke = 5.973506E-05 | | Fluid 1.Volume Fr... = 1.00000 | | Fluid 1.Dynamic V... = 9.211540E-04 | | Fluid 1.Density = 998.000 | | | | END OF DIAGNOSTIC OUTPUT FOR CFX EXPRESSION LANGUAGE | +--------------------------------------------------------------------+ +--------------------------------------------------------------------+ | PROBLEM ENCOUNTERED WHEN EXECUTING CFX EXPRESSION LANGUAGE | | | | The CFX expression language was evaluating: | | Eddy Viscosity | | | | The problem was: | | DIVIDE-BY-ZERO | | | | FURTHER INFORMATION | | | | The problem was encountered in executing the expression for: | | arg | | The complete expression is: | | max(2*sqrt(Fluid 1.ke)/(0.09*Fluid 1.tef*Wall Distance ),500*ki \| | netic viscosity/( | | The error occurs on sub-expression: | | 2*sqrt(Fluid 1.ke)/(0.09*Fluid 1.tef*Wall Distance ) | | | | BACKGROUND INFORMATION | | | | The error was detected at one location. The same problem may be | | present at other locations - that has not been investigated. | | The following values are for the first location which has the | | problem. | | | | These values were set before reaching the current expression: | | | | Name = Expression = Value | | | | kinetic viscosity = Fluid 1.Dynamic Viscosity/F= 9.230000E-07 | | sstrnr = 4.21159 | | Wall Distance = 0.00000 | | Fluid 2.Volume Fr... = 1.000000E-15 | | Fluid 2.Density = 2.308000E-02 | | Fluid 1.tef = 309.657 | | Fluid 1.ke = 7.026244E-05 | | Fluid 1.Volume Fr... = 1.00000 | | Fluid 1.Dynamic V... = 9.211540E-04 | | Fluid 1.Density = 998.000 | | | | END OF DIAGNOSTIC OUTPUT FOR CFX EXPRESSION LANGUAGE | +--------------------------------------------------------------------+ Any courtesies extended to me will be greatly appreciated. Thanks.

 May 10, 2017, 08:56 #2 Senior Member   Join Date: Jun 2009 Posts: 1,825 Rep Power: 33 The value for Wall Distance is 0; therefore, denominator is 0, and the division cannot be completed.

May 10, 2017, 20:31
#3
Member

Tingyun YIN
Join Date: Apr 2017
Posts: 31
Rep Power: 9
Quote:
 Originally Posted by Opaque The value for Wall Distance is 0; therefore, denominator is 0, and the division cannot be completed.
Hi Opaque,

Thank you for your reply.

In CFX, Definition of Wall Distance might not be same with meaning of y in F2 expression. Here:

F2 = tanh(arg^2)
arg = max(2*sqrt(Water.ke)/(0.09*Water.tef*Wall Distance ),500*kinetic viscosity/(Wall Distance^2*Water.tef) )

So, cloud you offer the correct the CEL expression or references for guidance?

Thanks.

 May 11, 2017, 00:58 #4 Super Moderator   Glenn Horrocks Join Date: Mar 2009 Location: Sydney, Australia Posts: 17,749 Rep Power: 143 Your function does not appear to be defined at the wall as you divide by Wall distance regardless of which argument the max() function ends up using. This means your equation falls apart at the wall. You will need to recast your function so it evaluates properly at the wall. It is not a problem with CEL, the problem is with the fundamental function you are trying to use.

May 11, 2017, 08:37
#5
Member

Tingyun YIN
Join Date: Apr 2017
Posts: 31
Rep Power: 9
Quote:
 Originally Posted by ghorrocks Your function does not appear to be defined at the wall as you divide by Wall distance regardless of which argument the max() function ends up using. This means your equation falls apart at the wall. You will need to recast your function so it evaluates properly at the wall. It is not a problem with CEL, the problem is with the fundamental function you are trying to use.
Hi ghorrocks,

Thank you for your reply. I get your point but how to evaluate properly at the wall in CFX?

In other words, how to express y (the distance from the field point to the nearest wall) in CFX? Is it correct?

Thanks.

May 11, 2017, 19:03
#6
Super Moderator

Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,749
Rep Power: 143
Quote:
 I get your point but how to evaluate properly at the wall in CFX?
Your function is not valid at the wall. Dream up a modification of the function so it is valid at the wall. For instance some models use wall functions to handle situations like this.

Quote:
 how to express y
The Wall Distance variable is correct.

May 12, 2017, 06:44
#7
Member

Tingyun YIN
Join Date: Apr 2017
Posts: 31
Rep Power: 9
Quote:
 Originally Posted by ghorrocks Your function is not valid at the wall. Dream up a modification of the function so it is valid at the wall. For instance some models use wall functions to handle situations like this. The Wall Distance variable is correct.

Yeah, I see.

Thanks a lot.

Sent from my iPhone using CFD Online Forum mobile app

 Tags cfx, sst k-w

 Thread Tools Search this Thread Search this Thread: Advanced Search Display Modes Linear Mode

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts BB code is On Smilies are On [IMG] code is On HTML code is OffTrackbacks are Off Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post Sanyo CFX 17 August 15, 2015 06:20 drsidd10 CFX 2 January 18, 2015 05:38 behest FLUENT 0 December 26, 2014 08:14 rockzh CFX 11 February 10, 2012 20:36 RossFS ANSYS Meshing & Geometry 4 November 10, 2011 02:38

All times are GMT -4. The time now is 11:36.

 Contact Us - CFD Online - Privacy Statement - Top