CEPS  24.01
Cardiac ElectroPhysiology Simulator
ActivationTracker Class Reference

Detailed Description

Class managing computations from potential to outputs.

Not only this class outputs the solution vector (one scalar field per component), it also handles the computation of activation times.

Activation times are defined by $ t_\mathrm{activ}(v_\mathrm{th},\bm{x}) = \min \max_{t>t_\mathrm{start}} \{t | V(t,\bm{x}) > v_\mathrm{th}\}$ Depolarization times are defined by $ t_\mathrm{depol}(v_\mathrm{th},\bm{x}) = \min \max_{t>t_\mathrm{start}} \{t | V(t,\bm{x}) < v_\mathrm{th}\}$ where $v$ is a depolarization threshold than can be set multiple times.

AP peaks are detected as the first time the AP decreases after activation time.

Definition at line 59 of file ActivationTracker.hpp.

#include <ActivationTracker.hpp>

Inheritance diagram for ActivationTracker:
[legend]

Public Member Functions

 ActivationTracker (CardiacSolver *solver)
 Constructor. More...
 
 ~ActivationTracker ()
 Destructor. More...
 
void update (CepsInt iter, CepsReal time, DHVecPtr solution, DHVecPtr prevSolution)
 Writes the solution (optionnally currents) every m_nbIterSnapshot steps only. Also updates activation times. More...
 
void writeActivationMap ()
 Writes activation times and probe points data. More...
 
CepsBool allPointsHaveBeenActivated () const
 Tells if all points have seen AP start (checked with activation threshold) More...
 
CepsBool allPointsHaveBeenRepolarized () const
 Tells if all points have seen AP end (checked with APD percentage) More...
 
CepsString getByeByeMessage () const
 Message to be displayed at the end of computation. More...
 
CepsVector< CepsReal > & getActivatedVolume ()
 Returns reference to data, so it can be linked to a TimeWriter. More...
 
- Public Member Functions inherited from CepsObject
 CepsObject ()=default
 default constructor More...
 
 CepsObject (const CepsObject &)=default
 Copy constructor. More...
 
virtual ~CepsObject ()=default
 Destructor. More...
 
CepsObjectoperator= (const CepsObject &)=default
 Assignment operator. More...
 
CepsObjecttoBaseObject ()
 Returns a pointer to CepsObject class. More...
 
const CepsObjecttoBaseObject () const
 Returns a pointer to CepsObject class, const version. More...
 
ProfilergetProfiler () const
 Access to profiler. More...
 

Protected Member Functions

void setupWithParameters (InputParameters *params)
 Initializes attributes from text input. More...
 
void initializeActivationMap ()
 Allocates arrays for activation detection. More...
 
CepsBool allSeen (const CepsMap< CepsUnknownIndex, CepsSet< CepsDofGlobalIndex >> &) const
 Check not nans for given array. More...
 

Protected Attributes

CardiacProblemm_problem
 Link to problem structure. More...
 
Geometrym_geom
 Geometry. More...
 
TimeWriterm_timeWriter
 Link to the solver's time writer, if needed... More...
 
CepsUInt m_nbIterPostProcess
 Output periodicity. More...
 
CepsMap< CepsUnknownIndex, CepsReal3Dm_activationTimeData
 AP analysis. More...
 
DHVecPtr m_activationTimes
 Values of activation times at each point. More...
 
DHVecPtr m_activated
 1/0 status of point (above/below threshold) More...
 
DHVecPtr m_peakValues
 Value of max potential. More...
 
DHVecPtr m_peakTimes
 Times of max potential. More...
 
DHVecPtr m_APD50
 length of AP to get to 50% depol More...
 
DHVecPtr m_APD
 length of AP (?) More...
 
CepsMap< CepsUnknownIndex, CepsSet< CepsDofGlobalIndex > > m_activationNotYetSeen
 Flag map. More...
 
CepsMap< CepsUnknownIndex, CepsSet< CepsDofGlobalIndex > > m_activationSeen
 Flag map. More...
 
