# UDF show parse error

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

 November 2, 2012, 07:21 UDF show parse error #1 New Member   Kuen-Sheng Yu Join Date: Nov 2012 Posts: 1 Rep Power: 0 hellow! I'm beginer for UDF. I want to take the toqre that obtained from fluent to aaomega=(moment[2]/0.0012), but it shows parse errorr , "Compute_Force_And_Moment" not found (pc=239) and "CX_Message" not found (pc=62). My code is the following: #include"udf.h" DEFINE_CG_MOTION(turbine1,dt,vel,omega,time,dtime) { Thread *t; Domain *d; face_t f; real CG[ND_ND]; real force[2]; real moment[2]; real x; real y; real r; real angle; real aangle; real aomega; real aaomega; Domain *domain= Get_Domain (1); Thread *tf1 = Lookup_Thread (domain, 12); if (!Data_Valid_P()) { Message0("\n\n!!! No data->No mesh motion !!!\n\n"); return; } r=sqrt(x*x+y*y); angle=atan(y/x); if(r>=0.00000001) begin_f_loop(f,t) { omega[2]=(sqrt(vel[0]*vel[0]+vel[1]*vel[1]))/r; aaomega=moment[2]/0.0012; aomega=omega[2]+aaomega*dtime; aangle=angle+aomega*dtime; } end_f_loop(f,t) NV_S (omega, =, 0.0); NV_S (CG, =, 0.0); NV_S (vel, =, 0.0); Compute_Force_And_Moment(d,t,CG,force,moment,TRUE) ; printf(" Force on the rotor=%f\t%f\t%f\n",force[0],force[1],force[2]); printf(" Moment on the rotor=%f\t%f\t%f\n",moment[0],moment[1],moment[2]); } Does anyone help me? please! Last edited by andy0936andy; November 4, 2012 at 21:50.

 November 12, 2012, 04:26 #2 Senior Member   SSL Join Date: Oct 2012 Posts: 226 Rep Power: 8 It may be needed to include "f_wall.h" header file. mm.abdollahzadeh likes this.

 Thread Tools Display Modes Linear Mode

 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 OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post sail OpenFOAM Paraview & paraFoam 9 November 25, 2011 16:46 vivek070176 OpenFOAM Installation 22 June 1, 2010 12:34 allenzhao OpenFOAM Installation 127 January 30, 2009 20:08 ivanyao OpenFOAM Running, Solving & CFD 6 September 5, 2008 20:50 CFD user CFX 3 November 25, 2002 16:16

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