Public Member Functions | List of all members

MAGSI-based Magnetization Simulator. More...

#include <seqsim.h>

Inheritance diagram for SeqSimMagsi:
Inheritance graph

Public Member Functions

 SeqSimMagsi (const STD_string &label="unnamedSeqSimMagsi")
 SeqSimMagsi (const SeqSimMagsi &ssm)
 ~SeqSimMagsi ()
SeqSimMagsioperator= (const SeqSimMagsi &ssm)
unsigned int get_total_size () const
SeqSimMagsireset_magnetization ()
SeqSimMagsiset_initial_vector (float Mx, float My, float Mz)
const farrayget_Mx () const
const farrayget_My () const
const farrayget_Mz () const
const farrayget_Mamp () const
const farrayget_Mpha () const
SeqSimMagsiupdate ()
SeqSimMagsiset_online_simulation (bool onlineflag)
SeqSimMagsiset_intravoxel_simulation (bool ivflag)
SeqSimMagsiset_numof_threads (unsigned int n)
SeqSimMagsiset_spat_rotmatrix (const RotMatrix &rotmatrix)
bool do_simulation ()
void prepare_simulation (const Sample &sample, CoilSensitivity *transmit_coil=0, CoilSensitivity *receive_coil=0, ProgressMeter *progmeter=0)
cvector simulate (const SeqSimInterval &simvals, double gamma)
void finalize_simulation ()
bool kernel (const SeqSimInterval &simvals, cvector &signal, int &, unsigned int begin, unsigned int end)
- Public Member Functions inherited from LDRblock
 LDRblock (const STD_string &title="Parameter List")
 LDRblock (const LDRblock &block)
 ~LDRblock ()
LDRblockoperator= (const LDRblock &block)
LDRblockmerge (LDRblock &block, bool onlyUserPars=true)
LDRblockunmerge (LDRblock &block)
STD_string printval (const STD_string &parameterName, bool append_unit=false) const
bool parseval (const STD_string &parameterName, const STD_string &value)
int parseblock (const STD_string &source, const LDRserBase &serializer=LDRserJDX())
unsigned int numof_pars () const
LDRbaseget_parameter (const STD_string &ldrlabel)
bool parameter_exists (const STD_string &ldrlabel) const
LDRblockset_prefix (const STD_string &prefix)
LDRblockset_embedded (bool embedded)
bool is_embedded () const
LDRbaseoperator[] (unsigned int i)
const LDRbaseoperator[] (unsigned int i) const
LDRbaseget_parameter_by_id (int id)
LDRblockcreate_copy (const LDRblock &src)
LDRblockappend_copy (const LDRbase &src)
LDRblockcopy_ldr_vals (const LDRblock &src)
bool operator== (const LDRblock &rhs) const
bool operator< (const LDRblock &rhs) const
bool compare (const LDRblock &rhs, const STD_list< STD_string > *exclude=0, double accuracy=0.0) const
STD_string print (const LDRserBase &serializer=LDRserJDX()) const
LDRbaseset_parmode (parameterMode parameter_mode)
LDRbaseset_filemode (fileMode file_mode)
STD_string get_parx_code (parxCodeType type) const
STD_ostream & print2stream (STD_ostream &os, const LDRserBase &serializer) const
bool parsevalstring (const STD_string &, const LDRserBase *ser=0)
bool parse (STD_string &parstring, const LDRserBase &serializer)
STD_string printvalstring (const LDRserBase *ser=0) const
LDRbasecreate_copy () const
STD_string get_typeInfo (bool parx_equivtype=false) const
int load (const STD_string &filename, const LDRserBase &serializer=LDRserJDX())
int write (const STD_string &filename, const LDRserBase &serializer=LDRserJDX()) const
- Public Member Functions inherited from LDRbase
virtual double get_minval () const
virtual double get_maxval () const
bool has_minmax () const
const STD_string & get_description () const
LDRbaseset_description (const STD_string &descr)
virtual svector get_alternatives () const
const STD_string & get_unit () const
LDRbaseset_unit (const STD_string &un)
virtual parameterMode get_parmode () const
virtual fileMode get_filemode () const
virtual GuiProps get_gui_props () const
virtual LDRbaseset_gui_props (const GuiProps &)
JcampDxProps get_jdx_props () const
LDRbaseset_jdx_props (const JcampDxProps &jp)
- Public Member Functions inherited from Labeled
 Labeled (const STD_string &label="unnamed")
Labeledset_label (const STD_string &label)
const STD_string & get_label () const
Labeledoperator= (const Labeled &l)
- Public Member Functions inherited from List< I, P, R >
 List ()
 ~List ()
Listoperator= (const List &l)
Listclear ()
Listappend (R item)
Listremove (R item)
unsigned int size () const
iter get_begin ()
iter get_end ()
constiter get_const_begin () const
constiter get_const_end () const
- Public Member Functions inherited from ThreadedLoop< SeqSimInterval, cvector, int >
 ThreadedLoop ()
bool init (unsigned int numof_threads, unsigned int loopsize)
void destroy ()
bool execute (const SeqSimInterval &in, STD_vector< cvector > &outvec)
- Public Member Functions inherited from SeqClass
SeqClassset_temporary ()

Additional Inherited Members

