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

compiled code for sinusoidal velocity

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 21, 2017, 07:39
Default compiled code for sinusoidal velocity
  #1
New Member
 
AMEET KUMAR
Join Date: Feb 2017
Posts: 14
Rep Power: 9
ameetks99 is on a distinguished road
Please can someone help me to write a UDF for compiled for fluid inlet velocity in recipricating pump which is rotating at 1450 rpm and total displacement of piston is 20 mm.
Diameter of piston is 14 mm.
when I used
#include "udf.h"
DEFINE_PROFILE(unsteady_velocity, thread, position)
{
face_t f;
real t = CURRENT_TIME;
begin_f_loop(f, thread)
{
F_PROFILE(f, thread, position) =2.61*sin(152*t);
}
end_f_loop(f, thread)
and compiled it then an error is found "the system cannot find the file specified"
ameetks99 is offline   Reply With Quote

Old   February 21, 2017, 09:43
Default
  #2
Senior Member
 
Michael Prinkey
Join Date: Mar 2009
Location: Pittsburgh PA
Posts: 363
Rep Power: 25
mprinkey will become famous soon enough
You are missing a closing } on the DEFINE_PROFILE.
mprinkey is offline   Reply With Quote

Old   February 22, 2017, 00:53
Default
  #3
New Member
 
AMEET KUMAR
Join Date: Feb 2017
Posts: 14
Rep Power: 9
ameetks99 is on a distinguished road
thank you for reply but the problem is Not resolved
ameetks99 is offline   Reply With Quote

Old   February 24, 2017, 09:29
Default
  #4
Senior Member
 
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27
pakk will become famous soon enough
I think there if more info showing on your screen that you don't show.
Give more info on the error. (At least the line above it and the line below it.)
pakk is offline   Reply With Quote

Old   February 27, 2017, 00:27
Default
  #5
New Member
 
AMEET KUMAR
Join Date: Feb 2017
Posts: 14
Rep Power: 9
ameetks99 is on a distinguished road
The UDF library you are trying to load (C:\Users\Ameet Kumar Singh\Desktop\final\final pump_files\dp0\FFF\Fluent\libudf) is not compiled for 3d on the current platform (win64).
The system cannot find the file specified.

C:\Users\Ameet Kumar Singh\Desktop\final\final pump_files\dp0\FFF\Fluent\C:\Users\Ameet Kumar Singh\Desktop\final\final pump_files\dp0\FFF\Fluent\libudf\win64\3d\libudf.d ll
This message is showing When I load the compiled udf
ameetks99 is offline   Reply With Quote

Old   February 27, 2017, 07:32
Default
  #6
Senior Member
 
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27
pakk will become famous soon enough
Take a look at the error:
Quote:
The UDF library you are trying to load (...) is not compiled
So this is the error when you try to load the UDF.
The problem occured earlier: when you tried to compile (build) the UDF.

The problem could be that you have spaces in your folder, Fluent has problems with this. Move it to a place without spaces.

If this does not solve it, show the error that you get when you compile.
pakk is offline   Reply With Quote

Old   March 3, 2017, 06:53
Default
  #7
New Member
 
AMEET KUMAR
Join Date: Feb 2017
Posts: 14
Rep Power: 9
ameetks99 is on a distinguished road
Same error
The UDF library you are trying to load (D:\final\final_files\dp0\FFF\Fluent\libudf) is not compiled for 3d on the current platform (win64).
The system cannot find the file specified.

D:\final\final_files\dp0\FFF\Fluent\D:\final\final _files\dp0\FFF\Fluent\libudf\win64\3d\libudf.dll
ameetks99 is offline   Reply With Quote

Old   March 3, 2017, 06:55
Default
  #8
Senior Member
 
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27
pakk will become famous soon enough
"If this does not solve it, show the error that you get when you compile."
pakk is offline   Reply With Quote

Old   March 3, 2017, 10:03
Default
  #9
Senior Member
 
Kevin
Join Date: Dec 2016
Posts: 138
Rep Power: 10
KevinZ09 is on a distinguished road
I've read about these errors quite frequently. Have you had a look in the following thread:

UDF - Error loading libudf

There's even some extra documentation in the form of a .pdf-file in there that could help. Did you compile the code yourself? You have to make sure the compiled library matches your 3D solver and 64-bits OS.
KevinZ09 is offline   Reply With Quote

Old   March 5, 2017, 09:32
Default
  #10
New Member
 
AMEET KUMAR
Join Date: Feb 2017
Posts: 14
Rep Power: 9
ameetks99 is on a distinguished road
I used
#include "udf.h"
DEFINE_PROFILE(unsteady_velocity, thread, position)
{
face_t f;
real t = CURRENT_TIME;
begin_f_loop(f, thread)
{
F_PROFILE(f, thread, position) =2.61*sin(152*t);
}
end_f_loop(f, thread)
and error showing is
The UDF library you are trying to load (D:\final\final_files\dp0\FFF\Fluent\libudf) is not compiled for 3d on the current platform (win64).
The system cannot find the file specified.

D:\final\final_files\dp0\FFF\Fluent\D:\final\final _files\dp0\FFF\Fluent\libudf\win64\3d\libudf.dll
ameetks99 is offline   Reply With Quote

Old   March 6, 2017, 04:12
Default
  #11
Senior Member
 
Join Date: Nov 2013
Posts: 1,965
Rep Power: 27
pakk will become famous soon enough
You are still showing the error that you get when you click 'load'. The error is even saying that: "The UDF library you are trying to load ..."

At the moment you click 'build', some text is shown in the text user interface in Fluent. What is that text?
pakk 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
unable to get parabolic velocity profile with pimplefoam houkensjtu OpenFOAM 4 October 8, 2012 05:41
Velocity profile disturbance due to loss coefficient rks171 Main CFD Forum 3 May 25, 2012 18:30
Variables Definition in CFX Solver 5.6 R P CFX 2 October 26, 2004 03:13
Design Integration with CFD? John C. Chien Main CFD Forum 19 May 17, 2001 16:56
What is the Better Way to Do CFD? John C. Chien Main CFD Forum 54 April 23, 2001 09:10


All times are GMT -4. The time now is 18:46.