/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  v2212                                 |
|   \\  /    A nd           | Website:  www.openfoam.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    object      dynamicMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dynamicFvMesh   dynamicMotionSolverFvMesh;

motionSolverLibs (sixDoFRigidBodyMotion);

motionSolver    sixDoFRigidBodyMotion;

// Not necessarily useful here, but can have different motion updates types
updateControl   timeStep;
updateInterval  1;


patches         (wing);
innerDistance   0.3;
outerDistance   1;

mass            22.9;
centreOfMass    (0.25 0.007 0.125);
momentOfInertia (1.958864357 3.920839234 2.057121362);
orientation
(
    0.9953705935 0.09611129781 0
    -0.09611129781 0.9953705935 0
    0 0 1
);
angularMomentum (0 0 0);
g               (0 0 0);
rho             rhoInf;
rhoInf          1.225;
report          on;

solver
{
    //type symplectic; //2nd order explicit
    type     Newmark; //2nd order implicit with outer correction
    gamma    0.5; //Velocity integration coefficient
    beta     0.25; //Position integration coefficient

}

constraints
{
    
    fixedLine1
    {
        sixDoFRigidBodyMotionConstraint line;
        direction     (0 1 0);
    }

    fixedAxis1
    {
        sixDoFRigidBodyMotionConstraint orientation;//fixedAxis;
        tolerance       1e-06;
        relaxationFactor 0.7;
        fixedOrientationCoeffs {}
    }
}

