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

Compiling/Interpret UDF

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

Like Tree2Likes

Reply
 
LinkBack Thread Tools Display Modes
Old   July 9, 2013, 03:58
Default Compiling/Interpret UDF
  #1
Bin
New Member
 
Chan Hiang Bin
Join Date: Apr 2013
Posts: 28
Rep Power: 4
Bin is on a distinguished road
Hi all,

I would like to ask when I have the UDF file (the .c file), how should I compile/intergret it into FLUENT? When I try what I had read from the tutorial, these messages pop out:

1) the udf library you are trying to load is not compiled.
2) nmake is not recognized as an internal or external command, operable program or batch file.

I'm currently new to ANSYS and still learning how to use it, thank a lot for your helps.

Regards,
Bin
Bin is offline   Reply With Quote

Old   July 9, 2013, 08:39
Default
  #2
Senior Member
 
Ananthakrishnan.A.S
Join Date: Feb 2012
Location: Mumbai (Bombay), India
Posts: 129
Rep Power: 7
Ananthakrishnan is on a distinguished road
Send a message via Skype™ to Ananthakrishnan
Hi,
I dont know what nmake means but i am guessing that probably nmake is not supported within Fluent's compiler so you will have to compile and run the code instead of just intepreting it. You will have to install Visual C++ and microsoft SDK and lauch fluent from the command promt of sdk.

May be someone else can give a more accurate reply to your problem.
Bin likes this.
Ananthakrishnan is offline   Reply With Quote

Old   July 9, 2013, 09:46
Default
  #3
Bin
New Member
 
Chan Hiang Bin
Join Date: Apr 2013
Posts: 28
Rep Power: 4
Bin is on a distinguished road
Thanks a lot Ananthakrishnan, I will try it. So it means that my computer does not has a proper compiler to 'cooperate' with FLUENT is it?

By the way, I'm using "compiled...", sorry for causing any confusion.
Bin is offline   Reply With Quote

Old   July 9, 2013, 23:43
Default
  #4
Bin
New Member
 
Chan Hiang Bin
Join Date: Apr 2013
Posts: 28
Rep Power: 4
Bin is on a distinguished road
Hi all and Ananthakrishnan,

I had installed visual studio and Microsoft SDK tools. But I'm still not sure about lauching fluent from the command promt of sdk. There are many things in the newly install visual studio and SDK tools, and i'm not sure which one is the right one to use. Can some one kindly shows some steps for this?

Thanks a lot in advance.

Best regards,
Bin
Bin is offline   Reply With Quote

Old   July 10, 2013, 02:40
Default
  #5
Senior Member
 
Join Date: Aug 2011
Posts: 315
Rep Power: 11
blackmask will become famous soon enough
The icon for the item should be a miniature of the command prompt "cmd.exe", i.e., a black rectangle with C:\ in it. Click that item and a command prompt will appear. Issue the "set" command in the prompt and you will see the PATH and other variables have been modified to access the source, library and executables provided by MS.
blackmask is offline   Reply With Quote

Old   July 10, 2013, 04:06
Default
  #6
Senior Member
 
Ananthakrishnan.A.S
Join Date: Feb 2012
Location: Mumbai (Bombay), India
Posts: 129
Rep Power: 7
Ananthakrishnan is on a distinguished road
Send a message via Skype™ to Ananthakrishnan
Hi,
In addition to previous reply, if you want still more details please give me your email id. I will send the pdf files which i used for installing and applying the environment variables in my computer..

Bye,
HyperNova likes this.
Ananthakrishnan is offline   Reply With Quote

Old   July 11, 2013, 09:28
Default
  #7
Member
 
Christopher Hershey
Join Date: Feb 2012
Location: East Lansing, Michigan
Posts: 40
Rep Power: 5
Hershey is on a distinguished road
Please see my post on setting up the UDF environment here:

Error compiling: nmake' is not recognized as an internal or external command
Hershey is offline   Reply With Quote

Old   July 11, 2013, 23:36
Default
  #8
Bin
New Member
 
