CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   helping about udf (https://www.cfd-online.com/Forums/fluent/85662-helping-about-udf.html)

sadegh1080 March 3, 2011 14:10

helping about udf
 
Hi friends,

I have a model that rotate about x axis through passing air flow on it.(free roll)

I have written an udf for this model but I don't know that is correct or not.

please help me.

udf is :

#include "udf.h"
static real wx = 0.0;
static real Mx=10;
static real dwx;
real NV_VEC(omega);
real Ix=10;
DEFINE_SDOF_PROPERTIES(missile, prop, dt, time, dtime)
{
prop[SDOF_MASS] = 50;
prop[SDOF_IXX] = Ix;
prop[SDOF_LOAD_M_X] += Mx;
dwx = dtime * Mx / Ix;
wx +=dwx;
NV_D(omega,=,wx,0,0);
//omega[0]= wx;
}


All times are GMT -4. The time now is 22:31.