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

if Statement for multiple UDS not working?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 30, 2020, 14:15
Default if Statement for multiple UDS not working?
  #1
Member
 
Deutschland
Join Date: Jun 2020
Location: https://t.me/pump_upp
Posts: 43
Rep Power: 6
schwaral is on a distinguished road
Send a message via ICQ to schwaral Send a message via AIM to schwaral Send a message via Yahoo to schwaral
Hi, somehow I am unable to use the if statement for my two UDS FLUX I have. Where is my mistake?

I used this form:

Code:
DEFINE_UDS_FLUX(my_uds_flux, f, t, i)
{
if (i==0)
{.....
return flux;
}
}
if (i==1)
{
.....
return flux;
}
}
schwaral is offline   Reply With Quote

Old   November 30, 2020, 22:17
Default
  #2
Senior Member
 
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34
AlexanderZ will become famous soon enoughAlexanderZ will become famous soon enough
are you sure about brackets in your code scheme?

compile udf and read the log
this code should work well in case there are no problems with syntax
__________________
best regards


******************************
press LIKE if this message was helpful
AlexanderZ is offline   Reply With Quote

Reply

Tags
flux, uds, uds_convective_term


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
When to use User-defined Scalar (UDS) for concentration? THC FLUENT 1 May 30, 2019 10:04
Can you explain me how to use UDS? Tleja Fluent UDF and Scheme Programming 0 July 14, 2015 02:52
what "If" condition means in rebound brbbhatti OpenFOAM Programming & Development 0 August 12, 2014 10:18
A good question about UDS Z FLUENT 1 March 31, 2005 16:14
UDS David FLUENT 1 March 21, 2005 12:31


All times are GMT -4. The time now is 22:14.