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

itkFourierSeriesPath.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkFourierSeriesPath.h,v $
00005   Language:  C++
00006   Date:      $Date: 2008-10-16 23:25:41 $
00007   Version:   $Revision: 1.7 $
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 __itkFourierSeriesPath_h
00018 #define __itkFourierSeriesPath_h
00019 
00020 #include "itkParametricPath.h"
00021 #include "itkVectorContainer.h"
00022 #include "itkContinuousIndex.h"
00023 #include "itkIndex.h"
00024 #include "itkOffset.h"
00025 #include "itkVector.h"
00026 
00027 namespace itk
00028 {
00029 
00030 
00060 template <unsigned int VDimension>
00061 class ITK_EXPORT FourierSeriesPath : public
00062 ParametricPath< VDimension >
00063 {
00064 public:
00066   typedef FourierSeriesPath           Self;
00067   typedef ParametricPath<VDimension>  Superclass;
00068   typedef SmartPointer<Self>          Pointer;
00069   typedef SmartPointer<const Self>    ConstPointer;
00070 
00072   itkTypeMacro(FourierSeriesPath, ParametricPath);
00073 
00075   typedef typename Superclass::InputType  InputType;
00076 
00078   typedef typename Superclass::OutputType OutputType;
00079 
00080 
00082   typedef ContinuousIndex<double,VDimension>    ContinuousIndexType;
00083   typedef Index<  VDimension >                  IndexType;
00084   typedef Offset< VDimension >                  OffsetType;
00085   typedef Vector<double,VDimension>             VectorType;
00086   typedef VectorContainer<unsigned, VectorType> CoefficientsType;
00087   typedef typename CoefficientsType::Pointer    CoefficientsPointer;
00088 
00089 
00091   virtual OutputType Evaluate( const InputType & input ) const;
00092 
00095   virtual VectorType EvaluateDerivative(const InputType & input) const;
00096 
00098   void AddHarmonic( const VectorType & CosCoefficients,
00099                     const VectorType & SinCoefficients );
00100 
00102   void Clear()
00103     {
00104     m_CosCoefficients->Initialize();
00105     m_SinCoefficients->Initialize();
00106     this->Modified();
00107     }
00109 
00111   itkNewMacro( Self );
00112 
00114   virtual void Initialize(void)
00115     {
00116     this->Clear();
00117     }
00118 
00119 protected:
00120   FourierSeriesPath();
00121   ~FourierSeriesPath(){}
00122   void PrintSelf(std::ostream& os, Indent indent) const;
00123 
00124 private:
00125   FourierSeriesPath(const Self&); //purposely not implemented
00126   void operator=(const Self&); //purposely not implemented
00127 
00128   CoefficientsPointer m_CosCoefficients;
00129   CoefficientsPointer m_SinCoefficients;
00130 };
00131 
00132 } // end namespace itk
00133 
00134 // Define instantiation macro for this template.
00135 #define ITK_TEMPLATE_FourierSeriesPath(_, EXPORT, x, y) namespace itk { \
00136   _(1(class EXPORT FourierSeriesPath< ITK_TEMPLATE_1 x >)) \
00137   namespace Templates { typedef FourierSeriesPath< ITK_TEMPLATE_1 x > \
00138                                      FourierSeriesPath##y; } \
00139   }
00140 
00141 #if ITK_TEMPLATE_EXPLICIT
00142 # include "Templates/itkFourierSeriesPath+-.h"
00143 #endif
00144 
00145 #if ITK_TEMPLATE_TXX
00146 # include "itkFourierSeriesPath.txx"
00147 #endif
00148 
00149 #endif
00150 

Generated at Sat Feb 28 12:28:25 2009 for ITK by doxygen 1.5.6 written by Dimitri van Heesch, © 1997-2000