CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

How to define multipy conditions in Fluent named expression?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 24, 2020, 18:22
Default How to define multipy conditions in Fluent named expression?
  #1
New Member
 
Oscar Shen
Join Date: Jan 2020
Posts: 4
Rep Power: 6
Scar123111 is on a distinguished road
Hi,
I know how to use basic conditional function for single conditon in Fluent, for exemple: IF(x>0,1,0). However, I don't know how to define multiple conditions. For exemple, I want IF(x>0 && y>0 && z>0,1,0) but "&&" doesn't work in Fluent expression language. Do you guys have an idea about how to solve that? Does anyone know how "AND" , "OR" and "NOT" function work in Fluent named expression? I can't find any information about these founctions online. Thanks!
Scar123111 is offline   Reply With Quote

Old   February 25, 2020, 03:06
Default Boolean
  #2
Senior Member
 
vinerm's Avatar
 
Vinerm
Join Date: Jun 2009
Location: Nederland
Posts: 2,946
Blog Entries: 1
Rep Power: 36
vinerm will become famous soon enough
In Fluent's expression language, you have to do it like this

AND(expr1, expr2)

Since the output is true or false, IF is not required. You can nest these.
__________________
Regards,
Vinerm

PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority.
vinerm is offline   Reply With Quote

Reply

Tags
expression editor, expressions


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 Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Near wall treatment in k-omega SST Arnoldinho OpenFOAM Running, Solving & CFD 38 March 8, 2017 13:48
How to define parameters for multi periodic boundary conditions in Fluent uuusheng FLUENT 1 October 14, 2014 06:48
Fluent boundary conditions problem bobo FLUENT 2 July 3, 2009 06:28
Missing math.h header Travis FLUENT 4 January 15, 2009 11:48
REAL GAS UDF brian FLUENT 6 September 11, 2006 08:23


All times are GMT -4. The time now is 20:23.