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

someone help me please with my UDF

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

Reply
 
LinkBack Thread Tools Display Modes
Old   January 10, 2011, 03:25
Default someone help me please with my UDF
  #1
Member
 
EH
Join Date: Dec 2010
Posts: 61
Rep Power: 7
ehooi is on a distinguished road
Hi all.
I have written a UDF that calculates the mean temperature of the outflow that is to be supplied to the inlet (something like a recirculation tank). When I compiled the UDF (UDFtrial.c), the following messages appear:
Error Object: #f
Deleted old libudf\win64\3ddp_host\libudf.dll
libudf\win64\3ddp_node\libudf.dll
1 file(s) copied.
(system "copy "C:\PROGRA~1\ANSYSI~1\v121\fluent"\fluent12.1.4\sr c\makefile_nt.udf libudf\win64\3ddp_host\makefile")
1 file(s) copied.
(chdir "libudf")()
(chdir "win64\3ddp_host")()
# Generating ud_io1.h
(system "copy "C:\PROGRA~1\ANSYSI~1\v121\fluent"\fluent12.1.4\sr c\makefile_nt.udf libudf\win64\3ddp_node\makefile")
1 file(s) copied.
(chdir "libudf")()
(chdir "win64\3ddp_node")()
# Generating ud_io1.h

and not the message as suggested by the UDF manual to be a successful compilation. Loading the library led to this error:

Opening library "libudf"...
Primitive Error at Node 0: open_udf_library: The operation completed successfully.

Primitive Error at Node 1: open_udf_library: The system cannot find the file specified.

Primitive Error at Node 2: open_udf_library: The system cannot find the file specified.

Primitive Error at Node 3: open_udf_library: The system cannot find the file specified.

Error: open_udf_library: The operation completed successfully.
Error Object: #f

I am running FLuent on a Windows 7 64bit system and parallel on a local machine.

Can someone help me with this?

Many thanks.

EH
ehooi is offline   Reply With Quote

Old   January 12, 2011, 22:32
Default
  #2
Senior Member
 
Ji Junjie
Join Date: Feb 2010
Location: Shanghai, China
Posts: 109
Rep Power: 8
gearboy is on a distinguished road
Quote:
Originally Posted by ehooi View Post
Hi all.
I have written a UDF that calculates the mean temperature of the outflow that is to be supplied to the inlet (something like a recirculation tank). When I compiled the UDF (UDFtrial.c), the following messages appear:
Error Object: #f
Deleted old libudf\win64\3ddp_host\libudf.dll
libudf\win64\3ddp_node\libudf.dll
1 file(s) copied.
(system "copy "C:\PROGRA~1\ANSYSI~1\v121\fluent"\fluent12.1.4\sr c\makefile_nt.udf libudf\win64\3ddp_host\makefile")
1 file(s) copied.
(chdir "libudf")()
(chdir "win64\3ddp_host")()
# Generating ud_io1.h
(system "copy "C:\PROGRA~1\ANSYSI~1\v121\fluent"\fluent12.1.4\sr c\makefile_nt.udf libudf\win64\3ddp_node\makefile")
1 file(s) copied.
(chdir "libudf")()
(chdir "win64\3ddp_node")()
# Generating ud_io1.h

and not the message as suggested by the UDF manual to be a successful compilation. Loading the library led to this error:

Opening library "libudf"...
Primitive Error at Node 0: open_udf_library: The operation completed successfully.

Primitive Error at Node 1: open_udf_library: The system cannot find the file specified.

Primitive Error at Node 2: open_udf_library: The system cannot find the file specified.

Primitive Error at Node 3: open_udf_library: The system cannot find the file specified.

Error: open_udf_library: The operation completed successfully.
Error Object: #f

I am running FLuent on a Windows 7 64bit system and parallel on a local machine.

Can someone help me with this?

Many thanks.

EH
Do not put the case and udf source file in the folder with a blank, such as "Program files"
gearboy is offline   Reply With Quote

Old   January 13, 2011, 03:02
Default
  #3
Member
 
EH
Join Date: Dec 2010
Posts: 61
Rep Power: 7
ehooi is on a distinguished road
Hi,
Thanks for your reply but the case file and the udf are in a path that does not contain spaces.

D:\USERS\EHOOI\Fluent\SONO\FLUENT_EH\Fabric_100_10 Jan


I have been trying to solve this issue for some time now and any help will be gratefully appreciated.
ehooi is offline   Reply With Quote

Old   January 13, 2011, 11:55
Default
  #4
Senior Member
 
Ji Junjie
Join Date: Feb 2010
Location: Shanghai, China
Posts: 109
Rep Power: 8
gearboy is on a distinguished road
Quote:
Originally Posted by ehooi View Post
Hi,
Thanks for your reply but the case file and the udf are in a path that does not contain spaces.

