pls check this c program
#include "udf.h"
static real v_prev = 0.0; static real A = 0.00009; static real f = 1; DEFINE_CG_MOTION(piston,dt,vel,omega,time,dtime) { /* reset velocities */ NV_S(vel, =, 0.0); NV_S(omega, =, 0.0); if (!Data_Valid_P()) return; /* equation of velocity */ v_prev = 2*3.142*A*f*sin(2*3.142*f*time+3.142/2); /* set x-component of velocity */ vel[0] = v_prev; } can u tell me the mistake in it |
Re: pls check this c program
which 1 do u wont, the 1st or last?????
|
Re: pls check this c program
when i am using this i am getting an an phase error in second line
and also in the equation |
All times are GMT -4. The time now is 12:46. |