- Public Types inherited from List< I, P, R >
typedef STD_list< P >::iterator iter
typedef STD_list< P >::const_iterator constiter
- Protected Member Functions inherited from LDRblock
LDRblockappend_member (LDRbase &ldr, const STD_string ldrlabel="")
- Protected Member Functions inherited from SeqClass
void marshall_error () const
virtual void clear_container ()
virtual bool prep ()
- Static Protected Member Functions inherited from SeqClass
static void clear_temporary ()
static void clear_containers ()

Detailed Description

MAGSI-based Magnetization Simulator.

This is a simulator to calculate the time evolution of a magnetization grid in 4 dimension (frequency and three spatial dimensions). This simulation of the Bloch-Torrey equations is performed by means of the MAGSI algorith (c.f. Journal of Magnetic Resonance 180:29-38, 2006). Simulation usually involves the following steps:

Definition at line 113 of file seqsim.h.

Constructor & Destructor Documentation

§ SeqSimMagsi() [1/2]

SeqSimMagsi::SeqSimMagsi ( const STD_string &  label = "unnamedSeqSimMagsi")

Constructs a simulator labeled 'object_label'.

§ SeqSimMagsi() [2/2]

SeqSimMagsi::SeqSimMagsi ( const SeqSimMagsi ssm)

Copy constructor

§ ~SeqSimMagsi()

SeqSimMagsi::~SeqSimMagsi ( )


Member Function Documentation

§ do_simulation()

bool SeqSimMagsi::do_simulation ( )

Returns whether simulation should be performed, i.e. whether the 'online' flag is true or 'update' was activated.

§ finalize_simulation()

void SeqSimMagsi::finalize_simulation ( )

Call this function after a simulation (i.e. after successive calls to simulate() )

Implements SeqSimAbstract.

§ get_Mamp()

const farray& SeqSimMagsi::get_Mamp ( ) const

Returns the amplitude of the transverse magnetisation

Definition at line 170 of file seqsim.h.

§ get_Mpha()

const farray& SeqSimMagsi::get_Mpha ( ) const

Returns the phase of the transverse magnetisation

Definition at line 175 of file seqsim.h.

§ get_Mx()

const farray& SeqSimMagsi::get_Mx ( ) const

Returns the real part of the transverse magnetisation

Definition at line 155 of file seqsim.h.

§ get_My()

const farray& SeqSimMagsi::get_My ( ) const

Returns the imaginary part of the transverse magnetisation

Definition at line 160 of file seqsim.h.

§ get_Mz()

const farray& SeqSimMagsi::get_Mz ( ) const

Returns the longitudinal magnetisation

Definition at line 165 of file seqsim.h.

§ get_total_size()

unsigned int SeqSimMagsi::get_total_size ( ) const

Returns the overall size of the array

Definition at line 140 of file seqsim.h.

§ kernel()

bool SeqSimMagsi::kernel ( const SeqSimInterval in,
cvector out,
int &  local,
unsigned int  begin,
unsigned int  end 

Overload this function to do the work of one thread using input 'in', generating output 'out' with thread-local storage 'local' for the the loop inidices (begin <= i < end).

Implements ThreadedLoop< SeqSimInterval, cvector, int >.

§ operator=()

SeqSimMagsi& SeqSimMagsi::operator= ( const SeqSimMagsi ssm)

Assignment operator

§ prepare_simulation()

void SeqSimMagsi::prepare_simulation ( const Sample sample,
CoilSensitivity transmit_coil = 0,
CoilSensitivity receive_coil = 0,
ProgressMeter progmeter = 0 

Prepare a simulation (i.e. before successive calls to simulate() ) with the parameters:

  • sample: The virtual sample
  • transmit_coil: Transmitter coil, 0 for none
  • receive_coil: Receiver coil, 0 for none
  • progmeter: Status indicator to trace progress, 0 for none

Implements SeqSimAbstract.

§ reset_magnetization()

SeqSimMagsi& SeqSimMagsi::reset_magnetization ( )

Set each magnetization to initial state 'initial_vector', which is (0,0,1) by default

§ set_initial_vector()

SeqSimMagsi& SeqSimMagsi::set_initial_vector ( float  Mx,
float  My,
float  Mz 

Set the vector for the initial magnetization

§ set_intravoxel_simulation()

SeqSimMagsi& SeqSimMagsi::set_intravoxel_simulation ( bool  ivflag)

Specifies whether intra-voxel magnetzation gradients are considered during simulation

Definition at line 192 of file seqsim.h.

§ set_numof_threads()

SeqSimMagsi& SeqSimMagsi::set_numof_threads ( unsigned int  n)

Specifies the number of threads used during simulation

Definition at line 197 of file seqsim.h.

§ set_online_simulation()

SeqSimMagsi& SeqSimMagsi::set_online_simulation ( bool  onlineflag)

Specifies whether simulation should be performed everytime update() is called

Definition at line 186 of file seqsim.h.

§ set_spat_rotmatrix()

SeqSimMagsi& SeqSimMagsi::set_spat_rotmatrix ( const RotMatrix rotmatrix)

Specifies a rotation matrix for the spatial domain, i.e. the magnetization array will be rotated in space using the specified rotation matrix.

§ simulate()

cvector SeqSimMagsi::simulate ( const SeqSimInterval simvals,
double  gamma 

Simulation with

  • simvals: The magnetic fields during a time interval
  • gamma: Gyromagnetic ration of the nucleus observed Return value: Signal in each receiver channel

Implements SeqSimAbstract.

§ update()

SeqSimMagsi& SeqSimMagsi::update ( )

Updates all parameter relations

The documentation for this class was generated from the following file: