To generate the CA model, please follow the procedure listed below: 1. Generate the geometry of the CA: The geometry of the simulation is generated by the Matlab script generateLattice.m; execute this file in Matlab and two files will be generated: geometry.txt and location.txt. The file location.txt saves n columns of the three dimensional coordinates for n nodes. This file is read only, for visualisation. The file geometry.txt has the geometry/topology/neighbuorhood relations, and will be read by the simulator. Interested programmers may figure out the format of geometry.txt from generateLattice.m. You can also alter the geometry for the virtual atrium. 2. Run the simulator: Compile and execute simulator.cpp. Note that there are many things you can change to alter simulation dynamics. In particular, consider the following output variables: - par.coarseRecordStart - par.coarseRecordEnd - par.coarseRecordDt - par.detailedRecordStart - par.detailedRecordEnd - par.detailedRecordDt as well as the model parameters - par.initialDefectNumber - par.pvBurstActivationProb - par.restitutionA - par.restitutionB - par.restitutionTau Dynamically, the intrinsic stochasticity is controlled by a random seed RS1. Two RS1 values are provided for the cases of Sinus Rhythm/AF.
tygrin/atrial-fibrillation-cellular-automata
Supplementary source code for the manuscript: Mechanisms of stochastic onset and termination of atrial fibrillation episodes: Insights using a cellular automaton model
C++