Hi,

I want to adapt the coding used within the udf file provided in https://www.youtube.com/watch?v=zttTAcO1S6I

I Want to alter it to make the moving wall function to perform Cyclically (To move back and forth), to create a wave flume simulation.

The UDF coding is as follows,

#include “udf.h” #include “dynamesh_tools.h” DEFINE_CG_MOTION(oscillate,dt,vel,omega,time,dtime ) { Thread *t; face_t f; /* define the variables */ t = DT_THREAD(dt); begin_f_loop(f,t) /* loop over each face in the zone to create an array of data */ { vel[0]=-2; } end_f_loop(f,t) }

I think the problem is with the vel[0]=-2

I want the wall to move back -300mm with a velocity of 0.45 and then return to 0mm with the same velocity. Then this will be the loop for the Boundary Condition.

If anyone experienced with UDF coding and fluent can help me, that would be greatly appreciated.

Thank you,

Ruari Skinner

Liverpool John Moores University

Similar questions and discussions