Decoding the Heartbeat: A Computational Intelligence Framework Coupling Nonlinear ODE Dynamics and Deep Attention Networks for Cardiac Arrhythmia Detection

Authors

  • Aziza Rashed Department of Computer Science, Faculty of Science, University of Tobruk, Tobruk, Libya Author
  • Bader Masry Department of Mathematics, Faculty of Science, University of Tobruk, Tobruk, Libya Author
  • Emad E. M. Awadh Department of Mathematics, Faculty of Science, University of Tobruk, Tobruk, Libya Author

DOI:

https://doi.org/10.54361/LJMR.20.3.97

Keywords:

Electrocardiogram (ECG), Inter-patient Splitting, Patient-wise Evaluation, Non-linear ODE Model, Limit Cycle Attractor, Discrete Wavelet Transform (DWT), 1D-CNN-BiGRU-Attention, McNemar Test, Ablation Study, AAMI

Abstract

Background: Automated electrocardiogram (ECG) heartbeat classification plays a paramount role in the early diagnosis of cardiovascular diseases [1, 2, 10]. However, existing deep-learning approaches frequently suffer from severe data leakage caused by beat-level data splitting [6, 9], class imbalance in benchmark databases like MIT-BIH [13, 17, 25], and a lack of statistical significance testing and explicit ablation analyses validating complex hybrid network extensions.

Methodology: To overcome these methodological pitfalls, this paper presents a fully revised, patient-wise rigorous computational intelligence framework. First, a three-dimensional coupled non-linear Ordinary Differential Equation (ODE) limit-cycle model (McSharry-type) [19] generates synthetic cardiac signals to augment minority classes exclusively within the training partition. Second, raw ECG signals are processed using a 4th-order zero-phase Butterworth band-pass filter (0.5–45 Hz) [3] and a 60 Hz IIR notch filter [4]. Third, an inter-patient (patient-wise) 70/15/15 train/validation/test split protocol is strictly applied to the MIT-BIH Arrhythmia Database [25, 26] to eliminate data leakage. Isolated 360-sample heartbeat segments centered on R-peaks detected via Pan-Tompkins [21] or Elgendi [22] methods are classified into ANSI/AAMI EC57 categories (Normal, Supraventricular Ectopic Beats, Ventricular Ectopic Beats) [23] using a hybrid 1D-CNN-BiGRU network [9, 12, 14, 16] equipped with Bahdanau-type additive attention [18, 24]. Hand-crafted wavelet features extracted via Discrete Wavelet Transform (Symlet-4) [15, 20] serve as inputs for classical Random Forest and SVM baselines [5].Results: Under strict patient-wise evaluation, the proposed ODE-augmented 1D-CNN-BiGRU-Attention network achieved an overall test accuracy of 97.40%, with per-class F1-scores of 0.981 (N), 0.884 (SVEB), and 0.942 (VEB). McNemar’s exact test confirmed that the performance gain over the standalone 1D-CNN baseline [11, 12] was statistically significant (p < 0.001, beat-level and exploratory; to be re-verified). Systematic ablation experiments verified that ODE-based synthetic augmentation contributed +2.15% directly to SVEB sensitivity. Conclusion: Enforcing methodological rigor—specifically inter-patient partitioning [6], statistical significance testing, and ablation studies—is crucial for realistic clinical evaluation [1, 2]. Coupling analytical ODE dynamics [19] with an attention deep architecture [18, 24] gives promising patient-wise performance on MIT-BIH; validation on larger independent cohorts is required before any claim of clinical transferability.

Downloads

Download data is not yet available.

References

1. Luz, E. J. S., Schwartz, W. R., Cámara-Chávez, G., & Menotti, D. (2016). ECG-based heartbeat classification for arrhythmia detection: A survey. Computer Methods and Programs in Biomedicine, 127, 144–164. https://doi.org/10.1016/j.cmpb.2015.12.008

