# Temperature profile UDF for 3D cylinder surface

 User Name Remember Me Password
 Register Blogs Members List Search Today's Posts Mark Forums Read

 LinkBack Thread Tools Search this Thread Display Modes
 June 5, 2015, 13:17 Temperature profile UDF for 3D cylinder surface #1 New Member   Himel Barua Join Date: Aug 2014 Posts: 2 Rep Power: 0 Hi, I am trying to incorporate a temperature profile on a surface of a 3D cylidner. I have been using this code. But, when i tried to interprete the code it starts to say undeclared variable. I have some idea to write UDF for 2D case where the boundary is a line, But for 3D case where the boundary is surface i am not very sure. Can anyone please help me in this regard? I am giving the code here. #include "udf.h" DEFINE_PROFILE(temperature_prof,thread,index) { real x[ND_ND]; real y; face_t f; begin _f_loop (f, thread) { F_centroid(x,f,thread); y=x[0]; F_PROFILE(f,thread,index)=-11497.5*y*y-659.781*y+1350; } end_f_loop(f,thread) } I am confused about particularly the red line, for 2D surface sholud the x should be 1D or 2D array ?

 June 16, 2015, 11:59 UDF for Imposing Heat Transfer Coefficient as a function of temperature on a line #2 New Member   Joseph Thodiyil Join Date: Jun 2015 Posts: 2 Rep Power: 0 Hi, I am new to UDF's. I am trying to impose a Convection heat transfer coefficient on a line on the OD of the pipe (in a pipeline 2D axisymmetric model), as function of the surface temperature. This is my attempt. Please provide your comments. /*---------------------------------------------------------------------------------------- heffupstream_rev.c UDF for specifying steady-state external CHTC, heff on a line as a function of Surface Temperature, Ts in a 2D axisymmetric CFD model: heff(Ts) = beta1*exp(beta2*Ts) + beta3 Temperature Ts is in Kelvins. /*---------------------------------------------------------------------------------------*/ #include "udf.h" #define beta1 8.83421; /* W/m^2.K */ #define beta2 1.45536e-3; /* 1/K */ #define beta3 -5.25737; /* W/m^2.K */ /* t is a pointer to the face's thread */ DEFINE_PROFILE(heff_upstream, c, t) { /* Variable Declarations */ real Ts = C_T(c,t); /* Ts is in Kelvins & C_T is the Cell Temperature variable Macro */ face_t f; /* f is a face thread index */ begin_f_loop(f,t) { F_PROFILE(f, t) = beta1 * exp(beta2*Ts) + beta3; } end_f_loop(f, t) }

 Tags fluent, temperature profile, udf

 Thread Tools Search this Thread Search this Thread: Advanced Search Display Modes Linear Mode

 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 OffTrackbacks are Off Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post [openSmoke] libOpenSMOKE Tobi OpenFOAM Community Contributions 554 July 12, 2021 11:22 Reivax Fluent UDF and Scheme Programming 5 April 7, 2015 23:54 ahvz Fluent UDF and Scheme Programming 4 July 23, 2013 08:55 [snappyHexMesh] Layers don't fully surround surface EVBUCF OpenFOAM Meshing & Mesh Conversion 14 August 20, 2012 05:31 shikamaru Fluent UDF and Scheme Programming 1 May 18, 2012 22:19

All times are GMT -4. The time now is 13:33.

 Contact Us - CFD Online - Privacy Statement - Top