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

incorrect cg motion UDF sdof_properties::libudf on zone 6 (assuming no motion)

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 18, 2013, 19:51
Default incorrect cg motion UDF sdof_properties::libudf on zone 6 (assuming no motion)
  #1
New Member
 
Mohamed Magdy Mohamed
Join Date: Jan 2013
Posts: 9
Rep Power: 13
M.Magdy is on a distinguished road
Hi,
I'm trying to simulate the movement of floating body in sea.
I'm using a udf for wall movement :
#include "udf.h"
#include "dynamesh_tools.h"
DEFINE_CG_MOTION(wave,dt,vel,omega,time,dtime )
{
vel[0]=((4)*(sin((63)*(time))));
}


and another one for the floating body six_dof_property:

/************************************************** *****
SDOF property compiled UDF with external forces/moments
************************************************** *****/
#include "udf.h"

DEFINE_SDOF_PROPERTIES(sdof_properties, prop, dt, time, dtime)
{
prop[SDOF_MASS] = 85167.33;
prop[SDOF_IXX] = 174112.84;
prop[SDOF_IYY] = 28237716.54;
prop[SDOF_IZZ] = 28237716.54;

prop[SDOF_ZERO_TRANS_X] = TRUE;
prop[SDOF_ZERO_TRANS_Y] = TRUE;
prop[SDOF_ZERO_ROT_X] = TRUE;
prop[SDOF_ZERO_ROT_Z] = TRUE;
printf ("\n updated 6DOF properties");
}

when i check the "six DOF" option in dynamic mesh the wall doesn't move and this message appears:
Unable to read motion history

while if i unchecked it an error appears -
but the waves are generated correctly-:
incorrect cg motion UDF sdof_properties::libudf on zone 6 (assuming no motion)

Can someone please help. Thanks.

Last edited by M.Magdy; March 22, 2013 at 07:54.
M.Magdy is offline   Reply With Quote

Old   March 19, 2013, 03:42
Default
  #2
Senior Member
 
Paritosh Vasava
Join Date: Oct 2012
Location: Lappeenranta, Finland
Posts: 732
Rep Power: 23
vasava will become famous soon enough
Try this

#include "udf.h"
#include "dynamesh_tools.h"
DEFINE_CG_MOTION(wave, dt, cg_vel, cg_omega, time, dtime)
real t = CURRENT_TIME;
{
cg_vel[0] = ((4)*(sin((63)*(t))));
cg_vel[1] = 0.0;
cg_vel[2] = 0.0;

cg_omega[0] = 0.0;
cg_omega[1] = 0.0;
cg_omega[2] = 0.0;

}
vasava is offline   Reply With Quote

Old   March 19, 2013, 04:15
Default
  #3
Senior Member
 
Paritosh Vasava
Join Date: Oct 2012
Location: Lappeenranta, Finland
Posts: 732
Rep Power: 23
vasava will become famous soon enough
Also you do not need 'dynamesh_tools.h'.
vasava is offline   Reply With Quote

Old   March 19, 2013, 08:28
Default
  #4
New Member
 
Mohamed Magdy Mohamed
Join Date: Jan 2013
Posts: 9
Rep Power: 13
M.Magdy is on a distinguished road
Thank you but the problem is still the same
M.Magdy is offline   Reply With Quote

Old   March 19, 2013, 09:51
Default
  #5
Senior Member
 
Paritosh Vasava
Join Date: Oct 2012
Location: Lappeenranta, Finland
Posts: 732
Rep Power: 23
vasava will become famous soon enough
Sorry initially I thought that there is problem with the first part and did not pay any attention to the second part.

Anyways, there are two things here

1. 'prop[SDOF_ZERO_TRANS_X] = TRUE;' and 'prop[SDOF_ZERO_TRANS_Y] = TRUE;' means that you want/allow the object to move in X and Y direction but not in Z-direction.

2. 'prop[SDOF_ZERO_ROT_X] = TRUE;' and 'prop[SDOF_ZERO_ROT_Z] = TRUE;' means that you want/allow the object to rotate in X and Z axes but not over Y-axis.