2. Hong, S., Zhou, Y., Shang, J., Xiao, C., & Sun, J. (2020). Opportunities and challenges of deep learning methods for electrocardiogram data: A systematic review. Computers in Biology and Medicine, 122, 103801. https://doi.org/10.1016/j.compbiomed.2020.103801

3. Clifford, G. D., Azuaje, F., & McSharry, P. E. (Eds.). (2006). Advanced Methods and Tools for ECG Data Analysis. Artech House. ISBN 9781580539661. https://books.google.com/books?vid=ISBN9781580539661

4. Sayadi, O., & Shamsollahi, M. B. (2008). ECG denoising and compression using a modified extended Kalman filter structure. IEEE Transactions on Biomedical Engineering, 55(9), 2240–2248. https://doi.org/10.1109/TBME.2008.921150

5. Ye, C., Kumar, B. V. K. V., & Coimbra, M. T. (2012). Heartbeat classification using morphological and dynamic features of ECG signals. IEEE Transactions on Biomedical Engineering, 59(10), 2930–2941. https://doi.org/10.1109/TBME.2012.2212896

6. De Chazal, P., O’Dwyer, M., & Reilly, R. B. (2004). Automatic classification of heartbeats using ECG morphology and heartbeat interval features. IEEE Transactions on Biomedical Engineering, 51(7), 1196–1206. https://doi.org/10.1109/TBME.2004.827359

7. Kachuee, M., Fazeli, S., & Sarrafzadeh, M. (2018). ECG heartbeat classification: A deep transferable representation. In Proc. IEEE International Conference on Healthcare Informatics (ICHI). arXiv:1805.00794. https://doi.org/10.48550/arXiv.1805.00794

8. Al Rahhal, M. M., Bazi, Y., AlHichri, H., Alajlan, N., Melgani, F., & Yager, R. R. (2016). Deep learning approach for active classification of electrocardiogram signals. Information Sciences, 345, 340–354. https://doi.org/10.1016/j.ins.2016.01.082

9. Kiranyaz, S., Ince, T., & Gabbouj, M. (2016). Real-time patient-specific ECG classification by 1-D convolutional neural networks. IEEE Transactions on Biomedical Engineering, 63(3), 664–675. https://doi.org/10.1109/TBME.2015.2468589

10. Hannun, A. Y., Rajpurkar, P., Haghpanahi, M., Tison, G. H., Bourn, C., Turakhia, M. P., & Ng, A. Y. (2019). Cardiologist-level arrhythmia detection and classification in ambulatory electrocardiograms using a deep neural network. Nature Medicine, 25(1), 65–69. https://doi.org/10.1038/s41591-018-0268-3

11. Acharya, U. R., Oh, S. L., Hagiwara, Y., Tan, J. H., Adam, M., Gertych, A., & San Tan, R. (2017). A deep convolutional neural network model to classify heartbeats. Computers in Biology and Medicine, 89, 389–396. https://doi.org/10.1016/j.compbiomed.2017.08.022

12. Acharya, U. R., Fujita, H., Oh, S. L., Hagiwara, Y., Tan, J. H., & Adam, M. (2017). Automated detection of arrhythmias using different intervals of tachycardia ECG segments with convolutional neural network. Information Sciences, 405, 81–90. https://doi.org/10.1016/j.ins.2017.04.012

13. Sellami, A., & Hwang, H. (2019). A robust deep convolutional neural network with batch-weighted loss for heartbeat classification. Expert Systems with Applications, 122, 75–84. https://doi.org/10.1016/j.eswa.2018.12.037

14. Oh, S. L., Ng, E. Y. K., Tan, R. S., & Acharya, U. R. (2018). Automated diagnosis of arrhythmia using combination of CNN and LSTM techniques with variable length heart beats. Computers in Biology and Medicine, 102, 278–287. https://doi.org/10.1016/j.compbiomed.2018.06.002

