CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

How to use sixDoFRigidBodyDisplacement?

Register Blogs Community New Posts Updated Threads Search

Like Tree14Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 28, 2010, 13:21
Exclamation How to use sixDoFRigidBodyDisplacement?
  #1
DLC
Member
 
Davide Lupo Conti
Join Date: Nov 2009
Posts: 34
Rep Power: 16
DLC is on a distinguished road
Hi Foamers!
i am playing with OF 1.7 and particularly with the tutorial regarding the floating object.
Does anyone know how to use restrains and constraints?
The new six DOF (sixDoFRigidBodyDisplacement) is told to be very nice, but I couldnt understand how to use it!
Can anyone please help?

Thanks a lot!
DLC
shincoast likes this.
DLC is offline   Reply With Quote

Old   August 2, 2010, 10:00
Default
  #2
New Member
 
mikael
Join Date: Jun 2010
Posts: 18
Rep Power: 15
keul is on a distinguished road
Hi DLC!

I'm working on cases which uses sixDoFRigidBodyDisplacement. You could look at the tutorial case "wingMotion" or "wingFlutter" in pimpleDyMFoam in the pointDisplacement file. You have different options.
In "constraint" you could fixe any degree of freedom. For example:
"fixedAxis" fixes one rotation along axis
"fixedPlane" fixes two translations
...

In "restraint" you could define a spring and/or a damp in any direction :
"linearSpring": you define an anchor, an attachment point on the moving body, a restlength, a stiffness and/or a damp.
"linearAxialAngularSpring": you apply a spring and/or a damp on moment along an axis.
...
You can find the source files at:
~/OpenFOAM/OpenFOAM-1.6.x/src/postProcessing/functionObjects/forces/pointPatchFields/derived

If you have any question...

Good Luck!
keul is offline   Reply With Quote

Old   August 2, 2010, 10:15
Default
  #3
DLC
Member
 
