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

Applying restraints in openfoam

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By Yann

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 14, 2020, 09:16
Default Applying restraints in openfoam
  #1
New Member
 
Pouria Taghikhani
Join Date: Sep 2016
Posts: 14
Rep Power: 9
Taghi is on a distinguished road
Hi foamers.
I am trying to attach a rope to the object in floating object sample in blueCFD 2017_2 (OF 5).
I've added some lines to "dynamicMeshDict.sixDoF" file as below but it has no effect on the original tutorial answer.
Does anyone have any Idea how to apply these kind of restrains?
Code:
dynamicFvMesh       dynamicMotionSolverFvMesh;

motionSolverLibs    ("libsixDoFRigidBodyMotion.so");

motionSolver        sixDoFRigidBodyMotion;

sixDoFRigidBodyMotionCoeffs
{
    patches         (floatingObject);
    innerDistance   0.05;
    outerDistance   0.35;

    centreOfMass    (0.5 0.45 0.35);

    // Cuboid dimensions
    Lx              0.3;
    Ly              0.2;
    Lz              0.5;

    // Density of the solid
    rhoSolid        999;

    // Cuboid mass
    mass            #calc "$rhoSolid*$Lx*$Ly*$Lz";

    // Cuboid moment of inertia about the centre of mass
    momentOfInertia #codeStream
    {
        codeInclude
        #{
            #include "diagTensor.H"
        #};

        code
        #{
            scalar sqrLx = sqr($Lx);
            scalar sqrLy = sqr($Ly);
            scalar sqrLz = sqr($Lz);
            os  <<
                $mass
               *diagTensor(sqrLy + sqrLz, sqrLx + sqrLz, sqrLx + sqrLy)/12.0;
        #};
    };

    report          on;
    accelerationRelaxation 0.7;
    //accelerationDamping 0;

    solver
    {
        type Newmark;
    }

    constraints
    {
        // fixedPoint
        // {
        //     sixDoFRigidBodyMotionConstraint point;
        //     centreOfRotation (0.5 0.45 0.1);
        // }

        fixedLine
        {
            sixDoFRigidBodyMotionConstraint line;
            centreOfRotation (0.5 0.45 0.1);
            direction (0 1 0);
        }

        fixedAxis
        {
            sixDoFRigidBodyMotionConstraint axis;
            axis (0 1 0);
        }
    }
    restraints
{
    chain
    {
        sixDoFRigidBodyMotionRestraint  linearSpringDamper;
        refAttachmentPt     (0 0 0);
        anchor              table
        (
            (0         (0.3 0.2 0.5))
            (2         (0.3 0.2 0.5))
            (6         (0.3 0.2 0.5))
            (8         (0.3 0.2 0.5))

        );
        psi                 10;
        wn                  8.28;
        numberOfChains      4;
        restLength          0.6245;
    }
}
}
Taghi is offline   Reply With Quote

Old   February 17, 2020, 03:17
Default
  #2
Senior Member
 
Yann
Join Date: Apr 2012
Location: France
Posts: 1,066
Rep Power: 26
Yann will become famous soon enough
Hello Taghi,


Have you checked your allRun script and dynamicMeshDict file to see if there is any reference to the "dynamicMeshDict.sixDoF" file somewhere?


AFAIK, solvers only check for the constant/dynamicMeshDict, unless specified otherwise.


My best bet is that your dynamicMeshDict.sixDoF is simply not used at all in the tutorial you're running, but it's here to offer another setup for dynamic mesh. Replace your current dynamicMeshDict file with the content of your dynamicMeshDict.sixDoF file and see if it solves your problem.


Cheers,
Yann
Tobi likes this.
Yann is offline   Reply With Quote

Old   February 27, 2020, 12:09
Default
  #3
New Member
 
Pouria Taghikhani
Join Date: Sep 2016
Posts: 14
Rep Power: 9
Taghi is on a distinguished road
Tnx a zillion times
"dynamicMeshDict.sixDoF" was meant to be replaced to "dynamicMeshDict".
problem solved
Taghi is offline   Reply With Quote

Reply

Tags
chain, floating body, floating object, restraints, rope


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
How to contribute to the community of OpenFOAM users and to the OpenFOAM technology wyldckat OpenFOAM 17 November 10, 2017 15:54
OpenFOAM v3.0+ ?? SBusch OpenFOAM 22 December 26, 2016 14:24
OpenFOAM Training Beijing 22-26 Aug 2016 cfd.direct OpenFOAM Announcements from Other Sources 0 May 3, 2016 04:57
OpenFOAM Training in Europe and USA hjasak OpenFOAM 0 August 8, 2008 05:33
OpenFOAM Debian packaging current status problems and TODOs oseen OpenFOAM Installation 9 August 26, 2007 13:50


All times are GMT -4. The time now is 13:28.