Don't you think that these two are not consistent with each other? Remove the line with 'prop[SDOF_ZERO_ROT_X] = TRUE;' and then try again.


Don't forget to compile and not interpret.
vasava is offline   Reply With Quote

Old   March 20, 2013, 09:59
Default
  #6
New Member
 
Mohamed Magdy Mohamed
Join Date: Jan 2013
Posts: 9
Rep Power: 13
M.Magdy is on a distinguished road
Hi Vasava,
Thanks for your reply but I'm afraid it didn't solve the problem.
if you could tell me whether I should in my case check the box beside "six DOF" in dynamic mesh options or not.
knowing that :
  • when i check it -----------> no waves are generated (the wall doesn't move)
  • when i uncheck it ---------> waves are generated but the floating body make no motion

    Thanks,
M.Magdy is offline   Reply With Quote

Old   March 21, 2013, 03:20
Default
  #7
Senior Member
 
Paritosh Vasava
Join Date: Oct 2012
Location: Lappeenranta, Finland
Posts: 732
Rep Power: 23
vasava will become famous soon enough
You say that mass of the box is 85167.33 (kg I suppose). Isnt that too heavy to be moved by wave of water?
vasava is offline   Reply With Quote

Old   March 22, 2013, 00:50
Default
  #8
New Member
 
Mohamed Magdy Mohamed
Join Date: Jan 2013
Posts: 9
Rep Power: 13
M.Magdy is on a distinguished road
No because the body is a cylinder of length 30m and diameter 3m and 4cm thickness
M.Magdy is offline   Reply With Quote

Old   March 28, 2013, 08:59
Default
  #9
New Member
 
Stefanos Katifeoglou
Join Date: Oct 2011
Location: Athens, Greece
Posts: 19
Rep Power: 15
stefanos is on a distinguished road
If you allow me, i would like to add a comment that may seem helpful, according to my experience.
Sometimes this occurs if the moving zones aren't adequately defined. In recent fluent editions you don't have to define the meanflow deforming zone. You just need to set the rigid body motion of the moving zone (the moving wall and/or a sourrounding moving fluid zone that includes the boundary layer, around the body, if turbulence modeling is employed). In addition, if there are edge zones recognized by fluent as borders between the rigid-deforming zones, they should also be introduced in the dynamic mesh zones panel as rigidly moving zones, according to the same udf.
stefanos is offline   Reply With Quote

Old   April 4, 2023, 13:00
Angry
  #10
New Member
 
Lucía
Join Date: Apr 2023
Posts: 7
Rep Power: 3
luciagalvez is on a distinguished road
I have the same problem and I cant find the problem. In my case I want to move one of the walls of a rectangle and my .cpp file is the following one:

#include "udf.h"
#include "dynamesh_tools.h"

DEFINE_CG_MOTION(wave,dt,cg_vel,cg_omega,time,dtim e)
{
cg_vel[0]=0.0;
cg_vel[1]=(0.12e-6*(sin( 20*3.1415927* time)));
cg_vel[2]=0.0;

cg_omega[0]=0.0;
cg_omega[1]=0.0;
cg_omega[2]=0.0;
}


And when I add to the dynamic mesh I obtain this message: Warning: incorrect grid motion UDF wave::libudf on zone 4 (assuming no motion)

If can anyone help. Thanks
luciagalvez 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
[Commercial meshers] Mesh conversion problem (fluent3DMeshToFoam) Aadhavan OpenFOAM Meshing & Mesh Conversion 2 March 8, 2018 02:47
Dynamic Mesh UDF Qureshi FLUENT 7 March 23, 2017 08:37
Moving mesh Niklas Wikstrom (Wikstrom) OpenFOAM Running, Solving & CFD 122 June 15, 2014 07:20
fluent probelm"mesh motion udf" bestrcsekhar Main CFD Forum 0 November 2, 2008 02:38
Sliding mesh error Karl Kevala FLUENT 4 February 21, 2001 16:52


All times are GMT -4. The time now is 14:59.