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

User defined functions

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

Like Tree2Likes
  • 1 Post By usman naseer
  • 1 Post By Juan Carlos

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 17, 2010, 13:53
Default User defined functions
  #1
New Member
 
Juan Carlos
Join Date: Feb 2010
Posts: 9
Rep Power: 16
Juan Carlos is on a distinguished road
Hi, to Flunet users,
I need to describe a three way flapper valve motion.
Mi intention is to simulate the arm and clapper move like a rigid body motion with dynamic mesh and user defined functions (udfs).
I have the geometry definite but, Iīm not experience using udfs in fluent.
Does anyone have any suggestions?
Thanks so much!
Juan C.
Juan Carlos is offline   Reply With Quote

Old   February 17, 2010, 23:38
Default
  #2
New Member
 
USMAN
Join Date: Nov 2009
Posts: 28
Rep Power: 16
usman naseer is on a distinguished road
Hi carlos,,
First of all understand the physics of your body motion.I mean to say that whether you have to assign a certain path to your body which is to be followed during its motion OR the flow will move your body by exerting some forces on it.
2. There are different types of "Macros" available in Fluent to describe different types of motion.Choose one of them according to your body motion.I will suggest you to use "DEFINE_CG_MOTION" if you have to assign a path to your body.
3. Install Visual studio alongwith Fluent and write a simple function in C++ by calling those Macros.Fluent manual will help you a lot in this regard.
4. Compile your UDF in Fluent and start your simulation.
Start working on your UDF & you will come to know about all these things with the passage of time.
Good Luck
Regards
usman naseer is offline   Reply With Quote

Old   February 18, 2010, 10:02
Default
  #3
New Member
 
Juan Carlos
Join Date: Feb 2010
Posts: 9
Rep Power: 16
Juan Carlos is on a distinguished road
Hi Usman
Thanks for you replay.
Respect to the physics of the problem, in this case the flow move the valve by exerting forces on it.
I will treat to reproduce the body motion of the valve due to hinge moment produced by the flow forces actuating on it.
I was reading the manual, particularly the dynamic mesh topics, and I agree with you to use "DEFINE_CG_MOTION" Macro to specify the flow driven rigid body motion, but I really don’t know how it does.
Regards,
Juan C.
Juan Carlos is offline   Reply With Quote

Old   February 22, 2010, 01:07
Default
  #4
New Member
 
USMAN
Join Date: Nov 2009
Posts: 28
Rep Power: 16
usman naseer is on a distinguished road
hi carlos,,
In the beginning ,you will face difficulties because everything regarding udf is new for you.But with the passage of time ,you will become familiar with it.
I would suggest you to try to understand the examples completely in Fluent manual regarding "DEFINE_CG_MOTION".This will help you a lot in writing your own udf.Let me know if it works.Then I will send you my own udf of the same macro.
But first try it yourself.
Good Luck
zrw823 likes this.
usman naseer is offline   Reply With Quote

Old   February 22, 2010, 01:33
Default
  #5
New Member
 
nishith dulet
Join Date: Feb 2010
Posts: 4
Rep Power: 16
nishith is on a distinguished road
hi usman i think u are dealing with udfs n all... this one is my problem please through some light..... I am studying R T instability and for that i have written UDF for creating a sinusoidal interface between the two liquids, the udf was interpreted well and after hooking i can see the sinusoidal interface by contours-----> phase. After doing all this when i start iterations, just after the first iteration all the things are getting vanished, in the sense now the lower fluid has taken place in all over the domain by vanishing the upper one, now i don't know the problem.

may be i am lagging some where in defining UDF but i have used UDF in only initialization and as i can see the sinusoidal interface i think its working well but if its working well then whats the problem ????????????

Please help,

Thanks
nishith is offline   Reply With Quote

Old   February 22, 2010, 10:08
Default
  #6
New Member
 
USMAN
Join Date: Nov 2009
Posts: 28
Rep Power: 16
usman naseer is on a distinguished road
hi nishith,
I am really sory.I am unable to help you in this regard.
Don't have any idea about this particular area.
Regards
usman naseer is offline   Reply With Quote

Old   February 24, 2010, 06:25
Default UDF solution
  #7
meb
Member
 
Marco Evangelos Biancolini
Join Date: May 2009
Location: Rome - Italy
Posts: 80
Rep Power: 16
meb is on a distinguished road
We did it for reed valves:
http://www.torvergata-karting.it/art...leview/76/1/9/
http://www.torvergata-karting.it/art...eview/92/1/16/

I'm currently exploring how to solve the problem using mesh morphing (http://www.rbf-morph.com/) and modal superposition. In fact using mesh morphing we can directly prescribe the motion acting on solutions weight (open loop) or we can calculate it on the basis of CFD results (closed loop as for FSI).

MEB
meb is offline   Reply With Quote

Old   March 25, 2010, 10:48
Default
  #8
New Member
 
Juan Carlos
Join Date: Feb 2010
Posts: 9
Rep Power: 16
Juan Carlos is on a distinguished road
Hi Usman
I was analyzing my problem of valve simulation and I can see that to reproduce the body motion of the valve due to hinge moment, I need determinate the magnitude and point of force application.
In the udf, I can use Compute_Force_And_Moment function to determinate the force, but I donīt know how find the position of the force application.
Do you have any suggestions that can help me?
Thanks so much!
Juan C.
zrw823 likes this.
Juan Carlos is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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 Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
User defined functions??? student CFX 0 March 26, 2008 07:54
use of user defined functions (UDF) Vedavyasa M FLUENT 0 June 27, 2007 07:21
Usage of user defined functions Gowrish FLUENT 1 October 26, 2005 08:44
user defined functions (udf) Sundar FLUENT 1 September 1, 2004 02:59
User defined functions Tuomas Koiranen FLUENT 2 December 29, 1999 08:41


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