CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Fluent UDF and Scheme Programming

UDF for oscillatory motion

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

Reply
 
LinkBack Thread Tools Display Modes
Old   June 25, 2014, 21:44
Default UDF for oscillatory motion
  #1
NGH
New Member
 
NGH
Join Date: May 2011
Posts: 15
Rep Power: 7
NGH is on a distinguished road
I have write the following UDF and using NACA 0012 as the fish geometry. The UDF compiled without error in Fluent but the foil does not move at all. Im doing a 2D case. What could be the issue? Any advice is greatly appreciated. Thanks

#include "udf.h"
DEFINE_GRID_MOTION(upper,domain,dt,time,dtime)
{
Thread *tf=DT_THREAD(dt);
face_t f;
Node *v;
real amp,omega, delta_y;
amp=0.05;
omega=5;
int n;
SET_DEORMING_THREAD_FLAG(THREAD_T0(tf));
begin_f_loop(f,tf)
{
f_node_loop(f,tf,n)
{
v=F_NODE(f,tf,n);
if(NODE_POS_NEED_UPDATE(v))
{
NODE_POS_UPDATED(v);
delta_y=amp*sin(omega*time);
NODE_Y(v)=NODE_Y(v)+delta_y;
}
}
}
end_f_loop(f,tf);
}
NGH 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
Display Zone motion of a dynamic mesh????Checking my UDF motion Irenedea FLUENT 0 March 20, 2014 03:17
UDF for creating motion to a body using a source file. jayjay Fluent UDF and Scheme Programming 1 August 18, 2012 21:05
UDF to control motion NOT about CG LenDawg0220 Fluent UDF and Scheme Programming 0 July 28, 2012 12:54
UDF: DEFINE_CG_MOTION for vertical jump motion of an electrode! alban Fluent UDF and Scheme Programming 2 June 8, 2010 18:54
UDF error CG Motion Alex FLUENT 0 March 22, 2006 18:40


All times are GMT -4. The time now is 23:39.