ITK  4.13.0
Insight Segmentation and Registration Toolkit
itkFourierSeriesPath.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef itkFourierSeriesPath_h
19 #define itkFourierSeriesPath_h
20 
21 #include "itkParametricPath.h"
22 #include "itkVectorContainer.h"
23 #include "itkIndex.h"
24 
25 namespace itk
26 {
57 template< unsigned int VDimension >
58 class ITK_TEMPLATE_EXPORT FourierSeriesPath:public
59  ParametricPath< VDimension >
60 {
61 public:
67 
70 
72  typedef typename Superclass::InputType InputType;
73 
75  typedef typename Superclass::OutputType OutputType;
76 
84 
86  virtual OutputType Evaluate(const InputType & input) const ITK_OVERRIDE;
87 
90  virtual VectorType EvaluateDerivative(const InputType & input) const ITK_OVERRIDE;
91 
93  void AddHarmonic(const VectorType & CosCoefficients,
94  const VectorType & SinCoefficients);
95 
97  void Clear()
98  {
99  m_CosCoefficients->Initialize();
100  m_SinCoefficients->Initialize();
101  this->Modified();
102  }
104 
106  itkNewMacro(Self);
107 
109  virtual void Initialize(void) ITK_OVERRIDE
110  {
111  this->Clear();
112  }
113 
114 protected:
116  ~FourierSeriesPath() ITK_OVERRIDE {}
117  void PrintSelf(std::ostream & os, Indent indent) const ITK_OVERRIDE;
118 
119 private:
120  ITK_DISALLOW_COPY_AND_ASSIGN(FourierSeriesPath);
121 
124 };
125 } // end namespace itk
126 
127 #ifndef ITK_MANUAL_INSTANTIATION
128 #include "itkFourierSeriesPath.hxx"
129 #endif
130 
131 #endif
CoefficientsPointer m_CosCoefficients
SmartPointer< Self > Pointer
VectorContainer< unsigned, VectorType > CoefficientsType
ContinuousIndex< double, VDimension > ContinuousIndexType
virtual void Initialize(void) override
ParametricPath< VDimension > Superclass
CoefficientsType::Pointer CoefficientsPointer
CoefficientsPointer m_SinCoefficients
Superclass::InputType InputType
Superclass::OutputType OutputType
Index< VDimension > IndexType
Represent a parametric path through ND Space.
Represent a closed path through ND Space by its frequency components.
Vector< double, VDimension > VectorType
A templated class holding a point in n-Dimensional image space.
Define a front-end to the STL &quot;vector&quot; container that conforms to the IndexedContainerInterface.
SmartPointer< const Self > ConstPointer
Control indentation during Print() invocation.
Definition: itkIndent.h:49
Offset< VDimension > OffsetType