View Issue Details

IDProjectCategoryView StatusLast Update
0001284OpenFOAM[All Projects] Bugpublic2015-05-01 16:45
Reporteruser924Assigned Tohenry 
Status resolvedResolutionfixed 
PlatformLinuxOSUbuntuOS Version10.04
Product Version 
Fixed in Version 
Summary0001284: sixDoFRigBodyMotion can only rotate around the COG
DescriptionWithin sixDoFRigBodyMotion the point constraint has no logical effect, with rotation of the object only now occurring about the COG.

In Openfoam222 this worked perfectly, but in the update this functionality seems to have been dropped.
Steps To ReproduceLoad the Floating object tutorial. To help make the effect more obvious, adjust it so its a high thin box, which is still bouyant. Now try to fix a point at the bottom of the box, so the object can now only rotate back and forth - like a paddle.

Our constant/DynamicMeshDist looks like this:

    patches (ccell);
    innerDistance 0.3;
    outerDistance 1;

    centreOfMass (0 0 -0.5);
    momentOfInertia (1000 1000 1000);
    mass 75;

    accelerationRelaxation 0.3;

    rhoInf 1000;

    report on;
    value uniform (0 0 0);

             sixDoFRigidBodyMotionConstraint point;
             point (0 0 -0.75);

            sixDoFRigidBodyMotionConstraint axis;
            axis (0 1 0);

Additional InformationIn Openfoam222, there was a function called updateForce, which contains the following:

        a() = fGlobal/mass_;
        tau() = (Q().T() & tauGlobal);

This has been updated and now resides in a function called updateAcceleration, but now only contains:
        vector aPrevIter = a();
        vector tauPrevIter = tau();

        // Calculate new accelerations
        a() = fGlobal/mass_;
        tau() = (Q().T() & tauGlobal);

i.e. the 'applyConstraints(..)' function has been removed, and indeed this function has been completely deleted. I cannot therefore understand how this code is able to work, since surely it still needs to balance the forces that evolve from the different constraints. In our example, there must be a additional force about the bottom of the floating object that forces it to stay at the fixed point.


TagsNo tags attached.



2014-05-11 20:42

manager   ~0003052

> i.e. the 'applyConstraints(..)' function has been removed,
> and indeed this function has been completely deleted.

Correct, the old method of applying constraints by adjusting the forces leads to large high-frequency accelerations due to round-off error and other numerical noise in the position of the CofG which in some cases cased failure of the simulation. For example the DTC cases were not possible to solve reliably with the old 6-DoF constraint implementation.

The new approach is to create constraint tensors and apply those to the velocities to remove unwanted components which works very reliably for static constraints such as symmetry and line motion. However, this is not yet complete for dynamically varying constraints such as a point constraint not being at the CofG where the transformation tensors need to be updated according to the current position. The plan it to extend the constraints to provide additional tensors for such cases but this may not be sufficient as positional errors may accumulate and need to be corrected. The old approach handled this but with the correction being obtainded by a returning force to correct the error in 1 time-step the accelerations generated are large.particularly if the time-step is small. Some kind of relaxation could be applied but it would be better if the correction were applied diroctly to the position rather than via a force.


2014-05-16 15:37

manager   ~0003061

Resolved by commit 3207f8d0c7d83396cebf1958fb38de732c8b0307

Issue History

Date Modified Username Field Change
2014-05-09 23:48 user924 New Issue
2014-05-11 20:42 henry Note Added: 0003052
2014-05-16 15:37 henry Note Added: 0003061
2014-05-16 15:37 henry Status new => resolved
2014-05-16 15:37 henry Resolution open => fixed
2014-05-16 15:37 henry Assigned To => henry