CepsMap< CepsUnknownIndex, CepsSet< CepsDofGlobalIndex > > m_foundPeak
 Flag map. More...
 
CepsMap< CepsUnknownIndex, CepsSet< CepsDofGlobalIndex > > m_foundAPD50
 Flag map. More...
 
CepsMap< CepsUnknownIndex, CepsSet< CepsDofGlobalIndex > > m_foundAPD
 Flag map. More...
 
CepsVector< CepsRealm_activatedVolume
 Size of tissue that is above activation threshold. More...
 
CepsReal m_tissueVolume
 Reference volume. More...
 
CepsUInt m_nToBeSeen
 Number of dofs in tissue for each activation time data. More...
 

Static Protected Attributes

static constexpr CepsUInt _threshold = 0
 Index in activation data. More...
 
static constexpr CepsUInt _apdpctg = 1
 Index in activation data. More...
 
static constexpr CepsUInt _minV4Peak = 2
 Index in activation data. More...
 
- Static Protected Attributes inherited from CepsObject
static Profiler m_profiler
 The same profiler for each big object. More...
 

Constructor & Destructor Documentation

◆ ActivationTracker()

ActivationTracker::ActivationTracker ( CardiacSolver solver)

Constructor.

Parameters
[in]solverlink to CardiacSolver structure

Definition at line 36 of file ActivationTracker.cpp.

◆ ~ActivationTracker()

ActivationTracker::~ActivationTracker ( )

Destructor.

Definition at line 67 of file ActivationTracker.cpp.

Member Function Documentation

◆ allPointsHaveBeenActivated()

CepsBool ActivationTracker::allPointsHaveBeenActivated ( ) const

Tells if all points have seen AP start (checked with activation threshold)

Definition at line 231 of file ActivationTracker.cpp.

◆ allPointsHaveBeenRepolarized()

CepsBool ActivationTracker::allPointsHaveBeenRepolarized ( ) const

Tells if all points have seen AP end (checked with APD percentage)

Definition at line 239 of file ActivationTracker.cpp.

◆ allSeen()

CepsBool ActivationTracker::allSeen ( const CepsMap< CepsUnknownIndex, CepsSet< CepsDofGlobalIndex >> &  arrays) const
protected

Check not nans for given array.

Definition at line 357 of file ActivationTracker.cpp.

◆ getActivatedVolume()

CepsVector< CepsReal > & ActivationTracker::getActivatedVolume ( )

Returns reference to data, so it can be linked to a TimeWriter.

Definition at line 253 of file ActivationTracker.cpp.

◆ getByeByeMessage()

CepsString ActivationTracker::getByeByeMessage ( ) const

Message to be displayed at the end of computation.

Definition at line 247 of file ActivationTracker.cpp.

◆ initializeActivationMap()

void ActivationTracker::initializeActivationMap ( )
protected

Allocates arrays for activation detection.

Definition at line 286 of file ActivationTracker.cpp.

◆ setupWithParameters()

void ActivationTracker::setupWithParameters ( InputParameters params)
protected

Initializes attributes from text input.

Definition at line 259 of file ActivationTracker.cpp.

◆ update()

void ActivationTracker::update ( CepsInt  iter,
CepsReal  time,
DHVecPtr  solution,
DHVecPtr  prevSolution 
)

Writes the solution (optionnally currents) every m_nbIterSnapshot steps only. Also updates activation times.

Definition at line 75 of file ActivationTracker.cpp.

◆ writeActivationMap()

void ActivationTracker::writeActivationMap ( )

Writes activation times and probe points data.

Definition at line 193 of file ActivationTracker.cpp.

Field Documentation

◆ _apdpctg

constexpr CepsUInt ActivationTracker::_apdpctg = 1
staticconstexprprotected

Index in activation data.

Definition at line 121 of file ActivationTracker.hpp.

◆ _minV4Peak

constexpr CepsUInt ActivationTracker::_minV4Peak = 2
staticconstexprprotected

Index in activation data.

