CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

UDF temperature variation

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 5, 2008, 08:38
Default UDF temperature variation
  #1
Alex E-H
Guest
 
Posts: n/a
hi. i am attempting to simulate a sinusoidally varying temperature velocity inlet and the following is my udf:

#include "udf.h"

DEFINE_PROFILE(unsteady_temp,thread,index) { face_t f; real T; real t = CURRENT_TIME;

begin_f_loop(f,thread) /* loops over all faces in the thread passed in the macro argument */ { F_PROFILE(f,thread,index) = 10.0 *sin(t*(3.14159/720) /* here stands the profile function as a function of time */ } end_f_loop(f,thread) }

When interpreting in Fluent I am getting the message:

Error: U:\4th_yr\FYP\2nd\Unsteady\unsteady_temperature.c: line 12: parse error.

Can anybody help me with this please?

Alex
  Reply With Quote

Old   November 5, 2008, 09:03
Default Re: UDF temperature variation
  #2
Alex E-H
Guest
 
Posts: n/a
sorry i have modified i think this should work but still doesnt:

#include "udf.h" DEFINE_PROFILE(unsteady_temperature, thread, position) { face_t f; real t = CURRENT_TIME;

begin_f_loop(f, thread) { F_PROFILE(f, thread, position) = 10.*sin((3.14159/720)*t) /* here stands the profile function as a function of time */ } end_f_loop(f, thread) }

parse error on line 10?

Alex
  Reply With Quote

Old   November 5, 2008, 09:18
Default Re: UDF temperature variation
  #3
Alex E-H
Guest
 
Posts: n/a
please do not worry to reply to this i have figured it out

alex
  Reply With Quote

Reply


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
UDF temperature variation Alex E-H FLUENT 3 February 19, 2017 14:55
Pressure temperature variation Dev CFX 0 June 21, 2007 23:01
Viscosity variation with temperature for gases- Kedar Main CFD Forum 3 October 24, 2005 06:43
variation of surface tension with temperature Markus FLUENT 1 July 17, 2002 20:23
Property variation with temperature G.Balakrishnan FLUENT 1 December 16, 2000 06:51


All times are GMT -4. The time now is 15:50.