|
[Sponsors] |
![]() |
![]() |
#1 |
New Member
Ian
Join Date: Aug 2018
Posts: 15
Rep Power: 8 ![]() |
Hi, everyone
Recently I am working on simulating a floating Object with 3-degree motion with RigidBodyMotion, but I have trouble in getting the motion amplitude and roll angle of the object. I have found there is a function object called SixDoFRigidBodyState, but it only works for SixDoFRigidBodyMotion, but I don't know if there any difference between those two libs, can someone tell me where can I find some script or tools to help me get the information? Thanks in advance! |
|
![]() |
![]() |
![]() |
![]() |
#2 |
Senior Member
Join Date: Oct 2017
Posts: 137
Rep Power: 9 ![]() |
Hi insane,
just a few days ago OpenFOAM.org added an equivalent functionObject for rigidBodyState: https://github.com/OpenFOAM/OpenFOAM...d19f6220801f09 So if you are able to use OpenFOAM-dev you could use this. Kind regards, Krapf |
|
![]() |
![]() |
![]() |
![]() |
#3 |
New Member
Ian
Join Date: Aug 2018
Posts: 15
Rep Power: 8 ![]() |
Hi.Krapf
Thank you for your timely reply, it does help me a lot! I'm trying to compile in the present version. |
|
![]() |
![]() |
![]() |
![]() |
#4 |
New Member
Cai Wei
Join Date: Jan 2018
Posts: 1
Rep Power: 0 ![]() |
Have you test it ?
|
|
![]() |
![]() |
![]() |
![]() |
#5 |
New Member
Ian
Join Date: Aug 2018
Posts: 15
Rep Power: 8 ![]() |
I have sucessfully achieve that in the latest version V1812 it works well
|
|
![]() |
![]() |
![]() |
![]() |
#6 |
New Member
Tanvir Sayeed
Join Date: Jan 2015
Posts: 9
Rep Power: 12 ![]() |
||
![]() |
![]() |
![]() |
![]() |
#7 |
New Member
Ian
Join Date: Aug 2018
Posts: 15
Rep Power: 8 ![]() |
1) download form the url Krapf put there
2) put the folder you download in the OpenFOAM src 3) modify the allwmake file add wmake $targetType rigidBodyState in the last 4) compile and fix it according to the compile information the detail of the process I am not sure after such a long time Good Luck! |
|
![]() |
![]() |
![]() |
![]() |
#8 | |
New Member
Tanvir Sayeed
Join Date: Jan 2015
Posts: 9
Rep Power: 12 ![]() |
Quote:
But when i run the tutorial "floatingObject", there was no data written in PostProcessing folder. The log.interFoam file states as follows: Using #calc at line 50 in file "/home/tanvir/Tanvir_test_cases/floatingObject/constant/dynamicMeshDict.rigidBodyMotionCoeffs.bodies.float ingObject" Using #codeStream with "/home/tanvir/Tanvir_test_cases/floatingObject/dynamicCode/platforms/linux64GccDPInt32Opt/lib/libcodeStream_61cbf2342e2af17e0533956d99753ec57f88 b4a3.so" Creating new library in "dynamicCode/_61cbf2342e2af17e0533956d99753ec57f88b4a3/platforms/linux64GccDPInt32Opt/lib/libcodeStream_61cbf2342e2af17e0533956d99753ec57f88 b4a3.so" Invoking wmake libso /home/tanvir/Tanvir_test_cases/floatingObject/dynamicCode/_61cbf2342e2af17e0533956d99753ec57f88b4a3 wmake libso /home/tanvir/Tanvir_test_cases/floatingObject/dynamicCode/_61cbf2342e2af17e0533956d99753ec57f88b4a3 ln: ./lnInclude dep: codeStreamTemplate.C Ctoo: codeStreamTemplate.C ld: /home/tanvir/Tanvir_test_cases/floatingObject/dynamicCode/_61cbf2342e2af17e0533956d99753ec57f88b4a3/../platforms/linux64GccDPInt32Opt/lib/libcodeStream_61cbf2342e2af17e0533956d99753ec57f88 b4a3.so Selecting dynamicFvMesh dynamicMotionSolverFvMesh Using #calc at line 50 in file "/home/tanvir/Tanvir_test_cases/floatingObject/constant/dynamicMeshDict.rigidBodyMotionCoeffs.bodies.float ingObject" Selecting motion solver: rigidBodyMotion Using #calc at line 50 in file "/home/tanvir/Tanvir_test_cases/floatingObject/constant/dynamicMeshDict.rigidBodyMotionCoeffs.bodies.float ingObject" Selecting rigidBodySolver Newmark --> FOAM Warning : Attempt to cast type rigidBodyMotion to type rigidBodyModel From function To& Foam::refCast(From&) [with To = const Foam::RBD::rigidBodyMotion; From = const Foam::motionSolver] in file /home/tanvir/OpenFOAM/OpenFOAM-v1906/src/OpenFOAM/lnInclude/typeInfo.H at line 138. From function bool Foam::functionObjectList::read() in file db/functionObjects/functionObjectList/functionObjectList.C at line 896 --> while loading function object 'rigidBodyState' Thanks again... |
||
![]() |
![]() |
![]() |
![]() |
#9 |
New Member
Ian
Join Date: Aug 2018
Posts: 15
Rep Power: 8 ![]() |
I am not sure if you add the corresponding functionObject in the controldict ? the template could be found in the .H file
|
|
![]() |
![]() |
![]() |
![]() |
#10 | |
New Member
Tanvir Sayeed
Join Date: Jan 2015
Posts: 9
Rep Power: 12 ![]() |
Quote:
rigidBodyState { type rigidBodyState; libs ("librigidBodyState.so"); angleFormat degrees; } Did you make any changes in src/rigidBodyDynamics or src/rigidBodyMeshMotion folders? Can you run that tutorial with proper output? |
||
![]() |
![]() |
![]() |
![]() |
#11 |
New Member
Ian
Join Date: Aug 2018
Posts: 15
Rep Power: 8 ![]() |
I guess you might have made some mistake in the compile procedure, I attach my RigidState file you can try to compile it to see if it works.
Good luck! |
|
![]() |
![]() |
![]() |
![]() |
#12 | |
New Member
Tanvir Sayeed
Join Date: Jan 2015
Posts: 9
Rep Power: 12 ![]() |
Quote:
When I compile your folder it shows error on "can't find 'BodyNames'..." which you must have solved as well... Is it possible to let me know your version and share your rigidBodyDynamics and rigidBodyMeshMotion folders as well. I again appreciate your help.. |
||
![]() |
![]() |
![]() |
![]() |
#13 |
New Member
Ian
Join Date: Aug 2018
Posts: 15
Rep Power: 8 ![]() |
Actually I am using this in OF1712 and OF1812 it all works.
Here are my two folders, you can try it again. Good Luck! |
|
![]() |
![]() |
![]() |
![]() |
#14 |
New Member
Tanvir Sayeed
Join Date: Jan 2015
Posts: 9
Rep Power: 12 ![]() |
||
![]() |
![]() |
![]() |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
2D Forced Roll Damping Simulation using FLUENT | Sunflower_Li | FLUENT | 0 | December 29, 2017 02:48 |
How to calculate oscillating roll of 2D body (with variable amplitude and omega) | lavrov | OpenFOAM Running, Solving & CFD | 0 | March 19, 2015 06:31 |