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::STARCDCoordinateRotation 00026 00027 Description 00028 A coordinateRotation defined by the STAR-CD convention. 00029 00030 The 3 rotations are defined in the STAR-CD convention 00031 (around Z, around X' and around Y''). 00032 The order of the parameter arguments matches this rotation order. 00033 00034 - the rotation angles are in degrees, unless otherwise explictly specified: 00035 00036 @verbatim 00037 coordinateRotation 00038 { 00039 type STARCDRotation; 00040 degrees false; 00041 rotation (0 0 3.141592654); 00042 } 00043 @endverbatim 00044 00045 \*---------------------------------------------------------------------------*/ 00046 00047 #ifndef STARCDCoordinateRotation_H 00048 #define STARCDCoordinateRotation_H 00049 00050 #include <meshTools/coordinateRotation.H> 00051 00052 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00053 00054 namespace Foam 00055 { 00056 00057 /*---------------------------------------------------------------------------*\ 00058 Class STARCDCoordinateRotation Declaration 00059 \*---------------------------------------------------------------------------*/ 00060 00061 class STARCDCoordinateRotation 00062 : 00063 public coordinateRotation 00064 { 00065 // Private member functions 00066 00067 //- Calculate transformation tensor 00068 void calcTransform 00069 ( 00070 const scalar rotZ, 00071 const scalar rotX, 00072 const scalar rotY, 00073 const bool inDegrees=true 00074 ); 00075 00076 00077 public: 00078 00079 //- Runtime type information 00080 TypeName("STARCDRotation"); 00081 00082 00083 // Constructors 00084 00085 //- Construct null 00086 STARCDCoordinateRotation(); 00087 00088 //- Construct from rotation vector 00089 STARCDCoordinateRotation 00090 ( 00091 const vector& rotZrotXrotY, 00092 const bool inDegrees=true 00093 ); 00094 00095 //- Construct from components of rotation vector 00096 STARCDCoordinateRotation 00097 ( 00098 const scalar rotZ, 00099 const scalar rotX, 00100 const scalar rotY, 00101 const bool inDegrees=true 00102 ); 00103 00104 //- Construct from dictionary 00105 STARCDCoordinateRotation(const dictionary&); 00106 00107 }; 00108 00109 00110 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00111 00112 } // End namespace Foam 00113 00114 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00115 00116 #endif 00117 00118 // ************************ vim: set sw=4 sts=4 et: ************************ //