• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files

transform3d.h

Go to the documentation of this file.
00001 /**********************************************************************
00002 transform3d.h - Handle 3D transformations in space groups.
00003  
00004 Copyright (C) 2007 by Jean Bréfort
00005 
00006 This file is part of the Open Babel project.
00007 For more information, see <http://openbabel.sourceforge.net/>
00008  
00009 This program is free software; you can redistribute it and/or 
00010 modify it under the terms of the GNU General Public License as 
00011 published by the Free Software Foundation; either version 2 of the
00012 License, or (at your option) any later version.
00013  
00014 This program is distributed in the hope that it will be useful,
00015 but WITHOUT ANY WARRANTY; without even the implied warranty of
00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00017 GNU General Public License for more details.
00018 ***********************************************************************/
00019 
00020 #ifndef OB_TRANSFORM_3D_H
00021 #define OB_TRANSFORM_3D_H
00022 
00023 #include <openbabel/math/matrix3x3.h>
00024 #include <list>
00025 #include <string>
00026 
00027 namespace OpenBabel
00028 {
00029   
00035   class OBAPI transform3d: private matrix3x3, private vector3
00036     {
00037     public:
00038       transform3d(void): matrix3x3(), vector3()
00039         {
00040         }
00041 
00042       transform3d(const matrix3x3 &m, const vector3 &v): matrix3x3(m), vector3(v)
00043         {
00044           Normalize();
00045         }
00046         
00047       transform3d(double s): matrix3x3(s), vector3()
00048         {
00049         }
00050 
00052       transform3d(vector3 row1,vector3 row2,vector3 row3,vector3 translation):
00053         matrix3x3(row1, row2, row3), vector3(translation)
00054         {
00055           Normalize();
00056         }
00057 
00059 
00060       transform3d(double d[3][3], double t[3]): matrix3x3(d), vector3(t)
00061        {
00062          Normalize();
00063        }
00064 
00065       vector3 operator *(const vector3 &);
00066 
00067       transform3d operator *(const transform3d &);
00068 
00069       std::string DescribeAsString() const;
00070       std::string DescribeAsValues() const;
00071 
00072       void Normalize();
00073         };
00074     
00075   typedef std::list<transform3d*>::const_iterator transform3dIterator;
00076 
00077 }
00078 
00079 #endif // OB_TRANSFORM_3D_H
00080 

This file is part of the documentation for Open Babel, version 2.2.0.

Documentation copyright © 1998-2007, the Open Babel Developers.
Open Babel is hosted by: SourceForge Logo
Generated on Thu Jul 3 14:30:34 2008 by doxygen 1.5.6.