Definition at line 122 of file ActivationTracker.hpp.

◆ _threshold

constexpr CepsUInt ActivationTracker::_threshold = 0
staticconstexprprotected

Index in activation data.

Definition at line 120 of file ActivationTracker.hpp.

◆ m_activated

DHVecPtr ActivationTracker::m_activated
protected

1/0 status of point (above/below threshold)

Definition at line 125 of file ActivationTracker.hpp.

◆ m_activatedVolume

CepsVector<CepsReal> ActivationTracker::m_activatedVolume
protected

Size of tissue that is above activation threshold.

Definition at line 137 of file ActivationTracker.hpp.

◆ m_activationNotYetSeen

CepsMap<CepsUnknownIndex,CepsSet<CepsDofGlobalIndex> > ActivationTracker::m_activationNotYetSeen
protected

Flag map.

Definition at line 131 of file ActivationTracker.hpp.

◆ m_activationSeen

CepsMap<CepsUnknownIndex,CepsSet<CepsDofGlobalIndex> > ActivationTracker::m_activationSeen
protected

Flag map.

Definition at line 132 of file ActivationTracker.hpp.

◆ m_activationTimeData

CepsMap<CepsUnknownIndex,CepsReal3D> ActivationTracker::m_activationTimeData
protected

AP analysis.

Definition at line 119 of file ActivationTracker.hpp.

◆ m_activationTimes

DHVecPtr ActivationTracker::m_activationTimes
protected

Values of activation times at each point.

Definition at line 124 of file ActivationTracker.hpp.

◆ m_APD

DHVecPtr ActivationTracker::m_APD
protected

length of AP (?)

Definition at line 129 of file ActivationTracker.hpp.

◆ m_APD50

DHVecPtr ActivationTracker::m_APD50
protected

length of AP to get to 50% depol

Definition at line 128 of file ActivationTracker.hpp.

◆ m_foundAPD

CepsMap<CepsUnknownIndex,CepsSet<CepsDofGlobalIndex> > ActivationTracker::m_foundAPD
protected

Flag map.

Definition at line 135 of file ActivationTracker.hpp.

◆ m_foundAPD50

CepsMap<CepsUnknownIndex,CepsSet<CepsDofGlobalIndex> > ActivationTracker::m_foundAPD50
protected

Flag map.

Definition at line 134 of file ActivationTracker.hpp.

◆ m_foundPeak

CepsMap<CepsUnknownIndex,CepsSet<CepsDofGlobalIndex> > ActivationTracker::m_foundPeak
protected

Flag map.

Definition at line 133 of file ActivationTracker.hpp.

◆ m_geom

Geometry* ActivationTracker::m_geom
protected

Geometry.

Definition at line 114 of file ActivationTracker.hpp.

◆ m_nbIterPostProcess

CepsUInt ActivationTracker::m_nbIterPostProcess
protected

Output periodicity.

Definition at line 117 of file ActivationTracker.hpp.

◆ m_nToBeSeen

CepsUInt ActivationTracker::m_nToBeSeen
protected

Number of dofs in tissue for each activation time data.

Definition at line 140 of file ActivationTracker.hpp.

◆ m_peakTimes

DHVecPtr ActivationTracker::m_peakTimes
protected

Times of max potential.

Definition at line 127 of file ActivationTracker.hpp.

◆ m_peakValues

DHVecPtr ActivationTracker::m_peakValues
protected

Value of max potential.

Definition at line 126 of file ActivationTracker.hpp.

◆ m_problem

CardiacProblem* ActivationTracker::m_problem
protected

Link to problem structure.

Definition at line 113 of file ActivationTracker.hpp.

◆ m_timeWriter

TimeWriter* ActivationTracker::m_timeWriter
protected

Link to the solver's time writer, if needed...

Definition at line 115 of file ActivationTracker.hpp.

◆ m_tissueVolume

CepsReal ActivationTracker::m_tissueVolume
protected

Reference volume.

Definition at line 138 of file ActivationTracker.hpp.


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