JEMRIS  2.8.1
open-source MRI simulations
Coil.h
Go to the documentation of this file.
1 
5 /*
6  * JEMRIS Copyright (C)
7  * 2006-2015 Tony Stoecker
8  * 2007-2015 Kaveh Vahedipour
9  * 2009-2015 Daniel Pflugfelder
10  *
11  *
12  * This program is free software; you can redistribute it and/or modify
13  * it under the terms of the GNU General Public License as published by
14  * the Free Software Foundation; either version 2 of the License, or
15  * (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * You should have received a copy of the GNU General Public License
23  * along with this program; if not, write to the Free Software
24  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
25  */
26 
27 #ifndef COIL_H_
28 #define COIL_H_
29 
30 #include "Prototype.h"
31 #include "Signal.h"
32 #include "Declarations.h"
33 #include "NDData.h"
34 
39 class Coil : public Prototype {
40 
41  public:
42 
46  virtual ~Coil ();
47 
53  double GetSensitivity (const double time=0) ;
54 
60  double GetPhase (const double time=0) ;
61 
67  double InterpolateSensitivity (const double* position, bool magnitude=true);
68 
77  virtual double GetSensitivity (const double* position) = 0;
78 
90  virtual double GetPhase (const double* position) {return 0.0;};
91 
97  void InitSignal (long lADCs);
98 
104  void Receive (long lADC);
105 
109  void Transmit ();
110 
116  Signal* GetSignal () { return m_signal; }
117 
121  Coil* Clone() const = 0;
122 
126  void GridMap ();
127 
133  double* MagnitudeMap ();
134 
140  double* PhaseMap ();
141 
147  virtual bool Prepare (const PrepareMode mode);
148 
158  void Initialize (DOMNode* node );
159 
160  int GetPoints ();
161 
162  unsigned GetNDim ();
163 
164  double GetNorm (){return m_norm;};
165 
166  protected:
167 
171  Coil() {};
172 
173  double m_position[3];
175  unsigned m_mode;
176  double m_azimuth;
177  double m_polar;
178  double m_scale;
179  double m_norm;
180  double m_phase;
182  bool m_complex;
183  bool m_conjugate;
184  unsigned m_dim;
185  double m_extent;
186  int m_points;
188  NDData<double> m_sensmag;
189  NDData<double> m_senspha;
190 
191  double Unwrap(double diff,bool magnitude);
193 };
194 
195 #endif /*COIL_H_*/
Implementation of JEMRIS Declarations.
double m_polar
Definition: Coil.h:177
Implementation of JEMRIS Prototype.
bool m_conjugate
Definition: Coil.h:183
bool m_complex
Definition: Coil.h:182
Signal * GetSignal()
Get the received signal of this coil.
Definition: Coil.h:116
void Transmit()
Transmit signal.
double GetPhase(const double time=0)
Get the B1+ phase at point (x,y,z) of the current spin.
Definition: Coil.cpp:135
double m_phase
Definition: Coil.h:180
void GridMap()
Dump sensitivity map on the XML defined grid.
Definition: Coil.cpp:89
double m_scale
Definition: Coil.h:178
virtual ~Coil()
Destructor.
Definition: Coil.cpp:32
unsigned m_dim
Definition: Coil.h:184
Prototype super class.
Definition: Prototype.h:71
double m_extent
Definition: Coil.h:185
void Initialize(DOMNode *node)
Initialize this prototype.
Definition: Coil.cpp:39
mode
Definition: Declarations.h:112
Implementation of JEMRIS Signal.
bool m_interpolate
Definition: Coil.h:181
double m_azimuth
Definition: Coil.h:176
double m_norm
Definition: Coil.h:179
virtual double GetPhase(const double *position)
Get the B1+ phase at point (x,y,z)
Definition: Coil.h:90
double Unwrap(double diff, bool magnitude)
Definition: Coil.cpp:217
double * MagnitudeMap()
Map magnitudes.
Definition: Coil.cpp:121
int m_points
Definition: Coil.h:186
void InitSignal(long lADCs)
Initialize my signal repository.
Definition: Coil.cpp:54
double GetSensitivity(const double time=0)
Get the B1+ magnitude at point (x,y,z) of the current spin.
Definition: Coil.cpp:153
Coil()
Definition: Coil.h:171
double * PhaseMap()
Map phases.
Definition: Coil.cpp:117
virtual bool Prepare(const PrepareMode mode)
Prepare coil with given attributes.
Definition: Coil.cpp:227
Coil * Clone() const =0
Base class of coil objects.
Definition: Coil.h:39
Signal * m_signal
Definition: Coil.h:174
double InterpolateSensitivity(const double *position, bool magnitude=true)
Interpolate the sensitivity at point (x,y,z)
Definition: Coil.cpp:172
unsigned m_mode
Definition: Coil.h:175
double m_position[3]
Definition: Coil.h:171
void Receive(long lADC)
Receive signal from World.
Definition: Coil.cpp:64
The signal store and IO.
Definition: Signal.h:249

-- last change 17.06.2016 | Tony Stoecker | Imprint --