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

UDF - Error loading libudf

Register Blogs Community New Posts Updated Threads Search

Like Tree56Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 24, 2015, 02:41
Default
  #61
New Member
 
Marya A
Join Date: Mar 2015
Posts: 6
Rep Power: 11
Marya is on a distinguished road
Thanks a lot. It worked for me
Marya is offline   Reply With Quote

Old   September 30, 2015, 15:51
Default
  #62
New Member
 
Yifei
Join Date: Sep 2015
Posts: 5
Rep Power: 10
gyf135 is on a distinguished road
The description in the pdf file works for me!

I was trying to load the libudf to Fluent after I thought I have built it. Actually it didn't. Even though there is no error message showing up when I click on the build button.

The problem I encountered was due to a space in the name of my .c file. So I suggest to make a simple name for the .c file. And I found this when I checked the log file under the /libudf/win64/ folder. Hope this would help someone.
masood135 likes this.
gyf135 is offline   Reply With Quote

Old   October 14, 2015, 18:52
Default Amazing!!
  #63
Member
 
Rui
Join Date: Apr 2015
Location: Montreal. CA
Posts: 49
Rep Power: 11
roi247 is on a distinguished road
Thank you for the help
roi247 is offline   Reply With Quote

Old   April 18, 2016, 14:52
Default
  #64
New Member
 
Ozair Piracha
Join Date: Mar 2016
Posts: 4
Rep Power: 10
Ozair Piracha is on a distinguished road
Hey all,
I am using Windows 10 (64 Bits). Would I have to install SDK for Windows 10 to run the Fluent according to the method mentioned in the above posts?
I will be obliged to have any reply.
Thank you.
Ozair Piracha is offline   Reply With Quote

Old   May 25, 2016, 19:02
Default Loading a UDF
  #65
New Member
 
johnr
Join Date: May 2016
Posts: 10
Rep Power: 9
Johnr is on a distinguished road
Hi,
I have made a udf ".c" file. now i don't know how to load this file in fluent. It basically takes outlet temp at each time step and regulates x momentum source term from that.

I am new to udfs....Help is needed...
Johnr is offline   Reply With Quote

Old   May 26, 2016, 02:22
Default
  #66
New Member
 
jyothsna k
Join Date: May 2014
Posts: 18
Rep Power: 11
jyothsna k is on a distinguished road
1. copy your .c file to your project's 'Fluent' folder
2. In Fluent, go to
Define->User Defined-> Functions->Compiled->Add->(select your file)-> Build
3. if you see any error, rectify it in your .c file , save and compile again(no need to add again. just click 'compile')
4. when you have no errors click on 'Load'
5. hook the udf's and run
jyothsna k is offline   Reply With Quote

Old   May 27, 2016, 09:48
Default
  #67
Senior Member
 
François Grégoire
Join Date: Jan 2010
Location: Canada
Posts: 392
Rep Power: 17
macfly is on a distinguished road
Quote:
Originally Posted by macfly View Post
Only 2 steps did the trick for me in order to compile UDFs in Fluent 14.5 or 15 on Windows 8.1:

- Installing Microsoft Visual Studio Express 2012 for Windows 8: http://www.microsoft.com/en-ca/downl....aspx?id=30664

- Add the path to nmake.exe to the Path environment variable.
Hi all,
I just want to mention that the same setup works just fine for compiling UDFs with Windows 10 64 bit/Fluent 17.0 (even if the Visual Studio version is supposedly for Windows 8).
jpap87 likes this.
macfly is offline   Reply With Quote

Old   June 2, 2016, 04:26
Default
  #68
New Member
 
JP
Join Date: May 2016
Posts: 2
Rep Power: 0
jpap87 is on a distinguished road
Quote:
Originally Posted by macfly View Post
Hi all,
I just want to mention that the same setup works just fine for compiling UDFs with Windows 10 64 bit/Fluent 17.0 (even if the Visual Studio version is supposedly for Windows 8).
Hey macfly

Pardon my "noobness" but what exactly is/meant by "- Add the path to nmake.exe to the Path environment variable." what do you do exactly?

