CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT > Fluent UDF and Scheme Programming

fluent UDF on linux machine

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By D Harvey

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 2, 2004, 15:34
Default fluent UDF on linux machine
  #1
Min-Hua Wang
Guest
 
Posts: n/a
Hi, All:

I am running fluent 5/6 on a linux machine. Does any one experience using UDF in fluent simulation on that machine.

Which makefile should I get from fluent directory. How to compile it and link to solver. I don't have a problem in running fluent on a Unix machine.

Thanks

MHW
  Reply With Quote

Old   June 4, 2004, 14:19
Default Re: fluent UDF on linux machine
  #2
D Harvey
Guest
 
Posts: n/a
you will get two makefiles. your directory structure should look like this in linux

/home/username

so place the UDF directory as follows:

/home/username/UDF

then libudf

/home/username/libudf

then add lnx86

/home/username/libudf/lnx86

then add src

/home/username/libudf/src

then in the lnx86 dir

/home/username/libudf/lnx86

add 2d 3d 3ddp (this corresponds to 2d 3d and 3d double precision)

then in the source directory you place your .c code

cp /directory location of fluent/Fluent.Inc/fluent6.1.??/src/makefile.udf /home/username/UDF/libudf/src/makefile cp /directory location of fluent/Fluent.Inc/fluent6.1.??/src/makefile.udf2 cp /home/username/UDF/libudf/Makefile

that should do it.

Cheers,

DH
  Reply With Quote

Old   June 4, 2004, 14:20
Default Re: fluent UDF on linux machine
  #3
D Harvey
Guest
 
Posts: n/a
you will get two makefiles. your directory structure should look like this in linux

/home/username

so place the UDF directory as follows:

/home/username/UDF

then libudf

/home/username/UDF/libudf

then add lnx86

/home/username/libudf/lnx86

then add src

/home/username/libudf/src

then in the lnx86 dir

/home/username/libudf/lnx86

add 2d 3d 3ddp (this corresponds to 2d 3d and 3d double precision)

then in the source directory you place your .c code

cp /directory location of fluent/Fluent.Inc/fluent6.1.??/src/makefile.udf /home/username/UDF/libudf/src/makefile cp /directory location of fluent/Fluent.Inc/fluent6.1.??/src/makefile.udf2 cp /home/username/UDF/libudf/Makefile

that should do it.

Cheers,

DH
natantyt likes this.
  Reply With Quote

Old   June 4, 2004, 14:21
Default Re: fluent UDF on linux machine
  #4
D Harvey
Guest
 
Posts: n/a
ignore the first reply it had an error.

BTW this is all in the UDF manual, which you will need.
  Reply With Quote

Old   June 11, 2004, 18:18
Default Re: fluent UDF on linux machine
  #5
Podila
Guest
 
Posts: n/a
Please contact smadhava@dal.ca. I guess he is the right person to help u with. Bye Podila
  Reply With Quote

Old   January 15, 2013, 04:57
Default
  #6
New Member
 
zhy
Join Date: Jan 2013
Posts: 1
Rep Power: 0
zhangyluck is on a distinguished road
[QUOTE=D Harvey
;113010]
cp /directory location of fluent/Fluent.Inc/fluent6.1.??/src/makefile.udf /home/username/UDF/libudf/src/makefile

cp /directory location of fluent/Fluent.Inc/fluent6.1.??/src/makefile.udf2 cp /home/username/UDF/libudf/Makefile


there should be no 'cp' in the second sentence
zhangyluck is offline   Reply With Quote

Old   June 29, 2013, 09:41
Default UDF syntax error
  #7
New Member
 
milad
Join Date: Jun 2013
Posts: 7
Rep Power: 13
majid_m87 is on a distinguished road
Hi all,

I did write a UDF for inlet velocity of my fluent case, but every time I try to interpreted it in Fluent, it says

"Error: /home/mp-current/9-2nd-50-tran/inlet_velocity.c: line 2: syntax error."

I will appreciate it if anyone help me in this case.

and this my UDF Vleocity profile


#include"udf.h"
DEFINE_PROFILE(inlet_velocity, thread, position) /* inlet x velocity = name of the x velocity */
{
real x[ND_ND]; /* this will hold the position vector */
real z;
face_t f; /* f = all the cell faces on the boundary*/
begin_f_loop(f,thread) /* thread = given boundary zone, defined automatically when the UDF is hooked to inlet boundary, the macro begin_f_loop is applied to all the cell faces*/
{
F_CENTROID(x, f, thread); /* the coordinates of the face centroid accessed by F_CENTROID */
z= x[1];
F_PROFILE(f, thread, position) = pow((60+z)/60,(1/7))+((50+z)/5); /* return velocity is assigned through F_PROFILE */
}
end_f_loop(f, thread)
}
majid_m87 is offline   Reply With Quote

Reply


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 Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Install Fluent in Linux L3munoz FLUENT 0 July 21, 2009 15:55
UDF error from Windows to Linux manu FLUENT 3 January 10, 2008 05:02
Fluent on dual processor machine Razvan FLUENT 3 July 19, 2005 12:13
UDF of Zimont model in fluent Z Main CFD Forum 0 February 17, 2005 04:07
UDF in parallel version of fluent yobee FLUENT 2 August 5, 2004 01:36


All times are GMT -4. The time now is 01:25.