Davide Lupo Conti
Join Date: Nov 2009
Posts: 34
Rep Power: 16
DLC is on a distinguished road
Hi Keul!
thanks for the reply!
I managed to do what I was trying on friday evening, after going crazy for a whole day! (I couldn't find the sources..)
Thanks again!
DLC
DLC is offline   Reply With Quote

Old   August 10, 2010, 17:58
Default question on dampening
  #4
Senior Member
 
Dave
Join Date: Jul 2010
Posts: 100
Rep Power: 15
daveatstyacht is on a distinguished road
Hi all,
I was just curious if the dampening terms for the springs were given as a fraction of critical dampening (ie: a damping of 1.0 equating to critically damped and greater than 1.0 over-damped)? Also thanks for this posting, it has indirectly helped me to discover the location of the components I need to solve another problem of mine related to the forces/moments acting on an object (now to actually figure out the c++ to implement what I want ).

Regards,
Dave
daveatstyacht is offline   Reply With Quote

Old   August 11, 2010, 03:26
Default
  #5
New Member
 
mikael
Join Date: Jun 2010
Posts: 18
Rep Power: 15
keul is on a distinguished road
Hi Dave,

I don't use the damping yet. So I can't answer you. But you could find an answer with a simple case. For example, you could fixe a moving mesh with a spring without fluid and study the oscillation.

Best regards
keul is offline   Reply With Quote

Old   August 11, 2010, 05:45
Default
  #6
Senior Member
 
Dave
Join Date: Jul 2010
Posts: 100
Rep Power: 15
daveatstyacht is on a distinguished road
In answer to my own question, after looking around in the sixDoFRigidBodyMotionRestraint/linearSpring file I believe it (damping) has units of N*s/m based on the lines below:

vector r = restraintPosition - anchor_;

scalar magR = mag(r);

// r is now the r unit vector
r /= (magR + VSMALL);

vector v = motion.currentVelocity(restraintPosition);

restraintForce = -stiffness_*(magR - restLength_)*r - damping_*(r & v)*r;

Therefore, I believe that damping is equal to "c" in the equation for harmonic motion.

Thanks for the reply and I may yet try to confirm the units still to confirm that I am not mistaken.

Regards,
-Dave
dupeng and mo_na like this.
daveatstyacht is offline   Reply With Quote

Old   August 17, 2010, 05:55
Default
  #7
DLC
Member
 
Davide Lupo Conti
Join Date: Nov 2009
Posts: 34
Rep Power: 16
DLC is on a distinguished road
Hi everyone,
I have a very short question for you. I'm interested in printing at every iteration the body orientation. I found that this sixDof works with tensor Q for orientation. I would be interested in angles (degrees or radiant) such as Euler angles or other, to have a more physical flavor... does anyone know if there is in the sixDof such variable?
thanks!

DLC
DLC is offline   Reply With Quote

Old   August 17, 2010, 07:58
Default
  #8
New Member
 
mikael
Join Date: Jun 2010
Posts: 18
Rep Power: 15
keul is on a distinguished road
Hi DLC,

I don't think OF could give you the Euler angles. But if you have the matrix rotation you could find the Euler angles and maybe compute the source files to give you results at each iteration. I don't know if it will help you!

best regards
keul is offline   Reply With Quote

Old   November 20, 2010, 06:04
Default
  #9
DLC
Member
 
Davide Lupo Conti
Join Date: Nov 2009
Posts: 34
Rep Power: 16
DLC is on a distinguished road
Hello to everyone!
I'm writing now my master thesis and I need to describe the 6DOF implemented in OF.
I'm actually struggling to fully understand the algorithm from the code. Can anyone give me a hand? does anyone know where I can find anything already written on the 6dof in OF 1.7?
any reply can be of great help!
thanks a lot!

DLC
DLC is offline   Reply With Quote

Old   November 23, 2010, 05:00
Default
  #10
Member
 
Rasoul
Join Date: Feb 2010
Posts: 32
Rep Power: 16
aut_iut is on a distinguished road
Hi David,

I'm interested to have such report. If you find something please share it with us.
Thanks,

Rasoul
aut_iut is offline   Reply With Quote

Old   April 1, 2011, 10:28
Default
  #11
Member
 
Dan
Join Date: Oct 2010
Location: UK
Posts: 41
Rep Power: 15
dandalf is on a distinguished road
Hi all..

I'm working on a problem involving multibody dynamics,
I have an equation which solves the multibody dynamics of my particular system.
Giving me all the perameters in
sixDoFRigidBodyMotionState

I want to use it in a dynamicMotionSolverFvMesh, for which the following patch types were offered
p, li { white-space: pre-wrap; }
Code:
22
 (
 angularOscillatingDisplacement
 angularOscillatingVelocity
 calculated
 cyclic
 empty
 fixedValue
 global
 mixed
 oscillatingDisplacement
 oscillatingVelocity
 processor
 sixDoFRigidBodyDisplacement
 slip
 surfaceDisplacement
 surfaceSlipDisplacement
 symmetryPlane
 timeVaryingUniformFixedValue
 uncoupledSixDoFRigidBodyDisplacement
 uniformFixedValue
 value
 wedge
 zeroGradient
 )
The only native options that seems to offer the use of this is are
sixDoFRidgidBodyDisplacment and
uncoupledSixDoFRigidBodyDisplacement

Is there a way to determine motion on a patch, by pescribing the variables for sixDoFRigidBodyMotionState on each iteration. preferably from a file written on the fly?

Or is there a simpler solution.

any suggestions would be appreciated.

Dandalf
dandalf is offline   Reply With Quote

Old   August 5, 2011, 06:58
Default
  #12
Member
 
Ben Vernieres
Join Date: Jul 2011
Location: Valencia, Spain
Posts: 42
Rep Power: 14
bouclette is on a distinguished road
Send a message via Skype™ to bouclette
Hi Dan,

Not sure if you've solved your issue since its been a while since then but if not, check that you have all the required libs in your controlDict file.

Regards,

Ben
bouclette is offline   Reply With Quote

Old   September 20, 2011, 10:52
Default
  #13
Senior Member
 
lakeat's Avatar
 
Daniel WEI (老魏)
Join Date: Mar 2009
Location: Beijing, China
Posts: 689
Blog Entries: 9
Rep Power: 21
lakeat is on a distinguished road
Send a message via Skype™ to lakeat
Quote:
Originally Posted by DLC View Post
Hello to everyone!
I'm writing now my master thesis and I need to describe the 6DOF implemented in OF.
I'm actually struggling to fully understand the algorithm from the code. Can anyone give me a hand? does anyone know where I can find anything already written on the 6dof in OF 1.7?
any reply can be of great help!
thanks a lot!

DLC
The code follows a paper's procedure as mentioned in their H file, Im not from their field (I'm civil engineer), I wonder if any of you are from that field?
__________________
~
Daniel WEI
-------------
Boeing Research & Technology - China
Beijing, China
Email
lakeat is offline   Reply With Quote

Old   September 20, 2011, 10:57
Default
  #14
Senior Member
 
lakeat's Avatar
 
Daniel WEI (老魏)
Join Date: Mar 2009
Location: Beijing, China
Posts: 689
Blog Entries: 9
Rep Power: 21
lakeat is on a distinguished road
Send a message via Skype™ to lakeat
The constraint does not work as the word implies, so I am quite confused.
I mean, you constrain a axis, and the body can still move around that axis, this is absurd, or I am missing something?

Another question is: Is this method only works for the solid bodies that with kind of symmetries? I have some object that I1 ~ I2 >> I3, is it going to work?
Thanks,
__________________
~
Daniel WEI
-------------
Boeing Research & Technology - China
Beijing, China
Email
lakeat is offline   Reply With Quote

Old   October 6, 2011, 18:52
Default
  #15
Senior Member
 
Dave
Join Date: Jul 2010
Posts: 100
Rep Power: 15
daveatstyacht is on a distinguished road
Daniel,
The constraint axis is paradoxically the axis you allow rotation or movement for. If you are interested in more than one axis of motion for rotation and translation there are other BC like fixedPlane. I cant claim to know them all. Hope that helps.
Dave
daveatstyacht is offline   Reply With Quote

Old   October 6, 2011, 19:34
Default
  #16
Senior Member
 
lakeat's Avatar
 