Thank you very much
jpap87 is offline   Reply With Quote

Old   June 2, 2016, 10:36
Default
  #69
Senior Member
 
François Grégoire
Join Date: Jan 2010
Location: Canada
Posts: 392
Rep Power: 17
macfly is on a distinguished road
How to add the path to nmake.exe to the Path environment variable:
- Go to Control Panel => System => Advanced System Properties => Advanced tab and you should get the window shown on the 1st attached picture.
- Click on Environment Variables...
- Select the Path environment variable and click Edit... (see 2nd attached picture)
- In the Edit environment variable window, click New and add the path where nmake.exe is located under the Visual Studio installation. On my computer it's C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin (see 3rd attached picture)

That's it
Attached Images
File Type: png ev0.PNG (15.5 KB, 94 views)
File Type: png ev1.png (13.4 KB, 93 views)
File Type: png ev2.png (14.3 KB, 105 views)
pakk, utkunun and jpap87 like this.
macfly is offline   Reply With Quote

Old   June 2, 2016, 12:22
Default
  #70
New Member
 
JP
Join Date: May 2016
Posts: 2
Rep Power: 0
jpap87 is on a distinguished road
Quote:
Originally Posted by macfly View Post
How to add the path to nmake.exe to the Path environment variable:
- Go to Control Panel => System => Advanced System Properties => Advanced tab and you should get the window shown on the 1st attached picture.
- Click on Environment Variables...
- Select the Path environment variable and click Edit... (see 2nd attached picture)
- In the Edit environment variable window, click New and add the path where nmake.exe is located under the Visual Studio installation. On my computer it's C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin (see 3rd attached picture)

That's it

Thank you very much for your help!
jpap87 is offline   Reply With Quote

Old   December 20, 2016, 06:02
Default
  #71
New Member
 
invincible
Join Date: Dec 2016
Posts: 17
Rep Power: 9
osamaajaz is on a distinguished road
i am using MSVB2010 and getting error that is displayed in attached pictures
Attached Images
File Type: png 1.png (5.9 KB, 33 views)
File Type: png Untitled.png (16.1 KB, 29 views)
osamaajaz is offline   Reply With Quote

Old   January 13, 2017, 09:40
Default #F error
  #72
New Member
 
invincible
Join Date: Dec 2016
Posts: 17
Rep Power: 9
osamaajaz is on a distinguished road
respected mates, there is a problem i am facing with UDF file. Kindly check and pont out what is the main error

this is code i am using for 2D
and getting the error that is showed in the attached picture


#include "udf.h"
DEFINE_CG_MOTION(move,dt,vel,omega,time,dtime)
{
vel[1] = 0.0942*sin(0.628*time);

}

DEFINE_CG_MOTION(ball1,dt,vel,omega,time,dtime)
{
if (time>0 && time<1)
vel[1]=0.018*time;
else if (time>5 && time<5.1)
vel[1]=-0.0005;
else if (time>5.1 && time<5.5)
vel[1]=-0.035;
else
vel[1]=-0.00;

}

DEFINE_CG_MOTION(ball2,dt,vel,omega,time,dtime)
{
if (time>0 && time<0.4)
vel[1]=-0.01;
else if (time>0.4 && time<5.5)
vel[1]=0.0942*sin(0.628*time);
else if (time>5.5 && time<6.17)
vel[1]=-0.0028;
else
vel[1]=0.0942*sin(0.628*time);
}
Attached Images
File Type: png Untitled.png (22.1 KB, 22 views)
osamaajaz is offline   Reply With Quote

Old   January 13, 2017, 09:54
Default
  #73
Senior Member
 
Join Date: Nov 2013
Posts: 1,965
Rep Power: 26
pakk will become famous soon enough
You are showing the error that you get when you try to load the UDF. But the problem happened when you tried to compile ("build") the UDF. Show the text that is printed after you click 'build'.
pakk is offline   Reply With Quote

Old   January 13, 2017, 10:03
Default
  #74
Senior Member
 
