CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > ANSYS > FLUENT > Fluent UDF and Scheme Programming

UDF compilation error

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

LinkBack Thread Tools Display Modes
Old   April 2, 2004, 09:37
Default UDF compilation error
Szabolcs Varga
Posts: n/a
Dear All, I am getting a compilation error of a UDF related (I think)to RP macros. Unfortunatelly I could not find the origin and meening of this error:

Error: G:\fluentwork\trigen\phase3\eforce_szabi.c: line 7: structure reference not implemented

There is almost no documentation on what RP_CELL(&(p->cCell)) and RP_THREAD(&(p->cCell)) are and how to use them correctly. There are a two examples in the fluent manual for the use of these macros, but I could not comile those examples either (4.6.12 Define_DPM_SWITH in the UDF manual). Could you please help me out what the problem might be? I am attaching the UDF below. Szabolcs

#include "udf.h" #include "dpm.h" #include "surf.h"

DEFINE_DPM_BODY_FORCE(force_L_P,p,idir) { cell_t c=RP_CELL(&(p->cCell)); Thread *t=RP_THREAD(&(p->cCell)); real l_force, mp, ex_t, er_t, Elp; real charge_on_p;

int V_x=0, V_r=0, E_x=0, E_r=1, E_magn=2;


charge_on_p= P_DIAM(p)*1.6e-11; /* you have to define real function P_charge() for particle charge*/ ex_t=C_UDMI(c,t,E_x); er_t=C_UDMI(c,t,E_r);

/* user code for x component force (m/s/s) */ if (idir==0) { l_force=ex_t*charge_on_p/mp; /*Fx*/ } /* user code for r component force (m/s/s) */ if (idir==1) { l_force=er_t*charge_on_p/mp; /*Fr*/ } return l_force }
  Reply With Quote

Old   April 2, 2004, 21:42
Default Re: UDF compilation error
Posts: n/a
structure reference not implemented is usually got when you try to "interpret " the UDF's rather than "compiling" them -Ajay
  Reply With Quote

Old   April 6, 2004, 02:09
Default Re: UDF compilation error
Posts: n/a

Yes,Yes. Ajay is right. We cannot use "interpretted" when we refer to structured variables. Let compile it.

Thank you

  Reply With Quote

Old   April 11, 2015, 13:49
Exclamation same problem
New Member
Join Date: Aug 2014
Posts: 14
Rep Power: 5
bia is on a distinguished road
I've got the same problem , so I try to compile but I had this text message error :Error: open_udf_library: Le fichier spécifié est introuvable.

Error Object: ()
(the specific folder not found (libudf ) ?
I turn back and unload the libudf and recompile again but always the same problem . please help me
bia is offline   Reply With Quote

Old   September 14, 2015, 05:27
New Member
Join Date: Feb 2015
Posts: 3
Rep Power: 4
shadi is on a distinguished road
your udf and your case must be in the same folder
shadi is offline   Reply With Quote


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
Pressure outlet boundary condition rolando OpenFOAM Running, Solving & CFD 62 September 18, 2017 06:45
Native ParaView Reader Bugs tj22 OpenFOAM Paraview & paraFoam 270 January 4, 2016 12:39
UDF: DEFINE_CG_MOTION for vertical jump motion of an electrode! alban Fluent UDF and Scheme Programming 2 June 8, 2010 18:54
[swak4Foam] groovyBC: problems compiling: "flex: not found" and "undefined reference to ..." sega OpenFOAM Community Contributions 12 February 17, 2010 10:30
How to get the max value of the whole field waynezw0618 OpenFOAM Running, Solving & CFD 4 June 17, 2008 05:07

All times are GMT -4. The time now is 20:42.