15. Wang, T., Lu, C., Sun, Y., Yang, M., Liu, C., & Ou, C. (2021). Automatic ECG classification using continuous wavelet transform and convolutional neural network. Entropy, 23(1), 119. https://doi.org/10.3390/e23010119

16. Yildirim, Ö. (2018). A novel wavelet sequence based on deep bidirectional LSTM network model for ECG signal classification. Computers in Biology and Medicine, 96, 189–202. https://doi.org/10.1016/j.compbiomed.2018.03.016

17. Rajesh, K. N. V. P. S., & Dhuli, R. (2018). Classification of imbalanced ECG beats using re-sampling techniques and AdaBoost ensemble classifier. Biomedical Signal Processing and Control, 41, 242–254. https://doi.org/10.1016/j.bspc.2017.12.004

18. Yao, Q., Wang, R., Fan, X., Liu, J., & Li, Y. (2020). Multi-class arrhythmia detection from 12-lead varied-length ECG using attention-based time-incremental convolutional neural network. Information Fusion, 53, 174–182. https://doi.org/10.1016/j.inffus.2019.06.024

19. McSharry, P. E., Clifford, G. D., Tarassenko, L., & Smith, L. A. (2003). A dynamical model for generating synthetic electrocardiogram signals. IEEE Transactions on Biomedical Engineering, 50(3), 289–294. https://doi.org/10.1109/TBME.2003.808805

20. Mallat, S. (2009). A Wavelet Tour of Signal Processing: The Sparse Way (3rd ed.). Academic Press. ISBN 9780123743701. https://books.google.com/books?vid=ISBN9780123743701

21. Pan, J., & Tompkins, W. J. (1985). A real-time QRS detection algorithm. IEEE Transactions on Biomedical Engineering, 32(3), 230–236. https://doi.org/10.1109/TBME.1985.325532

22. Elgendi, M. (2013). Fast QRS detection with an optimized knowledge-based method: Evaluation on 11 standard ECG databases. PLoS ONE, 8(9), e73557. https://doi.org/10.1371/journal.pone.0073557

23. Association for the Advancement of Medical Instrumentation. (2012). Testing and reporting performance results of cardiac rhythm and ST segment measurement algorithms (ANSI/AAMI EC57:2012). https://webstore.ansi.org/search/find?in=1&st=EC57

24. Bahdanau, D., Cho, K., & Bengio, Y. (2015). Neural machine translation by jointly learning to align and translate. In Proc. 3rd International Conference on Learning Representations (ICLR). arXiv:1409.0473. https://doi.org/10.48550/arXiv.1409.0473

25. Moody, G. B., & Mark, R. G. (2001). The impact of the MIT-BIH Arrhythmia Database. IEEE Engineering in Medicine and Biology Magazine, 20(3), 45–50. https://doi.org/10.1109/51.932724

26. Goldberger, A. L., Amaral, L. A. N., Glass, L., Hausdorff, J. M., Ivanov, P. C., Mark, R. G., Mietus, J. E., Moody, G. B., Peng, C.-K., & Stanley, H. E. (2000). PhysioBank, PhysioToolkit, and PhysioNet: Components of a new research resource for complex physiologic signals. Circulation, 101(23), e215–e220. https://doi.org/10.1161/01.CIR.101.23.e215

27. Sun, J. (2023). Automatic cardiac arrhythmias classification using CNN and attention-based RNN network. Healthcare Technology Letters, 10(3), 53–61. https://doi.org/10.1049/htl2.12045

Downloads

Published

20-10-2026

Issue

Section

Articles

How to Cite

1.
Rashed A, Masry B, Awadh E. Decoding the Heartbeat: A Computational Intelligence Framework Coupling Nonlinear ODE Dynamics and Deep Attention Networks for Cardiac Arrhythmia Detection. LJMR [Internet]. 2026 Oct. 20 [cited 2026 Oct. 20];20(3):695-707. Available from: https://ljmr.ly/index.php/ljmr/article/view/654

Similar Articles

1-10 of 170

You may also start an advanced similarity search for this article.