CFD Online URL
[Sponsors]
Home > Forums > Fluent UDF and Scheme Programming

Probleme to interpret 3D temperature profil UDF

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   January 16, 2012, 10:23
Default Probleme to interpret 3D temperature profil UDF
  #1
New Member
 
christophe REHMET
Join Date: Jan 2012
Posts: 5
Rep Power: 4
christophe06 is on a distinguished road
Hi,

I have defined a UDF for 3D Inlet temperature profil and it doesn't works anymore after a crash of fluent. My profil has become flat and I couldn't have good interpretation of all my UDF know. It's really a bad point because I need to give a report about these CFD results this week. I have writing the temperature profil as followed:

#include "udf.h"
"define domain_ID 2 //

enum{OC, NUM_OF_USED_UDM};

DEFINE_PROFILE(inlet_temp, t, i)
{
real x[ND_ND];
real r;
face_t f;
real Diameter = 6.e-2;
real T_max = 5.e3;
real T_max = 3.e2;
begin_f_loop(f, t)
{
F_CENTROID(x,f,t);
y = x[1];
z = x[2];
r = sqrt(pow(y,2)+pow(z,2));
F_PROFILE(f, t, i) = (T_max-T_paroi)*(1-pow(2.0*r/Diameter,2))+T_paroi;
}
end_f_loop(f, thread)
}
christophe06 is offline   Reply With Quote

Old   January 16, 2012, 11:58
Default
  #2
New Member
 
christophe REHMET
Join Date: Jan 2012
Posts: 5
Rep Power: 4
christophe06 is on a distinguished road
I find the solution, I just restarted from the beginning,it was fun
christophe06 is offline   Reply With Quote

Old   February 19, 2012, 16:08
Default Adapt UDF
  #3
New Member
 
PB
Join Date: Jan 2012
Location: UK
Posts: 6
Rep Power: 4
Aerogirl is on a distinguished road
Hi there,
I want to do the exact same UDF as you but my inlet is rectangular shaped and I was wondering if you could explain how to adapt your code to fit non-cylindrical coordinates? I am trying to model a hot spot temperature on the inlet of a gas turbine duct.

Your help would be much appreciated.
Kind Regards
AeroGirl
Aerogirl is offline   Reply With Quote

Old   February 20, 2012, 05:49
Default
  #4
New Member
 
christophe REHMET
Join Date: Jan 2012
Posts: 5
Rep Power: 4
christophe06 is on a distinguished road
Hi,

I think that you can define your profil along one direction, for example X and add other condition on Y.

#include "udf.h"
"define domain_ID 2 //

enum{OC, NUM_OF_USED_UDM};
DEFINE_PROFILE(inlet_x_temperature, thread, position)
{

real x[ND_ND];

real r;

face_t f;

real lenght = 6.e-2;

real T_max = 5.e3;

real T_max = 3.e2;

begin_f_loop(f, t)

{

F_CENTROID(x,f,t);

x = x[0];

F_PROFILE(f, t, i) = (T_max-T_paroi)*(1-pow(2.0*x/Diameter,2))+T_paroi;

}

end_f_loop(f, thread)

}
DEFINE_PROFILE(inlet_y_temperature, thread, position)
{

real x[ND_ND];

real r;

face_t f;

real lenght2 = 2.e-2;

real T_max = 5.e3;

real T_max = 3.e2;

begin_f_loop(f, t)

{

F_CENTROID(y,f,t);

y = x[1];

F_PROFILE(f, t, i) = (T_max-T_paroi)*(1-pow(2.0*y/Diameter,2))+T_paroi;

}

end_f_loop(f, thread)

}
Maybe this script will be ok.
christophe06 is offline   Reply With Quote

Old   February 20, 2012, 09:06
Default Thanks!
  #5
New Member
 
PB
Join Date: Jan 2012
Location: UK
Posts: 6
Rep Power: 4
Aerogirl is on a distinguished road
Thankyou I will give this a try and see how I get on!
Aerogirl is offline   Reply With Quote

Reply

Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Please Help! Temperature profile UDF for 3D geometry subhankar_bhandari FLUENT 2 April 16, 2011 06:30
Please Help! Temperature profile UDF for 3D geometry subhankar_bhandari FLUENT 0 August 16, 2010 09:40
UDF or any approach for Bulk Temperature calculation vemps FLUENT 0 May 1, 2009 02:09
Interpret three UDF for property Atsu FLUENT 4 April 22, 2006 16:04
UDF: temperature profile dolores FLUENT 5 March 30, 2004 05:53


All times are GMT -4. The time now is 05:25.