|
[Sponsors] |
Can I assign ID for boundary conditions after FLUENT assigned them automatically? |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
November 30, 2014, 10:35 |
Can I assign ID for boundary conditions after FLUENT assigned them automatically?
|
#1 |
New Member
Zeng Liyue
Join Date: Sep 2014
Posts: 21
Rep Power: 12 |
I am wondering...Can I assign ID for boundary conditions after FLUENT assigned them automatically?..This is important because I have so many UDFs contains IDs. I don't want my UDFs seem a mess...
|
|
December 1, 2014, 11:26 |
|
#2 |
Senior Member
Andrew Kokemoor
Join Date: Aug 2013
Posts: 122
Rep Power: 14 |
As far as I know, there isn't, but I'd be eager to know if there is. What I do is have a scheme macro to get the ID of a zone by name, then pull that into the UDF.
Scheme: (if (not (rp-var-object 'zone-id)) (rp-var-define 'zone-id 0 'integer #f)) (rpsetvar 'zone-id (zone-name->id "zone")) UDF: if (RP_Variable_Exists_P("zone-id")) {zone_id = RP_Get_Integer("zone-id");} The first line of scheme initializes the "zone-id" scheme variable, the second one writes the ID of the zone "zone" to that variable. The UDF line writes the value of the "zone-id" scheme variable to the "zone_id" variable in the UDF. Then you've got the ID of "zone" available for your UDF. You could do this for any number of zones. |
|
December 1, 2014, 18:15 |
|
#3 |
Senior Member
|
You can, but it actually consists in editing case files manually while exposing your cases to error prone modifications. There is no reason to do that on the case files instead of the UDFs.
|
|
December 5, 2014, 03:08 |
|
#4 |
New Member
Zeng Liyue
Join Date: Sep 2014
Posts: 21
Rep Power: 12 |
That's very helpful~~It's very kind of you~~
Actually I found it possible to define the ID number by adding boundary conditions in ICEM(I always define boundary conditions in fluent). But that is too slow compared to the scheme you've provided, since I have to define them every time I build a mesh... Thank you again~ |
|
December 5, 2014, 03:11 |
|
#5 | |
New Member
Zeng Liyue
Join Date: Sep 2014
Posts: 21
Rep Power: 12 |
Quote:
By the way, can you explain a little more about how to do that by editing case files? |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Wind tunnel Boundary Conditions in Fluent | metmet | FLUENT | 6 | October 30, 2019 13:23 |
Automatically start new calculation after the one before is completed? (FLUENT 12.1) | mars21t | FLUENT | 4 | March 27, 2011 10:52 |
Fluent accuracy and boundary conditions | Paolo Lampitella | Main CFD Forum | 0 | June 12, 2008 11:22 |
ICEM --> FLUENT, boundary conditions | Tobias | CFX | 1 | July 9, 2007 11:35 |
Boundary conditions in Fluent 4.5 | Arturo Ortiz | FLUENT | 0 | January 25, 2001 18:52 |