Chan Hiang Bin
Join Date: Apr 2013
Posts: 28
Rep Power: 4
Bin is on a distinguished road
Hi Ananthakrishnan,

This is my email: bin6331@hotmail.com

Sorry for causing so much trouble to you and thank you for your helps.

Best regards,
Bin
Bin is offline   Reply With Quote

Old   August 8, 2013, 00:33
Default how to start fluent in the visual studio frompt
  #9
New Member
 
tran trung
Join Date: Aug 2013
Posts: 23
Rep Power: 3
tranvantrung551987 is on a distinguished road
hello everybody
I am tring to run fluent in the visual studio frompt but me not yet been working. I add C:\Program Files\Microsoft Visual Studio 10.0\Common7\Tools\, C:\Program Files\Microsoft Visual Studio 10.0\VC\bin, C:\Program Files\ANSYS Inc\v140\fluent\ntbin\win32 but failed. Can you help me ! thank verry much
tranvantrung551987 is offline   Reply With Quote

Old   August 8, 2013, 01:43
Default
  #10
Senior Member
 
Paritosh Vasava
Join Date: Oct 2012
Location: Lappeenranta, Finland
Posts: 544
Rep Power: 12
vasava will become famous soon enough
Quote:
Originally Posted by tranvantrung551987 View Post
hello everybody
I am tring to run fluent in the visual studio frompt but me not yet been working. I add C:\Program Files\Microsoft Visual Studio 10.0\Common7\Tools\, C:\Program Files\Microsoft Visual Studio 10.0\VC\bin, C:\Program Files\ANSYS Inc\v140\fluent\ntbin\win32 but failed. Can you help me ! thank verry much
Where exactly you add these path?

Once you open the command prompt enter the path where fluent is installed. The path must be with in double quotation mark. e.g. "C:/Program/#####/fluent.exe". If you are not sure about the path just right click the fluent icon and you will see the exact path.
vasava is offline   Reply With Quote

Old   August 8, 2013, 04:30
Default
  #11
Senior Member
 
Ananthakrishnan.A.S
Join Date: Feb 2012
Location: Mumbai (Bombay), India
Posts: 129
Rep Power: 7
Ananthakrishnan is on a distinguished road
Send a message via Skype™ to Ananthakrishnan
What error do you get?
Ananthakrishnan is offline   Reply With Quote

Old   August 8, 2013, 05:02
Default question
  #12
New Member
 
tran trung
Join Date: Aug 2013
Posts: 23
Rep Power: 3
tranvantrung551987 is on a distinguished road
Quote:
Originally Posted by Ananthakrishnan View Post
What error do you get?
hello everybody
i get error " 'nmake' is not recognized as an internal or external command " when i compiled UDF. To correct this error, i start fluent in visual studio frompt by not
Can you help me?. thank you very much
tranvantrung551987 is offline   Reply With Quote

Old   August 8, 2013, 05:41
Default
  #13
Senior Member
 
Ananthakrishnan.A.S
Join Date: Feb 2012
Location: Mumbai (Bombay), India
Posts: 129
Rep Power: 7
Ananthakrishnan is on a distinguished road
Send a message via Skype™ to Ananthakrishnan
You should not use the visual studio promt..You need to start fluent from "Microsoft windows SDK " promt..You need the compiler Windows SDK to compile the UDF. You can find windows sdk available for free in windows site.
Ananthakrishnan is offline   Reply With Quote

Old   August 9, 2013, 04:50
Default
  #14
New Member
 
tran trung
Join Date: Aug 2013
Posts: 23
Rep Power: 3
tranvantrung551987 is on a distinguished road
Quote:
Originally Posted by Ananthakrishnan View Post
You should not use the visual studio promt..You need to start fluent from "Microsoft windows SDK " promt..You need the compiler Windows SDK to compile the UDF. You can find windows sdk available for free in windows site.
thank you so much
you can tell me with using microsoft SDk to start Fluent.
tranvantrung551987 is offline   Reply With Quote

Old   August 10, 2013, 03:24
Default Hi Anantharishnan
  #15
New Member
 
