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

Error: The UDF library you are trying to load (libudf) is not compiled for 2d on the

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 2 Post By gxu2

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 21, 2012, 12:30
Default Error: The UDF library you are trying to load (libudf) is not compiled for 2d on the
  #1
New Member
 
guoji xu
Join Date: Feb 2012
Posts: 19
Rep Power: 14
gxu2 is on a distinguished road
Hi, all
When I compiling UDFs, I can build "libudf", but I can't load it. So could anyone can help me or to explain why?

Thank you very much!

Opening library "c:\users\gxu2\desktop\vof\libudf"...
Error: The UDF library you are trying to load (libudf) is not compiled for 2d on the curent platform (ntx86).
vadvadim and kushagrapathak like this.
gxu2 is offline   Reply With Quote

Old   March 22, 2012, 09:31
Default
  #2
New Member
 
Marco
Join Date: Apr 2011
Posts: 9
Rep Power: 15
ReeKo is on a distinguished road
Are you sure the UDF was compiled correctly? I suggest you to launch FLUENT from compiler's prompt window under the working directory folder (where the .cas & .dat & the udf are located) then retry with the compiling.
To me, that errors means UDF wasn't compiled correctly.

Regards
ReeKo is offline   Reply With Quote

Old   March 22, 2012, 11:02
Default
  #3
New Member
 
guoji xu
Join Date: Feb 2012
Posts: 19
Rep Power: 14
gxu2 is on a distinguished road
Thank you, my friend!

I have tried lots of times but still can't get that through.

see the picture attachted.
Attached Images
File Type: jpg QQ??20120322100032.jpg (62.1 KB, 1351 views)
gxu2 is offline   Reply With Quote

Old   March 22, 2012, 12:05
Default
  #4
New Member
 
Marco
Join Date: Apr 2011
Posts: 9
Rep Power: 15
ReeKo is on a distinguished road
Are you sure to have tried launching FLUENT from the compiler's prompt window?

If you are, this could be a 32 bit vs 64 bit problem IF you're using FLUENT 64 bit version. For example (i'm working under windows OS) try installing Microsoft .NET Framework SDK. I use the ancient v2.0 version of them and they do the job. They're freeware, google them.
Once you installed them, again, launch FLUENT from SDK's prompt comand and retry.

In addition, check http://www.cfd-online.com/Wiki/Fluen...UDF.29_Related for more troubleshooting.

Regards
ReeKo is offline   Reply With Quote

Old   March 26, 2012, 18:32
Default
  #5
New Member
 
guoji xu
Join Date: Feb 2012
Posts: 19
Rep Power: 14
gxu2 is on a distinguished road
Thank you Reeko

my computer is 32bit and I have installed the ANSYS FLUENT 32bit correctly, so it is not the OS related problem. I have installed .net framework 4.o and SDK 7.1 on my computer and there is also visual C++6.0 on my computer. But I can't get throught this problem.

I am sorry that I don't know how to input orders, like to run fluent in SDK promt command window. Could you tell me a little bit?


Thank you very much and May God bless you!

Best regards!
gxu2 is offline   Reply With Quote

Old   March 27, 2012, 08:51
Default
  #6
New Member
 
Marco
Join Date: Apr 2011
Posts: 9
Rep Power: 15
ReeKo is on a distinguished road
Well, thank you for the blessing

Just tell me, what OS are you running on?

Regards
ReeKo is offline   Reply With Quote

Old   March 27, 2012, 10:27
Default
  #7
New Member
 
guoji xu
Join Date: Feb 2012
Posts: 19
Rep Power: 14
gxu2 is on a distinguished road
win 7, 32 bit, I have installed ANSYS educational version.

It always said the libudf.dll is missing, actually it is not generated and well compiled.

Should I install VC 2008, or 2009, or 2010, I don't know which version I should install for well compiling.

Thank you very much for helping me.
gxu2 is offline   Reply With Quote

Old   March 27, 2012, 11:22
Default
  #8
New Member
 
Marco
Join Date: Apr 2011
Posts: 9
Rep Power: 15
ReeKo is on a distinguished road
Install VC++ 2010 Express then ensure you have followed the steps described in "Set the correct environment variables" @ http://www.cfd-online.com/Wiki/Fluen...UDF.29_Related.
Run SDK's prompt window (you should find it under some folder in the Start->Programs menù). The shell will start from SDK's directory so you have to have to move on your working directory that contains both the case/dat and the UDF files (i.e: C:\my_fluent_case or whatever). Then type "fluent" and return; fluent will start and able to compile, so you can retry hopefully getting what you want.

Regards

Last edited by ReeKo; March 27, 2012 at 11:46.
ReeKo is offline   Reply With Quote

