Example b222: Excitation wavefront propagation from Purkinje stimulation in canine ventricular myocardium.

An eikonal equation is used to model propagation of excitation in a model of the canine ventricular myocardium with 90 tri-cubic Hermite elements. The solution describes the excitation time of the tissue given the initial excitation times from the stimuli received from the Purkinje network.


The comfile run by this example is as follows:

fem define parameter;r;r23;example;

fem define coordinate;r;rc3d;example;   # 3D rectangular Cartesian coordinates
fem define node;r;heart-mr3;example;    # 130 nodes
fem define base;r;hermite3;example;     # tri-cubic hermite bases and others
fem define element;r;heart-mr3;example; # 90 tricubic-Hermite elements
fem define fibre;r;heart-mr3;example;   #fibres
fem define element;r;heart-mr3;example fibre;
fem refine xi 2 cross;                  # refine in xi 2 direction
# Remove unnecessary versions from internal nodes where fields should be
# continuous.
FEM update node continuous_internal;

# Remove the confusion of scale factors.
# (Also allows the same bases to be used for field 1.)
fem update scale unit;

# Define 2 fields used in the solution:
#   Field 1 is tri-cubic Hermite (unit scalefactors) and will be set to
#     zero where dep. var. is not C1 continuous.
#   Field 2 determines versions for dep. var.
FEM define field;r;r23;example;
FEM define element;r;r23;example field;

# Orthotropic eikonal, Petrov-Galerkin FEM
fem define equation;r;eik-ort-pet;example;

# Set up groups for the various regions of the tissue that have different
# material properties.
fem group element 1,2,9..12,19,20,91,92,101,102,109,110 as purk-rf;
fem group element 62,71,72,79,80,161,162,169,170 as purk-rs;
fem group element 33..38,41..60,131..138,141..150 as purk-lv;
fem group element 99..100 as rest-rf;
fem group element 61,69..70,151,152,159..160 as rest-rs;
fem group element 31..32,39..40,121..132,139..140 as rest-lv;
fem group node xi3=0 element purk-rf as purk-rf;
fem group node xi3=1 element purk-rs as purk-rs;
fem group node xi3=0 element purk-lv as purk-lv;
fem group node purk-lv as purkinje;
fem group node xi3=0 element rest-rf as rest-rf;
fem group node xi3=1 element rest-rs as rest-rs;
fem group node xi3=0 element rest-lv as rest-lv;
fem group node purk-rf,purk-rs,rest-rf,rest-rs,rest-lv as endo;
fem group node 1..256 as all;
fem def material;r;myocardium-penet;example;
fem def initial;r;myocardium-purkinje-r23;example;

#fem update field from solution to 2
fem update field eikonal;               #calculate continuity field 1

# Precalculate guass point invariants
fem update gauss eikonal timing;

fem def solve;r;gmres;example;

if( 0 )
  { # skip gradual reduction in diffusion to save some time
    fem solve iterate 1 increment 0.02;
    fem solve iterate 1 increment 0.05;
    fem solve iterate 1 increment 0.07;
    fem solve iterate 1 increment 0.1;
    fem solve iterate 1 increment 0.15;
    fem solve iterate 1 increment 0.2;
    fem solve iterate 1 increment 0.25;
    fem solve iterate 1 increment 0.3;
    fem solve iterate 1 increment 0.35;
    fem solve iterate 1 increment 0.4;
    fem solve iterate 1 increment 0.45;
  }

# Twice the physiological level of diffusion is required to keep the solution
# stable.

# Read in precalculated solution
fem def initial;r;myocardium-purkinje-r23-a.5;example;
# Check that this is still the solution
fem solve iterate 2 increment 0.5;

if( $TESTING )
  {
    fem def initial;w;myocardium-purkinje-r23-a.5
  }

# Output results for cmgui
fem export node;heart as heart
fem export elem;heart as heart
fem export elements;purkinje field as heart
fem export nodes;penet-a.5 field as heart

Files used by this example are:

Name                                Modified     Size

example_b222.com 20-Dec-2005 3.2k eik-ort-pet.ipequa 05-Dec-2003 1.0k gmres.ipsolv 16-Aug-2010 2.7k gmres.ipsolv.old 13-Apr-2007 2.5k heart-mr3.ipelem 05-Dec-2003 91k heart-mr3.ipelfb 05-Dec-2003 46k heart-mr3.ipfibr 05-Dec-2003 71k heart-mr3.ipnode 05-Dec-2003 345k hermite3.ipbase 05-Dec-2003 11k myocardium-penet.ipmate 05-Dec-2003 2.3k myocardium-purkinje-r23-a.5.ipinit 05-Dec-2003 243k myocardium-purkinje-r23.ipinit 05-Dec-2003 59k r23.ipelfd 05-Dec-2003 56k r23.ipfiel 05-Dec-2003 332k r23.ippara 05-Dec-2003 5.8k rc3d.ipcoor 05-Dec-2003 728 viewsol.com 21-Dec-2005 1.2k

Download the entire example:

Name                           Modified     Size

examples_b_b2_b22_b222.tar.gz 17-Aug-2010 152k

Testing status by version:

StatusTestedReal time (s)
i686-linux
cmSuccessSun Mar 6 00:04:04 20164
cm-debugSuccessSat Mar 5 00:24:22 201612
mips-irix
cmSuccessSun Aug 19 02:24:33 200754
cm-debugSuccessWed Aug 15 02:36:01 2007157
cm-debug-clear-mallocSuccessSat Aug 18 02:55:29 2007175
cm-debug-clear-malloc7SuccessMon Aug 20 02:52:42 2007171
cm64SuccessSun Aug 19 02:24:49 200754
cm64-debugSuccessTue Aug 21 02:39:12 2007160
cm64-debug-clear-mallocSuccessThu Apr 1 11:23:53 200473
rs6000-aix
cmSuccessWed Mar 4 01:11:37 20095
cm-debugSuccessMon Mar 2 01:17:33 200943
cm64SuccessWed Mar 4 01:11:39 20095
cm64-debugSuccessTue Mar 3 01:22:52 200943
x86_64-linux
cmSuccessSun Mar 6 00:01:11 20162
cm-debugSuccessSat Mar 5 00:02:08 20167

Testing status by file:


Html last generated: Sun Mar 6 05:51:15 2016

Input last modified: Mon Aug 16 11:26:28 2010


CMISS Help / Examples / b / b2 / b22 / b222