Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkBallModel.h
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 #ifndef _MITK_BallModel_H
18 #define _MITK_BallModel_H
19 
21 
22 namespace mitk {
23 
29 template< class ScalarType = double >
30 class BallModel : public DiffusionSignalModel< ScalarType >
31 {
32 public:
33 
34  BallModel();
35  template< class OtherType >BallModel(BallModel<OtherType>* model)
36  {
37  this->m_CompartmentId = model->m_CompartmentId;
38  this->m_T2 = model->GetT2();
39  this->m_FiberDirection = model->GetFiberDirection();
40  this->m_GradientList = model->GetGradientList();
42  this->m_RandGen = model->GetRandomGenerator();
43 
44  this->m_BValue = model->GetBvalue();
45  this->m_Diffusivity = model->GetDiffusivity();
46  }
47  ~BallModel();
48 
52 
53 
55  PixelType SimulateMeasurement();
56  ScalarType SimulateMeasurement(unsigned int dir);
57 
58  void SetDiffusivity(double D) { m_Diffusivity = D; }
59  double GetDiffusivity() { return m_Diffusivity; }
60  void SetBvalue(double bValue) { m_BValue = bValue; }
61  double GetBvalue() { return m_BValue; }
62 
63  void SetFiberDirection(GradientType fiberDirection){ this->m_FiberDirection = fiberDirection; }
64  void SetGradientList(GradientListType gradientList) { this->m_GradientList = gradientList; }
65 
66 protected:
67 
68  double m_Diffusivity;
69  double m_BValue;
70 };
71 
72 }
73 
74 #include "mitkBallModel.cpp"
75 
76 #endif
77 
GradientType m_FiberDirection
Needed to generate anisotropc signal to determin direction of anisotropy.
unsigned int m_CompartmentId
GUI flag. Which compartment is this model assigned to?
double m_BValue
b-value used to generate the artificial signal
Definition: mitkBallModel.h:69
double ScalarType
void SetDiffusivity(double D)
Definition: mitkBallModel.h:58
DataCollection - Class to facilitate loading/accessing structured data.
ItkRandGenType::Pointer m_RandGen
Random number generator.
GradientListType m_GradientList
Diffusion gradient direction container.
ItkDoubleImgType::Pointer m_VolumeFractionImage
Tissue specific volume fraction for each voxel (only relevant for non fiber compartments) ...
void SetFiberDirection(GradientType fiberDirection)
Definition: mitkBallModel.h:63
Generates direction independent diffusion measurement employing a scalar diffusion constant d: e^(-bd...
Definition: mitkBallModel.h:30
double m_Diffusivity
Scalar diffusion constant.
Definition: mitkBallModel.h:68
std::vector< GradientType > GradientListType
Abstract class for diffusion signal models.
itk::Vector< double, 3 > GradientType
void SetGradientList(GradientListType gradientList)
Definition: mitkBallModel.h:64
double GetBvalue()
Definition: mitkBallModel.h:61
DiffusionSignalModel< ScalarType >::PixelType PixelType
Definition: mitkBallModel.h:49
DiffusionSignalModel< ScalarType >::GradientType GradientType
Definition: mitkBallModel.h:50
ItkDoubleImgType::Pointer GetVolumeFractionImage()
double GetDiffusivity()
Definition: mitkBallModel.h:59
void SetBvalue(double bValue)
b-value used to generate the artificial signal
Definition: mitkBallModel.h:60
BallModel(BallModel< OtherType > *model)
Definition: mitkBallModel.h:35
double m_T2
Tissue specific transversal relaxation time.
DiffusionSignalModel< ScalarType >::GradientListType GradientListType
Definition: mitkBallModel.h:51
PixelType SimulateMeasurement()
ItkRandGenType::Pointer GetRandomGenerator()