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

piecewise functions in UDFs

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 16, 2009, 09:28
Default piecewise functions in UDFs
  #1
Member
 
Buddy
Join Date: Mar 2009
Location: P.R.C.
Posts: 30
Rep Power: 17
zjbwow is on a distinguished road
hi there

I want to load on the boundary a changing pressure which described by a piecewise function in the UDFs.


question is:how?


#include "udf.h"
DEFINE_PROFILE(unsteady_outlet, thread, position)
{
face_t f;
begin_f_loop(f, thread)
{
real t = RP_Get_Real("flow-time");
F_PROFILE(f, thread, position) =5.0e6*sin(10.*t);
}
end_f_loop(f, thread)
}


through the codes I can see how to set a continous formula but a piecewise function......no.

help,please.
zjbwow is offline   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
Unsteady and Flux UDFs for UDSs tom FLUENT 0 February 13, 2009 10:27
When I use the wall functions....! maximus Main CFD Forum 7 January 20, 2003 09:35
User-Defined Functions Boisson FLUENT 2 January 18, 2002 22:09
N-S equations:divergence free functions? D. Puigjaner Main CFD Forum 1 July 27, 2000 12:43
Experimental Repository for UDFs, Journal Files and Scheme Scripts Jonas Larsson FLUENT 0 March 5, 2000 15:36


All times are GMT -4. The time now is 19:12.