1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | foam-extend: Open Source CFD
4 \\ / O peration | Version: 3.2
5 \\ / A nd | Web: http://www.foam-extend.org
6 \\/ M anipulation | For copyright notice see file Copyright
7 -------------------------------------------------------------------------------
9 This file is part of foam-extend.
11 foam-extend is free software: you can redistribute it and/or modify it
12 under the terms of the GNU General Public License as published by the
13 Free Software Foundation, either version 3 of the License, or (at your
14 option) any later version.
16 foam-extend is distributed in the hope that it will be useful, but
17 WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
25 Foam::ellipticCylindricalCS
28 Elliptic cylindrical coordinate system.
30 Notation: u = a.x() v = a.y() z = a.z();
32 http://en.wikipedia.org/wiki/Elliptic_coordinates
35 ellipticCylindricalCS.C
38 Henrik Rusche, Wikki GmbH
41 \*---------------------------------------------------------------------------*/
43 #ifndef ellipticCylindricalCS_H
44 #define ellipticCylindricalCS_H
46 #include "coordinateSystem.H"
49 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
54 /*---------------------------------------------------------------------------*\
55 Class ellipticCylindricalCS Declaration
56 \*---------------------------------------------------------------------------*/
58 class ellipticCylindricalCS
60 public coordinateSystem
62 // Private data members
64 // Distance of the foci from the origin
67 //- Are angles in degrees? (default = true)
73 // Protected Member Functions
75 //- Convert from local coordinate system to the global Cartesian system
76 // with optional translation for the origin
77 virtual vector localToGlobal(const vector&, bool translate) const;
79 //- Convert from local coordinate system to the global Cartesian system
80 // with optional translation for the origin
81 virtual tmp<vectorField> localToGlobal
87 //- Convert from global Cartesian system to the local coordinate system
88 // with optional translation for the origin
89 virtual vector globalToLocal(const vector&, bool translate) const;
91 //- Convert from global Cartesian system to the local coordinate system
92 // with optional translation for the origin
93 virtual tmp<vectorField> globalToLocal
101 //- Runtime type information
102 TypeName("ellipticCylindrical");
108 ellipticCylindricalCS(const bool inDegrees = true);
111 ellipticCylindricalCS
113 const coordinateSystem&,
114 const bool inDegrees = true
117 //- Construct copy with a different name
118 ellipticCylindricalCS
121 const coordinateSystem&,
122 const bool inDegrees = true
125 //- Construct from origin, and rotation
126 ellipticCylindricalCS
130 const coordinateRotation& cr,
132 const bool inDegrees = true
135 //- Construct from origin and 2 axes
136 ellipticCylindricalCS
143 const bool inDegrees = true
146 //- Construct from dictionary
147 ellipticCylindricalCS
150 const dictionary& dict
154 virtual autoPtr<coordinateSystem> clone() const
156 return autoPtr<coordinateSystem>(new ellipticCylindricalCS(*this));
162 // Global information about the coordinate system
164 //- Directions in which the span is limited
165 virtual spanInfo spanLimited() const;
168 virtual boundBox spanBounds() const;
171 //- Are angles in degrees?
172 bool inDegrees() const;
174 //- Non-const access to inDegrees
181 virtual void write(Ostream&) const;
184 virtual void writeDict(Ostream&, bool subDict = true) const;
188 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
190 } // End namespace Foam
192 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
196 // ************************************************************************* //