|
[Sponsors] |
April 17, 2009, 05:45 |
UDF: using if
|
#1 |
New Member
Join Date: Apr 2009
Posts: 10
Rep Power: 17 |
dear to all,
i'm trying to use the "if" command in an UDF. when i interpreted the UDF by Fluent, it wrote: "invalid expression type for if: double." the line of the error is the first of this group: if (Tg=0) Kr=0; else { Kr=qrnet/(Tg); } Kr,qrnet,Tg were declared as real. can someone help me? best regards to all |
|
April 17, 2009, 05:56 |
|
#2 |
Member
Join Date: Mar 2009
Posts: 49
Rep Power: 17 |
hi,
I think you is the if-question! you assign 0 to Tg, but I think the boolean expression is supposed to be: if (tg == 0.0) cheers |
|
April 17, 2009, 06:02 |
|
#3 |
New Member
Join Date: Apr 2009
Posts: 10
Rep Power: 17 |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Dynamic Mesh UDF | Qureshi | FLUENT | 7 | March 23, 2017 08:37 |
How to add a UDF to a compiled UDF library | kim | FLUENT | 3 | October 26, 2011 22:38 |
I need UDF help. | S.Whitney | FLUENT | 0 | October 15, 2007 12:29 |
UDF...UDF...UDF...UDF | Luc SEMINEL | FLUENT | 0 | November 25, 2002 05:03 |
UDF, UDF, UDF, UDF | Luc SEMINEL | Main CFD Forum | 0 | November 25, 2002 05:01 |