FreeFOAM The Cross-Platform CFD Toolkit
Hosted by SourceForge:
Get FreeFOAM at SourceForge.net.
            Fast, secure and Free Open Source software downloads

SDA.H

Go to the documentation of this file.
00001 /*---------------------------------------------------------------------------*\
00002   =========                 |
00003   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
00004    \\    /   O peration     |
00005     \\  /    A nd           | Copyright (C) 1991-2010 OpenCFD Ltd.
00006      \\/     M anipulation  |
00007 -------------------------------------------------------------------------------
00008 License
00009     This file is part of OpenFOAM.
00010 
00011     OpenFOAM is free software: you can redistribute it and/or modify it
00012     under the terms of the GNU General Public License as published by
00013     the Free Software Foundation, either version 3 of the License, or
00014     (at your option) any later version.
00015 
00016     OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
00017     ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00018     FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
00019     for more details.
00020 
00021     You should have received a copy of the GNU General Public License
00022     along with OpenFOAM.  If not, see <http://www.gnu.org/licenses/>.
00023 
00024 Class
00025     Foam::solidBodyMotionFunctions::SDA
00026 
00027 Description
00028     Ship design analysis (SDA) 3DoF motion function.
00029 
00030     Comprising sinusoidal roll (rotation about x), heave (z-translation)
00031     and sway (y-translation) motions with changing amplitude and phase.
00032 
00033 See Also
00034     SKA (Sea Keeping Analysis) for 6DoF motion.
00035 
00036 SourceFiles
00037     SDA.C
00038 
00039 \*---------------------------------------------------------------------------*/
00040 
00041 #ifndef SDA_H
00042 #define SDA_H
00043 
00044 #include <dynamicFvMesh/solidBodyMotionFunction.H>
00045 
00046 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00047 
00048 namespace Foam
00049 {
00050 namespace solidBodyMotionFunctions
00051 {
00052 
00053 /*---------------------------------------------------------------------------*\
00054                           Class SDA Declaration
00055 \*---------------------------------------------------------------------------*/
00056 
00057 class SDA
00058 :
00059     public solidBodyMotionFunction
00060 {
00061     // Private data
00062 
00063         //- Center of gravity
00064         vector CofG_;
00065 
00066         //- Model scale ratio
00067         scalar lamda_;
00068 
00069         //- Max roll amplitude [rad]
00070         scalar rollAmax_;
00071 
00072         //- Min roll amplitude [rad]
00073         scalar rollAmin_;
00074 
00075         //- Heave amplitude [m]
00076         scalar heaveA_;
00077 
00078         //- Sway amplitude [m]
00079         scalar swayA_;
00080 
00081         //- Damping Coefficient [-]
00082         scalar Q_;
00083     
00084         //- Time Period for liquid [sec]
00085         scalar Tp_;
00086 
00087         //- Natural Period of Ship [sec]
00088         scalar Tpn_;
00089 
00090         //- Reference time step [sec]
00091         scalar dTi_;
00092 
00093         //- Incr. in Tp/unit 'dTi'[-]
00094         scalar dTp_;
00095 
00096 
00097     // Private Member Functions
00098 
00099         //- Disallow copy construct
00100         SDA(const SDA&);
00101 
00102         //- Disallow default bitwise assignment
00103         void operator=(const SDA&);
00104 
00105 
00106 public:
00107 
00108     //- Runtime type information
00109     TypeName("SDA");
00110 
00111 
00112     // Constructors
00113 
00114         //- Construct from components
00115         SDA
00116         (
00117             const dictionary& SBMFCoeffs,
00118             const Time& runTime
00119         );
00120 
00121 
00122     // Destructor
00123 
00124         virtual ~SDA();
00125 
00126 
00127     // Member Functions
00128 
00129         //- Return the solid-body motion transformation septernion
00130         virtual septernion transformation() const;
00131 
00132         //- Update properties from given dictionary
00133         virtual bool read(const dictionary& SBMFCoeffs);
00134 };
00135 
00136 
00137 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00138 
00139 } // End namespace solidBodyMotionFunctions
00140 } // End namespace Foam
00141 
00142 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00143 
00144 #endif
00145 
00146 // ************************ vim: set sw=4 sts=4 et: ************************ //
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines