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

Sdof

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 28, 2016, 04:27
Question Sdof
  #1
New Member
 
' w '
Join Date: Apr 2015
Posts: 6
Rep Power: 10
wanis is on a distinguished road
Hello members,
I have tried to compile this UDF but, it seems that there is a problem coding. therefore plz if i can get help to debug it I would appreciate.
Addition info:
I want to change the mass value respect to the time or the value of F_Y as stated in the program, let's say the mass is 100 gram then after certain time will be 90 gram and so on; so if any one here can advice me how? Also if there is any suggestion to re-correct .
Here is my UDF.

The Object is Moving in Three dimensions ( x, y and Z), so the CG will be changed during the motion, so that is why I need to define F_Y depends of CG changes HOW????


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


DEFINE_SDOF_PROPERTIES(Object_prop, prop, dt, time, dtime)
{
real mass;
real G;
mass = 0.2986;
G = 9.81;
cg = DT_CG(dt)[1];


prop[SDOF_MASS] = mass;
prop[SDOF_IXX] = 0.00178849;
prop[SDOF_IYY] = 0.00179058;
prop[SDOF_IZZ] = 0.00166991;
prop[SDOF_ZERO_TRANS_X] = FALSE; /* boolean, suppress translation in x-direction */
prop[SDOF_ZERO_TRANS_Y] = FALSE; /* boolean, suppress translation in y-direction */
prop[SDOF_ZERO_TRANS_Z] = FALSE; /* boolean, suppress translation in y-direction */

prop[SDOF_IXY] = 0.0; /* -0.00000003;*/
prop[SDOF_IXZ] = 0.0; /* 0.00000000;*/
prop[SDOF_IYZ] = 0.0; /* 0.00000000;*/

/* Change mass value */
{
register real F_Y ;
F_Y = mass * G
{
Prop [SDOF_LOAD_F_Y]=F_Y;
}
if (F_Y < mass*G)
{
prop[SDOF_MASS] = mass - 0.01;
}

printf ("\nObject_Prop: Updated 6DOF properties");

Last edited by wanis; May 28, 2016 at 05:17. Reason: Adding info
wanis is offline   Reply With Quote

Old   June 16, 2016, 13:16
Default
  #2
New Member
 
' w '
Join Date: Apr 2015
Posts: 6
Rep Power: 10
wanis is on a distinguished road
Hello,

I have no idea about to solve the problem yet, i hope u to help me
wanis is offline   Reply With Quote

Old   March 6, 2017, 22:04
Default sdof problem
  #3
New Member
 
betoche
Join Date: Jun 2016
Posts: 5
Rep Power: 9
hesam267 is on a distinguished road
Hi.
can anyone explain simple example of SDOF function Please?
i coudnt solve any problem with this udf because of Dynamic mesh error.
can you clear it with for example one cylindrical (or any other shape) in water bowl?
i think i do something wrong in create dynamic mesh zone.
hesam267 is offline   Reply With Quote

Old   July 5, 2017, 13:23
Default Sdof error and some explanation
  #4
New Member
 
thibaut
Join Date: Mar 2017
Posts: 2
Rep Power: 0
alleau is on a distinguished road
Hi all,

Wanis : I think your error is coming from :
F_Y = mass * G
{
Prop [SDOF_LOAD_F_Y]=F_Y;
}

which is not correct. Maybe someting like
if(F_Y == mass * G)
{
Prop [SDOF_LOAD_F_Y]=F_Y;
}
should work, but i don't know if it's what you mean.

hesam267, for the explanation of the SDOF solver, it computes fluid external load and momentum on a solid, define as a wall in fluent.
Your error can come from a time discretisation. For example, if your solid is moving faster than your mesh is reform, you might have a negative cell volume.
Hope this help
alleau is offline   Reply With Quote

Reply

Tags
udf and programming


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
Force on moving body joechorn Fluent UDF and Scheme Programming 5 April 2, 2015 11:25
WILLING TO PAY/ FREELANCER REQUIRED / small UDF coding force loads over body / 6DOF acasas CFD Freelancers 1 January 23, 2015 07:26
trouble in SDOF solver vga67 FLUENT 0 March 9, 2014 04:23
problem in SDOF Sydronlee FLUENT 0 February 7, 2014 22:01
sdof Grigor Nikolov FLUENT 0 August 1, 2013 05:50


All times are GMT -4. The time now is 10:45.