UDF for heat flux in a wall
Hi everybody,
i have a cubic solid element in Fluent. This element is at an initial temperature of 600K. In one of the 6 face of the cube i have to apply a UDF which withdraw heat time by time, depending on the temperature of the face of the cube itself. Is there a way to write that kind of UDF? If yes, how can i do it? |
Ansys FLuent Customization manual, look for DEFINE_PROFILE macro
|
Thank you AlexanderZ for the fast reply.
I would appreciate if you post here an example of heat flux UDF. I didn't find in the customization manual any specific example for heat flux. I tried to do that by the following UDF: Code:
#include "udf.h" Since i don't have yet the real dimensions of the problem i just write a random value for the heat flux. My question is: if i would have the real values for the heat flux, will it run? |
Why don't you just test it??? It takes one minute to test it... Why would you put it here and make other people think about whether it would run or not, when you can just put it in your computer and make sure if it runs?
|
I agree here with Pakk, you do better try to run it next time
but this code is correct |
I'm sorry, it was not my intention to be a loss of time.
I tried the code before asking the question and it gave me bad results, so i just wanted to understand whether the problem is about either the dimension of the HF or the code for the udf. AlexanderZ answered to my question. Anyway thank you both |
Quote:
Anyway: the fact that you had already tried your code and got bad results is very relevant information, that you probably should have added when you asked the question. |
next time i'll do it, thank for suggestions Pakk
|
All times are GMT -4. The time now is 04:49. |