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

UDF for 1DOF Rotation

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 1 Post By AlexanderZ
  • 1 Post By AlexanderZ

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   December 26, 2017, 21:43
Question UDF for 1DOF Rotation
  #1
Member
 
ram_call's Avatar
 
ram
Join Date: Apr 2013
Posts: 37
Rep Power: 13
ram_call is on a distinguished road
Hi everyone,
I am trying to simulate rotation of an impeller around X axis (1DOF). I've wrote this UDF, but error for compiling is as below:
[Error] udf.h: No such file or directory

UDF:
#include "udf.h"
DEFINE_SDOF_PROPERTIES(turbine,prop,dt,time,dtime)
{
prop[SDOF_IXX]=0.0001969261;
prop[SDOF_ZERO_TRANS_X]=TRUE;
prop[SDOF_ZERO_TRANS_Y]=TRUE;
prop[SDOF_ZERO_TRANS_Z]=TRUE;
prop[SDOF_ZERO_ROT_X]=FALSE;
prop[SDOF_ZERO_ROT_Y]=TRUE;
prop[SDOF_ZERO_ROT_Z]=TRUE;
printf("\nturbine: updated 6DOF properties");
}

what is the error?
1) is the UDF correct? I think for rotation mass is not necessary, is it? also defining other moments, presumably fluent will consider zero, right?
2) Are units in SI for UDF? the units for IXX is assumed kg.m2 (SI)
3) I defined the rotation axis X, does it mean it will be the axis of rotation?
4) how fluent can understand it is CW or CCW rotation? in Ansys 18 (no need to UDF for this kind of problem) I could define -1 along X for axis of rotation, which I think it defined the direction.
Any experience?
ram_call is offline   Reply With Quote

Old   December 27, 2017, 13:22
Default
  #2
Member
 
ram_call's Avatar
 
ram
Join Date: Apr 2013
Posts: 37
Rep Power: 13
ram_call is on a distinguished road
maybe I dont know how to comoile a UDF at the first place, i am new on UDF
ram_call is offline   Reply With Quote

Old   December 27, 2017, 21:20
Default
  #3
Senior Member
 
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34
AlexanderZ will become famous soon enoughAlexanderZ will become famous soon enough
It seems, you have installed fluent using not default setting.
I think, the problem is that fluent doesn't see his files for udf.

To fix this issue you may try to set windows environment variable FLUENT_INC
and put there your path to fluent (by default C:\ANSYS Inc\v182\fluent )

Best regards
ram_call likes this.
AlexanderZ is offline   Reply With Quote

Old   December 27, 2017, 21:21
Default
  #4
Senior Member
 
Alexander
Join Date: Apr 2013
Posts: 2,363
Rep Power: 34
AlexanderZ will become famous soon enoughAlexanderZ will become famous soon enough
do not forget to reboot your computer
ram_call likes this.
AlexanderZ is offline   Reply With Quote

Old   December 29, 2017, 14:53
Default
  #5
Member
 
ram_call's Avatar
 
ram
Join Date: Apr 2013
Posts: 37
Rep Power: 13
ram_call is on a distinguished road
Quote:
Originally Posted by AlexanderZ View Post
It seems, you have installed fluent using not default setting.
I think, the problem is that fluent doesn't see his files for udf.

To fix this issue you may try to set windows environment variable FLUENT_INC
and put there your path to fluent (by default C:\ANSYS Inc\v182\fluent )

Best regards
thanks for answer. I installed visual basic and after first attempt, seems fluent recognized it for compiler automatically. It seems recent versions (18 for my case) can do it, but for older need settings you mentioned.
ram_call is offline   Reply With Quote

Old   December 29, 2017, 14:55
Default
  #6
Member
 
ram_call's Avatar
 
ram
Join Date: Apr 2013
Posts: 37
Rep Power: 13
ram_call is on a distinguished road
Quote:
Originally Posted by AlexanderZ View Post
do not forget to reboot your computer
do you know about question 4? should I enter negative value for Ixx for correct rotation direction or no difference for that and domain will rotate based on flow regime and forces coming by.
also my geometry is in mm, but I entered value for mass and moment of inertia in m and kg.m2. I hope this is true since I read in manual that the default units are SI.
ram_call is offline   Reply With Quote

Reply

Tags
6dof, rotation, udf


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
Define CG_Motion UDF Macro query bhat_nikhil Fluent UDF and Scheme Programming 0 October 31, 2017 03:33
Fluent Radiation/porous media Schmitt pierre-Louis FLUENT 26 September 1, 2016 11:29
UDF for rotation Hari Fluent UDF and Scheme Programming 2 January 13, 2016 03:51
UDF for solid body rotation araz Fluent UDF and Scheme Programming 1 January 13, 2016 03:46
UDF, UDF, UDF, UDF Luc SEMINEL Main CFD Forum 0 November 25, 2002 05:01


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