Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkSymmetricEigenSystem.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkSymmetricEigenSystem.h,v $
00005   Language:  C++
00006   Date:      $Date: 2009-11-22 13:34:53 $
00007   Version:   $Revision: 1.9 $
00008 
00009   Copyright (c) Insight Software Consortium. All rights reserved.
00010   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
00011 
00012      This software is distributed WITHOUT ANY WARRANTY; without even 
00013      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00014      PURPOSE.  See the above copyright notices for more information.
00015 
00016 =========================================================================*/
00017 #ifndef __itkSymmetricEigenSystem_h
00018 #define __itkSymmetricEigenSystem_h
00019 
00020 #include "itkObject.h"
00021 #include "vnl/algo/vnl_symmetric_eigensystem.h"
00022 #include "itkObjectFactory.h"
00023 #include "itkObject.h"
00024 #include "itkFixedArray.h"
00025 #include "itkMatrix.h"
00026 #include "itkObjectFactory.h"
00027 
00028 namespace itk
00029 {
00030   
00045 template< class TMatrixElement, int VNumberOfRows >
00046 class ITK_EXPORT SymmetricEigenSystem : public Object
00047 {
00048 public:
00050   typedef SymmetricEigenSystem     Self;
00051   typedef Object                   Superclass;
00052   typedef SmartPointer<Self>       Pointer;
00053   typedef SmartPointer<const Self> ConstPointer;
00054 
00056   itkTypeMacro( SymmetricEigenSystem, Object );
00057 
00059   itkNewMacro(Self);
00060 
00062   typedef FixedArray< TMatrixElement, VNumberOfRows > ArrayType;
00063 
00065   typedef FixedArray< ArrayType, VNumberOfRows > Array2DType;
00066 
00068   typedef Array2DType EigenVectorArrayType;
00069 
00071   typedef ArrayType EigenValueArrayType;
00072 
00074   typedef Matrix< TMatrixElement, VNumberOfRows, VNumberOfRows > MatrixType;
00075 
00077   typedef vnl_symmetric_eigensystem< TMatrixElement > InternalEigenSystemType;
00078 
00080   itkSetObjectMacro(Matrix, MatrixType);
00081   MatrixType* GetMatrix()
00082     { return m_Matrix; }
00084 
00091   itkSetMacro(UseAbsoluteOrder, bool);
00092   itkGetMacro(UseAbsoluteOrder, bool);
00094 
00096   EigenVectorArrayType* GetEigenVectors()
00097     { return &m_EigenVectors; } 
00098 
00100   EigenValueArrayType* GetEigenValues()
00101     { return &m_EigenValues; }
00102 
00105   void Update()
00106     { this->GenerateData(); }
00107 
00108 protected:
00109   SymmetricEigenSystem();
00110   virtual ~SymmetricEigenSystem();
00111   void PrintSelf(std::ostream& os, Indent indent) const;
00112 
00114   void GenerateData();
00115 
00116 private:
00117   SymmetricEigenSystem(const Self&); //purposely not implemented
00118   void operator=(const Self&); //purposely not implemented
00119 
00121   MatrixType* m_Matrix;
00122 
00124   EigenVectorArrayType m_EigenVectors;
00125 
00127   EigenValueArrayType m_EigenValues;
00128 
00131   bool m_UseAbsoluteOrder;
00132 };
00133 
00134 } // end namespace itk
00135 
00136 #ifndef ITK_MANUAL_INSTANTIATION
00137 #include "itkSymmetricEigenSystem.txx"
00138 #endif
00139 
00140 #endif
00141 

Generated at Mon Jul 12 2010 20:00:19 for ITK by doxygen 1.7.1 written by Dimitri van Heesch, © 1997-2000