|
[Sponsors] |
UDF For my 2D - Axisymmetric CHT rotating model |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
February 21, 2020, 05:03 |
UDF For my 2D - Axisymmetric CHT rotating model
|
#1 |
New Member
James Adams
Join Date: Feb 2020
Posts: 3
Rep Power: 6 |
Hi,
First time posting. ANSYS rookie. Ive set up a CHT 2D axisymmetric model. I need to set up a UDF to simulate an engine slam acceleration. My UDF does not seem to be working and I have no idea, why. I suspect I'm either calling the wrong type of macro or my syntax is wrong (never used C in my life). I have interpreted this macro and I have called it in the cell zone conditions for my rotor and in the interface boundary conditions. |
|
February 21, 2020, 06:37 |
Required motion
|
#2 |
Senior Member
|
Omega is not a scalar. So, its value cannot be set the way you have in the UDF.
In a 2D case, rotation is allowed only about z-axis. If that's what you need, you do not require a UDF. Just open the cell zone conditions panel and apply the rotational speed. Ensure that the center of cell zone is given correctly. If you want to give a speed that depends on time, then you can use a profile. Profile is much simpler and easier than a UDF.
__________________
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. |
|
February 24, 2020, 10:24 |
Solved
|
#3 |
New Member
James Adams
Join Date: Feb 2020
Posts: 3
Rep Power: 6 |
Hi,
Thanks for your suggestion. Because I need to create much more complicated rotational profiles dependednt on time, I was insistent in using a macro. After a few hours of trial and error I managed to write a UDF that worked. |
|
February 24, 2020, 10:36 |
Profile for zone motion
|
#4 |
Senior Member
|
This is a profile UDF and not meant for making a zone move. Furthermore, zones are cell zones if you are using moving mesh or MRF. If you are modeling a moving wall, then this will work. Otherwise, use DEFINE_ZONE_MOTION, just like you had in your original code. You need to modify that as follows
DEFINE_ZONE_MOTION(...) { if(time > 200) *omega = 2000; else if (time <=200 && time > 100) *omega = 9000; else *omega = 2000; }
__________________
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. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
UDF problem for Population balance model | Amir.11 | Fluent UDF and Scheme Programming | 6 | May 30, 2022 04:36 |
Modified k-e turbulence model UDF | Travis | Fluent UDF and Scheme Programming | 7 | November 11, 2018 20:21 |
Using UDF for shaking / rotating mesh | MandatoryMadness | FLUENT | 0 | October 11, 2018 12:13 |
generate the 3D model from this 2D axisymmetric model | mlooti | FLUENT | 2 | June 11, 2018 08:26 |
Axisymmetric model | Satish Perivilli | FLUENT | 2 | May 9, 2006 10:02 |