Daniel WEI (老魏)
Join Date: Mar 2009
Location: Beijing, China
Posts: 689
Blog Entries: 9
Rep Power: 21
lakeat is on a distinguished road
Send a message via Skype™ to lakeat
Quote:
Originally Posted by daveatstyacht View Post
Daniel,
The constraint axis is paradoxically the axis you allow rotation or movement for. If you are interested in more than one axis of motion for rotation and translation there are other BC like fixedPlane. I cant claim to know them all. Hope that helps.
Dave


What?
I don't think so.

After several tests, I checked the codes and it seems quite misleading. Okay, here are my finding, I hope this is helpful. And also I wish someone could look into it.

1. line constraint (1 0 0), actually means constraint y direction,
2. line constraint (0 1 0), actually means constraint x direction,

(You don't agree with this? Okay, how about this you constraint both, and you will see that they are both locked, not what you imagined, that there will be two degrees in x and y. And if you delete these two constraints, you will find that they are released, you will get 2 degree of freedom.)

3. axis constraint, behaves just as what you mentioned "paradoxically".

So, quite misleading, aren't they?


I bet many of you know ansys, right, a company who aquires Fluent! In ANSYS, constraint simply means constarint, literally enough, like DX, DY, ROTZ...


Please correct me if I was wrong.
Best,
__________________
~
Daniel WEI
-------------
Boeing Research & Technology - China
Beijing, China
Email
lakeat is offline   Reply With Quote

Old   October 6, 2011, 22:40
Default
  #17
Senior Member
 
Dave
Join Date: Jul 2010
Posts: 100
Rep Power: 15
daveatstyacht is on a distinguished road
Daniel,
Below is the code I use to provide free to trim and heave motion in 1.7.1 (z translation and y axis rotation). The way to produce two translation freedoms is a fixedplane constraint if I recall correctly. A fixed line constraint only allows translation along that one axis. If you use two fixedline constraints you will effectively over constrain the object and it cant move as you have seen. It prevents translation in the other two directions. I don't know why they developed the constraints in this manner.

fixedLine1
{
sixDoFRigidBodyMotionConstraint fixedLine;
tolerance 1e-6;
relaxationFactor 0.7;
fixedLineCoeffs
{
refPoint (-3.23 0 1.21);
direction (0 0 1);
}
}

fixedAxis1
{
sixDoFRigidBodyMotionConstraint fixedAxis;
tolerance 1e-06;
relaxationFactor 0.7;
fixedAxisCoeffs
{
axis ( 0 1 0 );
}
}

I hope this helps.
Dave
sharonyue and IFX21 like this.
daveatstyacht is offline   Reply With Quote

Old   October 6, 2011, 23:06
Default
  #18
Senior Member
 
lakeat's Avatar
 
Daniel WEI (老魏)
Join Date: Mar 2009
Location: Beijing, China
Posts: 689
Blog Entries: 9
Rep Power: 21
lakeat is on a distinguished road
Send a message via Skype™ to lakeat
Thanks, but I think this is really funny, very funny.

And how could you explain this, if you delete all the fixedLine entries, and the body will move freely?

That's paper's motivation in using Simplectic method really makes this ODE problem complicated.
__________________
~
Daniel WEI
-------------
Boeing Research & Technology - China
Beijing, China
Email
lakeat is offline   Reply With Quote

Old   January 2, 2013, 11:44
Default
  #19
New Member
 
Luca Bonfiglio
Join Date: Oct 2011
Posts: 9
Rep Power: 14
lucaBonfiglio is on a distinguished road
Hi foamers,

I would like to fix only one motion (roll), having pitch and yaw free to move. I tried to fix the x axis :

constraints
{
maxIterations 500;
fixedAxis1
{
sixDoFRigidBodyMotionConstraint fixedAxis;
tolerance 1e-06;
relaxationFactor 0.7;
fixedAxisCoeffs
{
axis ( 1 0 0 );
}
}
}

But it didn't work out.
It seems that the roll motion is the only one that is allowed.
I tried to put two fixedAxis: one in the direction (0 1 0) and one in the direction (0 0 1). But in this way it seems that the body can no longer rotate in any direction.

Does anybody have any suggestions??

Regards
lucaBonfiglio is offline   Reply With Quote

Old   February 7, 2013, 00:36
Default
  #20
New Member
 
Md. Naimul Haque
Join Date: Jan 2013
Posts: 14
Rep Power: 13
najunaju is on a distinguished road
Hai Mr. Luca Bonfiglio,

Did you get anyway to solve your problem?

Here is some explanation. As discussed before, through fixedAxis and fixedLines you can only mention the axis along which object may rotate and translate, respectively. But criteria is only one axis and other two axis are fixed. That means, when you put two fixedAxis or two fixedLines you are completely fixing the object in-terms of rotation or translation respectively.

When you want, two free axis movement and one constrained axis then you have to use fixedPlane.

I might be wrong, correct me if so.

By the way, do you know how to deal with constrain tensor? I am really struggling on that.

best wishes,
najunaju is offline   Reply With Quote

Reply

Tags
contstraints, restraints, sixdof, sixdofrigidbody


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



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