Old   July 20, 2012, 17:31
Default
  #9
New Member
 
Join Date: Jul 2012
Posts: 18
Rep Power: 14
mila_oliv is on a distinguished road
I'm having a similar problem, but can't even build the library....this is what happens after i press build:

1 file(s) copied.
(system "copy "C:\PROGRA~1\ANSYSI~1\v130\fluent"\fluent13.0.0\sr c\makefile_nt.udf "libudf\win64\2ddp\makefile" ")
1 file(s) copied.
(chdir "libudf")()
(chdir "win64\2ddp")()

Done.


I did a test with a code I found in this forum and it was compiled! So I think the problem is my udf.... can you take a look and maybe help me find my mistake??? I just started leraning udf by myself....it's not very easy!


Quote:
#include "udf.h"
#define n 0

DEFINE_SOURCE(funcaocorrente, c, t, ds, eqn)
{
real NV_VEC(psi);
real NV_VEC(vxdy);
real source;
int n,m,deltay;
cell_t c;
Thread *t;

/*number of nodes*/
n+=C_NNODES(c,t);
/*mesh size = mXm*/
m=(n^0.5)-1;
/*distance between nodes*/
deltay=1/m;
/*stream function definition: psi[i][j+1]=psi[i][j]+(Vx*deltay)*/
vxdy=NV_S(C_U(c,t),*=,deltay);
/*calculating stream function*/
C_UDMI(c,t,0)=NV_V(psi,+=,vxdy);
/*allocating stream function to postprocees*/
source=C_UDMI(c,t,0)
dS[eqn]=C_U(c,t);
return source;
}

Last edited by mila_oliv; July 20, 2012 at 18:35.
mila_oliv is offline   Reply With Quote

Old   November 21, 2013, 05:41
Default
  #10
Member
 
mehdimoradi
Join Date: Jun 2013
Posts: 53
Rep Power: 13
mehdimoradi. is on a distinguished road
Quote:
Originally Posted by gxu2 View Post
Hi, all
When I compiling UDFs, I can build "libudf", but I can't load it. So could anyone can help me or to explain why?

Thank you very much!

Opening library "c:\users\gxu2\desktop\vof\libudf"...
Error: The UDF library you are trying to load (libudf) is not compiled for 2d on the curent platform (ntx86).
Hi;
Could you solved your problem. I also encountered with the same problem.
My OS also is win7(32bit) and fluent 32 bit is installed on it.
if you could solve the problem let me know.
Thanks
mehdimoradi. is offline   Reply With Quote

Old   January 22, 2017, 12:12
Smile My solution to this problem
  #11
New Member
 
Katja N.
Join Date: May 2014
Location: Sweden
Posts: 13
Rep Power: 12
Katja is on a distinguished road
Hello,

Today I have experienced this error and found out that's related to the maximum number of characters allowed for file names in Win 7, which is 255 characters. So, if your case is saved in a folder that has a very long path, then you might get this error. Work with shorter path lengths and see if that solves the problem.

Cheers
__________________
Katja is offline   Reply With Quote

Old   April 22, 2017, 00:37
Default
  #12
New Member
 
Zhijie Zhao
Join Date: Apr 2017
Posts: 1
Rep Power: 0
JIEkobe24 is on a distinguished road
Please make sure that there is no space in front the macro name DEFINE_SOURCE(),then compile the udf again .
JIEkobe24 is offline   Reply With Quote

Old   December 20, 2017, 18:17
Default
  #13
Senior Member
 
Joe
Join Date: Feb 2012
Location: Canada
Posts: 112
Rep Power: 14
enayath is on a distinguished road
https://www.youtube.com/watch?v=xt2hnE9_LdM
enayath is offline   Reply With Quote

Old   August 10, 2018, 18:38
Default cause: syntax error
  #14
New Member
 
Patrick
Join Date: Jul 2018
Posts: 4
Rep Power: 8
pat-cfd is on a distinguished road
I had this error happen to me today and found the cause to be a syntax error (forgot to put a semi colon at the end of a statement, d'oh!)

When you build the library, read the terminal messages that pop up to see if there is any mention of an error.
pat-cfd 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
compiled udf rafat FLUENT 2 July 25, 2003 02:57
how to quit compiled or interprited UDF tian FLUENT 0 April 9, 2003 00:53
Installing Compiled UDF HARI SARYONO FLUENT 0 November 24, 2001 02:48
setting up compiled UDF library in windows2000 sivakumar FLUENT 1 October 19, 2001 04:46
Compiled UDF / Compilation problem mikhail FLUENT 1 October 13, 2000 07:12


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