link to homepage

Institute for Neuroscience and Medicine

Navigation and service


API documentation

Base class for MR model solver. More...

#include <Model.h>

Inheritance diagram for Model:
Collaboration diagram for Model:

List of all members.

Public Member Functions

 Model ()
 Constructor.
virtual ~Model ()
 Default Destructor.
void Prepare (CoilArray *pRxCoilArray, CoilArray *pTxCoilArray, ConcatSequence *pConcatSequence, Sample *pSample)
 Prepare for simulations.
void SetSequence (ConcatSequence *pConcatSequence)
 Set MR sequence.
void Solve ()
 Solve differential equations.

Static Public Member Functions

static void saveEvolution (long index, bool close_files)
 Save time evolution to disk.

Protected Member Functions

virtual void InitSolver ()=0
 Initialise solver.
virtual void FreeSolver ()=0
 Free solver.
virtual bool Calculate (double next_tStop)=0
 Calculate specific solution.
void RunSequenceTree (double &dTimeShift, long &lIndexShift, Module *module)

Protected Attributes

Worldm_world
 Simulation world.
CoilArraym_rx_coil_array
 Receive coil array.
CoilArraym_tx_coil_array
 Transmit coil array.
ConcatSequencem_concat_sequence
 Top node of the sequence tree for simulation.
Samplem_sample
 Sample.
double m_accuracy_factor
 increase accuracy by thid factor in case of numerical problems
bool m_do_dump_progress
 If true, percentage progress during Solve() is written to .jemris_progress.out.

Detailed Description

Base class for MR model solver.

Definition at line 43 of file Model.h.


Member Function Documentation

virtual bool Model::Calculate ( double  next_tStop  )  [protected, pure virtual]

Calculate specific solution.

Calculate specific solution in an atomic sequence All setting for the computation are in m_World

Implemented in Bloch_CV_Model.

Referenced by RunSequenceTree().

Here is the caller graph for this function:

void Model::Prepare ( CoilArray pRxCoilArray,
CoilArray pTxCoilArray,
ConcatSequence pConcatSequence,
Sample pSample 
)

Prepare for simulations.

Parameters:
pRxCoilArray Coil array receiving and storing the signal processed.
pTxCoilArray Coil array transmitting the sequence to be processed.
pConcatSequence Complete MR sequence.
pSample Sample.

Definition at line 46 of file Model.cpp.

References m_concat_sequence, m_rx_coil_array, m_sample, and m_tx_coil_array.

Referenced by Simulator::SetModel().

Here is the caller graph for this function:

void Model::RunSequenceTree ( double &  dTimeShift,
long &  lIndexShift,
Module module 
) [protected]

Run through the sequence tree and execute Calculate for each atom

Parameters:
dTimeShift The time shift with which this run starts within the sequence time frame
lIndexShift More elaborate description here please
module The Atomic sequence simulated in this run

Definition at line 101 of file Model.cpp.

References ConcatSequence::begin(), Calculate(), AtomicSequence::CollectTPOIs(), ConcatSequence::end(), FreeSolver(), Pulse::GetAxis(), Module::GetChildren(), AtomicSequence::GetDuration(), Sequence::GetNumOfADCs(), Module::GetNumOfTPOIs(), TPOI::GetPhase(), Pulse::GetPhaseLock(), TPOI::GetTime(), Module::GetTPOIs(), InitSolver(), m_accuracy_factor, m_rx_coil_array, m_tx_coil_array, m_world, World::NonLinGradField, World::pAtom, World::phase, CoilArray::Receive(), World::saveEvolFunPtr, World::saveEvolStepSize, Pulse::SetTPOIs(), World::solution, World::SpinNumber, World::time, World::total_time, World::TotalADCNumber, and World::TotalSpinNumber.

Referenced by Solve().

Here is the call graph for this function:

Here is the caller graph for this function:

void Model::saveEvolution ( long  index,
bool  close_files 
) [static]

Save time evolution to disk.

Static function to write the time-evolution of the magnetisation for every spin to binary file.

Definition at line 243 of file Model.cpp.

References World::instance(), PHASE, World::saveEvolFileName, World::saveEvolOfstream, World::saveEvolStepSize, World::solution, World::SpinNumber, World::time, World::TotalADCNumber, World::TotalSpinNumber, World::Values, XC, YC, and ZC.

Here is the call graph for this function:


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

Servicemeu