D:\USERS\EHOOI\Fluent\SONO\FLUENT_EH\Fabric_100_10 Jan


I have been trying to solve this issue for some time now and any help will be gratefully appreciated.
There is a space in "Fabric_100_10 Jan", right?between "Fabric_100_10" and "Jan".
gearboy is offline   Reply With Quote

Old   January 13, 2011, 12:02
Default
  #5
Member
 
EH
Join Date: Dec 2010
Posts: 61
Rep Power: 7
ehooi is on a distinguished road
Hi,
There is no space there. Sorry for the mistake there. The directory is:

D:\USERS\EHOOI\Fluent\SONO\FLUENT_EH\Fabric_100_10 Jan

which has no space.

I have no idea what is wrong.
ehooi is offline   Reply With Quote

Old   January 13, 2011, 21:40
Default
  #6
Senior Member
 
Ji Junjie
Join Date: Feb 2010
Location: Shanghai, China
Posts: 109
Rep Power: 8
gearboy is on a distinguished road
Quote:
Originally Posted by ehooi View Post
Hi,
There is no space there. Sorry for the mistake there. The directory is:

D:\USERS\EHOOI\Fluent\SONO\FLUENT_EH\Fabric_100_10 Jan

which has no space.

I have no idea what is wrong.
Another possibility is that you install ansys under "Program files", which has a space.
gearboy is offline   Reply With Quote

Old   January 14, 2011, 06:20
Default
  #7
Member
 
EH
Join Date: Dec 2010
Posts: 61
Rep Power: 7
ehooi is on a distinguished road
Hi,
Thanks for your reply. Yes Ansys is installed in

C:\Program Files\ANSYS Inc

There are spaces in Program Files and Ansys Inc. Are you saying that the spaces will cause error when trying to run parallel UDF?

But ANSYS Inc is a default folder created by ansys....does it mean I would have to change that as well?

Thanks.

EH
ehooi is offline   Reply With Quote

Old   January 17, 2011, 09:58
Default
  #8
Senior Member
 
Ji Junjie
Join Date: Feb 2010
Location: Shanghai, China
Posts: 109
Rep Power: 8
gearboy is on a distinguished road
Quote:
Originally Posted by ehooi View Post
Hi,
Thanks for your reply. Yes Ansys is installed in

C:\Program Files\ANSYS Inc

There are spaces in Program Files and Ansys Inc. Are you saying that the spaces will cause error when trying to run parallel UDF?

But ANSYS Inc is a default folder created by ansys....does it mean I would have to change that as well?

Thanks.

EH
I have never try ansys 12. Just give you some idea.
gearboy is offline   Reply With Quote

Old   September 27, 2011, 03:01
Default Please let me know about the outcome
  #9
New Member
 
Ehsan
Join Date: Jun 2011
Posts: 9
Rep Power: 7
Ehsan-F is on a distinguished road
Hi,
Ehooi,
I have the same problem with the same error. Ansys is installed in "program file"
please let me know if you could find the answer.
it take me more than 2 weeks but still no progress.
Ehsan
Ehsan-F is offline   Reply With Quote

Old   September 27, 2011, 03:09
Default
  #10
Member
 
EH
Join Date: Dec 2010
Posts: 61
Rep Power: 7
ehooi is on a distinguished road
Quote:
Originally Posted by Ehsan-F View Post
Hi,
Ehooi,
I have the same problem with the same error. Ansys is installed in "program file"
please let me know if you could find the answer.
it take me more than 2 weeks but still no progress.
Ehsan
You have to install Microsoft Windows SDK 7.1 Command Prompt and run Fluent from there. Also use Microsoft Visual C++ 2010 Express.

Hope this helps
ehooi is offline   Reply With Quote

Old   September 27, 2011, 03:14
Default
  #11
Member
 
EH
Join Date: Dec 2010
Posts: 61
Rep Power: 7
ehooi is on a distinguished road
Quote:
Originally Posted by Ehsan-F View Post
Hi,
Ehooi,
I have the same problem with the same error. Ansys is installed in "program file"
please let me know if you could find the answer.
it take me more than 2 weeks but still no progress.
Ehsan
I attached another file containing some help. I couldn't get this to work in mine but maybe it will help in your case. The way I did it was mentioned in my earlier reply to you.
ehooi is offline   Reply With Quote

Old   September 27, 2011, 03:33
Default
  #12
New Member
 
Ehsan
Join Date: Jun 2011
Posts: 9
Rep Power: 7
Ehsan-F is on a distinguished road
Thanks for your quick reply,
I will try that and see if helps. have you installed first visual c++ then fluent or it does not any matter? and then install SDK.
Thanks
Ehsan
Ehsan-F is offline   Reply With Quote

Old   September 27, 2011, 03:35
Default
  #13
Member
 
EH
Join Date: Dec 2010
Posts: 61
Rep Power: 7
ehooi is on a distinguished road
Quote:
Originally Posted by Ehsan-F View Post
Thanks for your quick reply,
I will try that ans see if helps. have you installed first visual c++ then fluent or it does not any matter? and then SDK.
Thanks
Ehsan
Fluent can be installed first, that doesnt matter. But in terms of visual c++ and SDK, I dont remember but I think installing C++ first will make more sense. Just give it a try.
ehooi is offline   Reply With Quote

Old   September 27, 2011, 04:07
Default
  #14
New Member
 
Ehsan
Join Date: Jun 2011
Posts: 9
Rep Power: 7
Ehsan-F is on a distinguished road
Hi Ehooi,
thanks for sending pdf; seems it is not working,
I have installed C++ 2010 express edition and SDK 7.1
Thanks , it can be built now but I cannot load it.
the error is:
Errorpen_udf_library:The system cannot find the file specified.
have you set environment variables for c++ and fluent before you get them working? what you added to your path?
I have added these three:
C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\Tools;C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin;C:\Program Files\ANSYS Inc\v120\fluent\ntbin\win64
please let me know if you have any comment on that
Many thanks
EHsan

Last edited by Ehsan-F; September 27, 2011 at 05:12.
Ehsan-F is offline   Reply With Quote

Old   September 27, 2011, 06:15
Default
  #15
Member
 
EH
Join Date: Dec 2010
Posts: 61
Rep Power: 7
ehooi is on a distinguished road
Quote:
Originally Posted by Ehsan-F View Post
Hi Ehooi,
thanks for sending pdf; seems it is not working,
I have installed C++ 2010 express edition and SDK 7.1
Thanks , it can be built now but I cannot load it.
the error is:
Errorpen_udf_library:The system cannot find the file specified.
have you set environment variables for c++ and fluent before you get them working? what you added to your path?
I have added these three:
C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\Tools;C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin;C:\Program Files\ANSYS Inc\v120\fluent\ntbin\win64
please let me know if you have any comment on that
Many thanks
EHsan
Sorry I can't remember how I did it. But could you give me more information as in where is it that they asked you to set the path for the environment variables? Maybe that will jog my memory.
ehooi is offline   Reply With Quote

Old   September 27, 2011, 12:40
Default
  #16
New Member
 
Ehsan
Join Date: Jun 2011
Posts: 9
Rep Power: 7
Ehsan-F is on a distinguished road
Hi,
It works now, I just changed the file name from "gas nozzle" to "nozzle" then it works.
Thanks alot for all your helps
Ehsan
Ehsan-F is offline   Reply With Quote

Old   November 2, 2011, 03:33
Default
  #17
Senior Member
 
Mohsin Mukhtar
Join Date: Mar 2010
Location: South Korea
Posts: 249
Rep Power: 9
Mohsin is on a distinguished road
Dear Ehsan,

I have got exactly same problem.
Could you tell me which file name you had changed? Case and Data file names? Apparently it seems that they shouldn't have a space between them but mine has no space still i am getting the error. Any suggestion?

Greatly thanks
Mohsin is offline   Reply With Quote

Old   November 2, 2011, 03:45
Default
  #18
New Member
 
Ehsan
Join Date: Jun 2011
Posts: 9
Rep Power: 7
Ehsan-F is on a distinguished road
Hi Mohsin,
I have attached a file containing what I have done, see that may help you.
The source file should not have space in its name but your problem maybe different, check the file
Ehsan
Attached Files
File Type: pdf fluent udf.pdf (94.5 KB, 275 views)
Ehsan-F is offline   Reply With Quote

Old   November 2, 2011, 21:53
Default
  #19
Senior Member
 
Mohsin Mukhtar
Join Date: Mar 2010
Location: South Korea
Posts: 249
Rep Power: 9
Mohsin is on a distinguished road
Dear Ehsan,

Thanks alot. Problem solved.
Mohsin is offline   Reply With Quote

Old   January 27, 2014, 14:07
Default
  #20
New Member
 
Kieran
Join Date: Dec 2013
Posts: 6
Rep Power: 4
Kxt908 is on a distinguished road
I encountered the same problem. I made a new workbench case without any spaces in its name and everything seemed to work OK.
Kxt908 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
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 FLUENT 0 November 25, 2002 05:03
UDF, UDF, UDF, UDF Luc SEMINEL Main CFD Forum 0 November 25, 2002 05:01


All times are GMT -4. The time now is 15:52.