Decoding Heartbeats: Unveiling the Rhythm with Fourier Analysis part 1

kipngeno koech
4 min readDec 24, 2024

--

From our first article in this series, we learnt that signals can be either in frequency domain or time domain. Time domain we said, was a representation of signals as a function of time while frequency domain represents the same signal as a function of its constituent frequencies.

Fourier analysis transforms the signal from the time domain to the frequency domain.

TIME DOMAIN

In the time domain, a signal shows how a specific quantity, such as voltage or sound, changes over time. Take the ECG (Electrocardiogram) as an example - the waveform often depicted in movies before someone dies. The amplitude of this signal reflects the strength of the heart’s electrical activity or mechanical function during each heartbeat. When a person passes away, the waveform flattens because the heart has stopped functioning. At that moment, the amplitude becomes zero, signaling the cessation of heart activity.

The ECG is actually a perfect example of a composite signal. The amplitude represents the voltage generated by electrical impulses as the heart relaxes and contracts. Each heartbeat produces a characteristic waveform due to this electrical activity in the heart which can be broken down into:

source

1. P wave - atrial depolarization, the electrical impulse triggering the atria to contract
2. QRS complex - ventricular depolarization - the electrical impulse triggering the ventricles to contract
3. T wave - ventricular repolarization - the recovery phase of the ventricles.

note: The larger the amplitude the stronger the electrical activity in the heart.

The frequencies and amplitudes of an ECG signal for a healthy human being depend on the individual’s physiology and can vary slightly.

The heart rate frequency (main signal), for most healthy adults is 55- 85 beats per minute, in which when you convert to frequency (divide by 60 to get per second), it is like 0.6 Hz - 2 Hz. (if your heartbeat is 60 per minute, then the frequency is 1 Hz).

My heartbeat at the time of writing this blog is 74 beats per minute, that is like a frequency of 1.23 Hz.

ECG provides a detailed record of electrical activity of the heart during each heartbeat. The ECG signal records the electrical impulses that trigger heartbeats, and each cycle of the ECG corresponds to one heartbeat.

The ECG signal is a composite of at least three main components (P wave, QRS complex, T wave), along with potential noise. By applying Fourier analysis, we can decompose this signal into its individual frequency components, enabling us to separate and examine the heart-related signals from any noise present.

Frequency domain ( A high level overview of Fourier Analysis)

Fourier analysis is a mathematical technique used to transform a signal from the time domain to the frequency domain as alluded to earlier. This transformation allows us to understand the different frequency components that make up a signal.

In the case of an ECG (Electrocardiogram) signal, Fourier analysis helps us break down the complex waveform into individual frequencies, making it easier to study the various components of the heart’s electrical activity and separate it from noise

The ECG waveform typically consists of key components like the P wave, QRS complex, and T wave, each representing a phase of the heart’s electrical activity.

Fourier Transform converts the ECG signal from the time domain (where we observe how the signal changes over time) to the frequency domain (where we observe how the signal is made up of different frequency components).

This is done using the Fast Fourier Transform (FFT) algorithm ( we will look into this in the next blog), which efficiently computes the frequencies present in the signal. The result of the Fourier Transform is a spectrum that shows the magnitude of each frequency component in the signal.

source

The electrical activities of the heart (P wave, QRS complex, T wave) occupy a specific range of frequencies:

  • QRS complex: The largest and fastest electrical activity, often containing frequencies between 10–50 Hz.
  • P and T waves: These slower, lower-frequency activities typically range from 0.5–10 Hz.

Noise: High-frequency noise (from muscle activity or electrical interference) can appear in the spectrum and be filtered out to focus on the relevant heart signal.

conclusion

Fourier analysis helps transform the ECG signal from the time domain, where we see how the signal varies over time, to the frequency domain, where we can study the different frequencies that make up the signal. This allows us to isolate the heart’s electrical components, filter out noise, and gain deeper insights into heart health and rhythm abnormalities.

In the next article, we’ll dive into a hands-on Fourier analysis of heart data and explore the insights we can gain from both the time and frequency domains. Hopefully, the concepts of the time and frequency domains are starting to make more sense. See you in the next blog!

--

--

kipngeno koech
kipngeno koech

Written by kipngeno koech

You will find me here, lost in words, for it is my pen that listens and understands the depths of my soul.

No responses yet