tran trung
Join Date: Aug 2013
Posts: 23
Rep Power: 3
tranvantrung551987 is on a distinguished road
Quote:
Originally Posted by Ananthakrishnan View Post
Hi,
In addition to previous reply, if you want still more details please give me your email id. I will send the pdf files which i used for installing and applying the environment variables in my computer..

Bye,
Hi
my mail is tranvan_trung551987@yahoo.com. Can you give for me your flie.pdf you use to install
thank you very much
tranvantrung551987 is offline   Reply With Quote

Old   August 11, 2013, 15:14
Default
  #16
New Member
 
Enrico Di Cesare
Join Date: Aug 2013
Location: Verona Italia
Posts: 4
Rep Power: 3
Enricodex is on a distinguished road
Hello

I had the same problem and I am trying to fix it follwing the advices of the discussion that you can find in this forum
(UDF library load error)
I am not yet finished to download the tool needed to fix the problem, so I can be sure that It will work, (if It will work I will contact you, in order to explain step by step the procedure)
Enricodex is offline   Reply With Quote

Old   August 11, 2013, 16:10
Default
  #17
New Member
 
Enrico Di Cesare
Join Date: Aug 2013
Location: Verona Italia
Posts: 4
Rep Power: 3
Enricodex is on a distinguished road
Goooooooooooooooooood job

It works. So if you need some advise you just have to ask for.

Bye
Enricodex is offline   Reply With Quote

Old   March 31, 2014, 12:20
Default problem with compiling udf
  #18
New Member
 
mohammadjavad zeidi
Join Date: Dec 2013
Posts: 1
Rep Power: 0
mohammadjavad313 is on a distinguished road
Quote:
Originally Posted by Enricodex View Post
Hello

I had the same problem and I am trying to fix it follwing the advices of the discussion that you can find in this forum
(UDF library load error)
I am not yet finished to download the tool needed to fix the problem, so I can be sure that It will work, (if It will work I will contact you, in order to explain step by step the procedure)
hello enrico
while i was compiling my udf i encountered this message "The UDF library you are trying to load (libudf) is not compiled for 2ddp on the curent platform (ntx86)."
i have install microsoft visual studio 2012 ultimate version and i have run fluent with it's command but i don't know why i cannot load my udf
mohammadjavad313 is offline   Reply With Quote

Old   April 1, 2014, 05:12
Default
  #19
Senior Member
 
ghost82's Avatar
 
Daniele
Join Date: Oct 2010
Location: Italy
Posts: 899
Rep Power: 15
ghost82 will become famous soon enough
Quote:
Originally Posted by mohammadjavad313 View Post
hello enrico
while i was compiling my udf i encountered this message "The UDF library you are trying to load (libudf) is not compiled for 2ddp on the curent platform (ntx86)."
i have install microsoft visual studio 2012 ultimate version and i have run fluent with it's command but i don't know why i cannot load my udf
Retain the source file and delete the libudf folder; then recompile the source on your pc.
ghost82 is offline   Reply With Quote

Old   May 3, 2014, 07:06
Default me too
  #20
New Member
 
sarighulikhan
Join Date: Mar 2014
Posts: 15
Rep Power: 3
hane is on a distinguished road
Quote:
Originally Posted by Ananthakrishnan View Post
Hi,
In addition to previous reply, if you want still more details please give me your email id. I will send the pdf files which i used for installing and applying the environment variables in my computer..

Bye,
please sent them to my id too
thank u very much
hane is offline   Reply With Quote

Reply

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
Source Term UDF VS Porous Media Model pchoopanya Fluent UDF and Scheme Programming 1 August 28, 2013 06:12
UDF parallel error: chip-exec: function not found????? shankara.2 Fluent UDF and Scheme Programming 1 January 16, 2012 23:14
How to add a UDF to a compiled UDF library kim FLUENT 3 October 26, 2011 21:38
Dynamic Mesh UDF Qureshi FLUENT 1 December 2, 2009 01:27
UDF, UDF, UDF, UDF Luc SEMINEL Main CFD Forum 0 November 25, 2002 05:01


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