restraints
{
    
    verticalSpring
    {
        sixDoFRigidBodyMotionRestraint nonLinearSpring;

        anchor          (0.25 0.007 0.125);
        refAttachmentPt (0.25 0.007 0.125);
        dampingModelType linear;
        c1              2;
        restLength      0;
        modelType       stiffnessList;

        stiffnessList
        {
            interpolationType linear;
            outOfBounds       EXTRAPOLATE;

            values
            (
                ( -0.123784	-9681.40804968083)
                ( -0.123701	-9583.61604968083)
                ( -0.123618	-9485.82404790651)
                ( -0.123535	-9388.03204790651)
                ( -0.123453	-9290.24004790651)
                ( -0.12337	-9192.4480461322)
                ( -0.123287	-9094.6560461322)
                ( -0.123204	-8996.8640461322)
                ( -0.123121	-8899.0720461322)
                ( -0.123038	-8801.28004435788)
                ( -0.122956	-8703.48804435788)
                ( -0.122873	-8605.69604435788)
                ( -0.12279	-8507.90404435788)
                ( -0.122707	-8410.11204258357)
                ( -0.122624	-8312.32004258357)
                ( -0.122541	-8214.52804258357)
                ( -0.122459	-8116.73604080925)
                ( -0.122376	-8018.94404080925)
                ( -0.122293	-7921.15204080925)
                ( -0.12221	-7823.36004080925)
                ( -0.122126	-7725.56803903494)
                ( -0.12204	-7627.77603903494)
                ( -0.121951	-7529.98403903494)
                ( -0.121859	-7432.19203726062)
                ( -0.121765	-7334.40003726062)
                ( -0.121667	-7236.60803726062)
                ( -0.121567	-7138.81603726062)
                ( -0.121464	-7041.02403548631)
                ( -0.121358	-6943.2320354863)
                ( -0.121248	-6845.44003548631)
                ( -0.121135	-6747.64803371199)
                ( -0.121018	-6649.85603371199)
                ( -0.120897	-6552.06403371199)
                ( -0.120773	-6454.27203371199)
                ( -0.120644	-6356.48003193767)
                ( -0.120511	-6258.68803193768)
                ( -0.120373	-6160.89603193768)
                ( -0.120231	-6063.10403016336)
                ( -0.120083	-5965.31203016336)
                ( -0.119931	-5867.52003016336)
                ( -0.119773	-5769.72803016336)
                ( -0.119609	-5671.93602838904)
                ( -0.119439	-5574.14402838904)
                ( -0.119263	-5476.35202838905)
                ( -0.11908	-5378.56002838904)
                ( -0.11889	-5280.76802661473)
                ( -0.118693	-5182.97602661473)
                ( -0.118488	-5085.18402661473)
                ( -0.118275	-4987.39202484041)
                ( -0.118053	-4889.60002484041)
                ( -0.117822	-4791.80802484041)
                ( -0.117582	-4694.01602484041)
                ( -0.117331	-4596.2240230661)
                ( -0.117069	-4498.4320230661)
                ( -0.116796	-4400.6400230661)
                ( -0.116511	-4302.84802129178)
                ( -0.116213	-4205.05602129178)
                ( -0.115901	-4107.26402129178)
                ( -0.115575	-4009.47202129178)
                ( -0.115233	-3911.68001951747)
                ( -0.114874	-3813.88801951747)
                ( -0.114498	-3716.09601951747)
                ( -0.114103	-3618.30401774315)
                ( -0.113687	-3520.51201774315)
                ( -0.113249	-3422.72001774315)
                ( -0.112789	-3324.92801774315)
                ( -0.112303	-3227.13601596884)
                ( -0.111789	-3129.34401596884)
                ( -0.111247	-3031.55201596884)
                ( -0.110673	-2933.76001419452)
                ( -0.110064	-2835.96801419452)
                ( -0.109419	-2738.17601419452)
                ( -0.108733	-2640.38401419452)
                ( -0.108003	-2542.59201242021)
                ( -0.107224	-2444.80001242021)
                ( -0.106393	-2347.00801242021)
                ( -0.105504	-2249.21601064589)
                ( -0.104551	-2151.42401064589)
                ( -0.103527	-2053.63201064589)
                ( -0.102425	-1955.84001064589)
                ( -0.101236	-1858.04800887158)
                ( -0.099949	-1760.25600887158)
                ( -0.098554	-1662.46400887158)
                ( -0.097035	-1564.67200887158)
                ( -0.095376	-1466.88000709726)
                ( -0.093559	-1369.08800709726)
                ( -0.091558	-1271.29600709726)
                ( -0.089347	-1173.50400532295)
                ( -0.08689	-1075.71200532295)
                ( -0.084143	-977.920005322946)
                ( -0.081053	-880.128005322946)
                ( -0.077547	-782.336003548631)
                ( -0.073532	-684.544003548631)
                ( -0.068882	-586.75200354863)
                ( -0.063418	-488.960001774315)
                ( -0.056876	-391.168001774315)
                ( -0.048836	-293.376001774315)
                ( -0.038557	-195.584001774315)
                ( -0.024448	-97.792)
                ( 0	0)
                ( 0.024448	97.792)
                ( 0.038557	195.584001774315)
                ( 0.048836	293.376001774315)
                ( 0.056876	391.168001774315)
                ( 0.063418	488.960001774315)
                ( 0.068882	586.75200354863)
                ( 0.073532	684.544003548631)
                ( 0.077547	782.336003548631)
                ( 0.081053	880.128005322946)
                ( 0.084143	977.920005322946)
                ( 0.08689	1075.71200532295)
                ( 0.089347	1173.50400532295)
                ( 0.091558	1271.29600709726)
                ( 0.093559	1369.08800709726)
                ( 0.095376	1466.88000709726)
                ( 0.097035	1564.67200887158)
                ( 0.098554	1662.46400887158)
                ( 0.099949	1760.25600887158)
                ( 0.101236	1858.04800887158)
                ( 0.102425	1955.84001064589)
                ( 0.103527	2053.63201064589)
                ( 0.104551	2151.42401064589)
                ( 0.105504	2249.21601064589)
                ( 0.106393	2347.00801242021)
                ( 0.107224	2444.80001242021)
                ( 0.108003	2542.59201242021)
                ( 0.108733	2640.38401419452)
                ( 0.109419	2738.17601419452)
                ( 0.110064	2835.96801419452)
                ( 0.110673	2933.76001419452)
                ( 0.111247	3031.55201596884)
                ( 0.111789	3129.34401596884)
                ( 0.112303	3227.13601596884)
                ( 0.112789	3324.92801774315)
                ( 0.113249	3422.72001774315)
                ( 0.113687	3520.51201774315)
                ( 0.114103	3618.30401774315)
                ( 0.114498	3716.09601951747)
                ( 0.114874	3813.88801951747)
                ( 0.115233	3911.68001951747)
                ( 0.115575	4009.47202129178)
                ( 0.115901	4107.26402129178)
                ( 0.116213	4205.05602129178)
                ( 0.116511	4302.84802129178)
                ( 0.116796	4400.6400230661)
                ( 0.117069	4498.4320230661)
                ( 0.117331	4596.2240230661)
                ( 0.117582	4694.01602484041)
                ( 0.117822	4791.80802484041)
                ( 0.118053	4889.60002484041)
                ( 0.118275	4987.39202484041)
                ( 0.118488	5085.18402661473)
                ( 0.118693	5182.97602661473)
                ( 0.11889	5280.76802661473)
                ( 0.11908	5378.56002838904)
                ( 0.119263	5476.35202838905)
                ( 0.119439	5574.14402838904)
                ( 0.119609	5671.93602838904)
                ( 0.119773	5769.72803016336)
                ( 0.119931	5867.52003016336)
                ( 0.120083	5965.31203016336)
                ( 0.120231	6063.10403016336)
                ( 0.120373	6160.89603193768)
                ( 0.120511	6258.68803193768)
                ( 0.120644	6356.48003193767)
                ( 0.120773	6454.27203371199)
                ( 0.120897	6552.06403371199)
                ( 0.121018	6649.85603371199)
                ( 0.121135	6747.64803371199)
                ( 0.121248	6845.44003548631)
                ( 0.121358	6943.2320354863)
                ( 0.121464	7041.02403548631)
                ( 0.121567	7138.81603726062)
                ( 0.121667	7236.60803726062)
                ( 0.121765	7334.40003726062)
                ( 0.121859	7432.19203726062)
                ( 0.121951	7529.98403903494)
                ( 0.12204	7627.77603903494)
                ( 0.122126	7725.56803903494)
                ( 0.12221	7823.36004080925)
                ( 0.122293	7921.15204080925)
                ( 0.122376	8018.94404080925)
                ( 0.122459	8116.73604080925)
                ( 0.122541	8214.52804258357)
                ( 0.122624	8312.32004258357)
                ( 0.122707	8410.11204258357)
                ( 0.12279	8507.90404435788)
                ( 0.122873	8605.69604435788)
                ( 0.122956	8703.48804435788)
                ( 0.123038	8801.28004435788)
                ( 0.123121	8899.0720461322)
                ( 0.123204	8996.8640461322)
                ( 0.123287	9094.6560461322)
                ( 0.12337	9192.4480461322)
                ( 0.123453	9290.24004790651)
                ( 0.123535	9388.03204790651)
                ( 0.123618	9485.82404790651)
                ( 0.123701	9583.61604968083)
                ( 0.123784	9681.40804968083)
            );
        }
    }
}


// ************************************************************************* //