Kevin
Join Date: Dec 2016
Posts: 138
Rep Power: 9
KevinZ09 is on a distinguished road
It's saying you don't have a library compiled for your 64-bits OS and 2D solver So compile it and load the library. If it still doesn't work, go through the suggestions in this thread.
KevinZ09 is offline   Reply With Quote

Old   January 13, 2017, 11:22
Default
  #75
New Member
 
invincible
Join Date: Dec 2016
Posts: 17
Rep Power: 9
osamaajaz is on a distinguished road
how to compile for that
kindly guide me...
do i need to change all coding or some part in that?
osamaajaz is offline   Reply With Quote

Old   January 13, 2017, 11:27
Default
  #76
New Member
 
invincible
Join Date: Dec 2016
Posts: 17
Rep Power: 9
osamaajaz is on a distinguished road
Quote:
Originally Posted by pakk View Post
You are showing the error that you get when you try to load the UDF. But the problem happened when you tried to compile ("build") the UDF. Show the text that is printed after you click 'build'.
it is building but the problem occurs in loading, as showing in the corresponding pictures. i dont know how to fix it
need your guidance
Attached Images
File Type: png 1.png (35.7 KB, 32 views)
File Type: png 2.png (9.4 KB, 24 views)
osamaajaz is offline   Reply With Quote

Old   January 13, 2017, 11:30
Default
  #77
Boh
Member
 
Join Date: Sep 2016
Posts: 33
Rep Power: 9
Boh is on a distinguished road
Quote:
Originally Posted by macfly View Post
How to add the path to nmake.exe to the Path environment variable:
- Go to Control Panel => System => Advanced System Properties => Advanced tab and you should get the window shown on the 1st attached picture.
- Click on Environment Variables...
- Select the Path environment variable and click Edit... (see 2nd attached picture)
- In the Edit environment variable window, click New and add the path where nmake.exe is located under the Visual Studio installation. On my computer it's C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin (see 3rd attached picture)

That's it
I think you need to do this to fix the problem
Boh is offline   Reply With Quote

Old   January 14, 2017, 06:06
Default
  #78
Senior Member
 
Join Date: Nov 2013
Posts: 1,965
Rep Power: 26
pakk will become famous soon enough
Quote:
Originally Posted by osamaajaz View Post
it is building but the problem occurs in loading, as showing in the corresponding pictures. i dont know how to fix it
need your guidance
Your first picture clearly indicates that the problem occurs in building. I see the following text:
Quote:
'nmake' is not recognized as an internal or external command, ...
Your installation of Fluent can not find the compiler. The problem is not in your code.
pakk is offline   Reply With Quote

Old   January 20, 2017, 12:54
Default
  #79
New Member
 
invincible
Join Date: Dec 2016
Posts: 17
Rep Power: 9
osamaajaz is on a distinguished road
Quote:
Originally Posted by pakk View Post
Your first picture clearly indicates that the problem occurs in building. I see the following text:

Your installation of Fluent can not find the compiler. The problem is not in your code.
how to fix it?
osamaajaz is offline   Reply With Quote

Old   January 20, 2017, 15:07
Default
  #80
Senior Member
 
François Grégoire
Join Date: Jan 2010
Location: Canada
Posts: 392
Rep Power: 17
macfly is on a distinguished road
Quote:
Originally Posted by osamaajaz View Post
how to fix it?
UDF - Error loading libudf

Please read the whole thread before participating in it, it's a minimum.
macfly 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
Dynamic Mesh UDF Qureshi FLUENT 7 March 23, 2017 07:37
UDF parallel error: chip-exec: function not found????? shankara.2 Fluent UDF and Scheme Programming 1 January 16, 2012 22:14
How to add a UDF to a compiled UDF library kim FLUENT 3 October 26, 2011 21:38
UDF...UDF...UDF...UDF Luc SEMINEL FLUENT 0 November 25, 2002 04:03
UDF, UDF, UDF, UDF Luc SEMINEL Main CFD Forum 0 November 25, 2002 04:01


All times are GMT -4. The time now is 07:14.