BME355 Lab Listing: Biosignals
Top navigation banner.


Biosignal Processing


Preparation

Lab Outline

Procedure

Learning more


Quiz

GOALS

To understand one-dimensional data acquisition and processing, including the sampling theorem, quantization effects, the frequency domain, windowing and filtering.

Biosignals originate from a variety of sources:

Bio-electric signals: generated by nerve and muscle cells by the membrane potential. The action potential of the cell itself may be measured in single cell recordings. Surface electrodes can be used to measure the field generated by many cells in the vicinity of the electrode due to the propagation through tissue.

Bio-impedance signals: tissue impedance provides information about composition, blood volume and distribution, endocrine activity, etc. Test sinusoidal currents may be injected into the tissue using a frequency range (50KHz-1MHz) to minimize electrode polarizations problems and low current (20MicroA to 20mA) to avoid tissue heating. The voltage drop due to the current and tissue impedance is measured.

Bio-acoustic signals: due to acoustic noise created by biological phenomena. Examples include the flow of blood in the heart or through vessels, the flow a air in the lungs and airways, in the joints and in the digestive tract. Sounds propagate and may be acquired on the surface with, for example, microphones.

Biomagnetic signals: Organs such as the heart, brain and lungs produce a weak magnetic field. These signals tend to have a low signal to noise due to the extremely low field strength.

Biomechanical signals: arising from a mechanical function of a biologic system such as motion, displacement, pressure, tension and flow. Since the mechanical phenomenon does not propagate, measurement must be performed at the site making the measurement difficult and invasive.

Biochemical signals: resulting from chemical measurements of tissue or samples. Example: measurement of ion concentration inside or near a cell using ion electrodes. These are typically low frequency signals.

Bio-optical signals: from optical functions of a biologic system, naturally occuring or induced. Example: blood oxygenation may be estimated by measuring the transmitted and backscattered light from a tissue.


Acquisition sequence:


Math Preliminaries

Convolution:

Convolution is defined as:

The integrand is the product of two functions with the latter flipped and shifted.


See this java demonstration of convolution for a graphical explanation.

Fourier Transform:

Any signal can be considered to be a sum of an infinite number of sinusoidal waves of different frequencies. Think of a musical audio signal being composed of high and low notes. The Fourier transform is particularly important for linear (adding/scaling inputs results in adding/scaling outputs), time-invariant (a shift in the input gives a shift in the output) systems. The response of such systems to a complex exponential (sinusoid) is just a constant times the input. The Fourier transform is the weight or magnitude of each component frequency and is computed by this integral:



Inverse Fourier Transform:

We can recover the original signal from its frequency domain representation using:

x is a linear combination of elementary periodic patterns (complex exponentials - sinusoids). X is a measure of the relative contributions of each sinusoid. A useful property of the Fourier transform is that convolution in the signal domain becomes multiplication in the frequency domain (and vice versa, actually).

Thus,

For discrete signals, such as we will deal with, the analogous transform is the discrete Fourier transform:


Note, we will get a negative and positive peak for any frequency component, i.e. for a 100Hz signal, we will get components at 100 and -100.


Whitaker Shannon Sampling theorem:

Consider a signal x(t) bandlimited to ±W/2. This means that X(f), the Fourier transform of x, is equal to 0 for f >= W/2. If this signal is sampled at a frequency greater than W, it can be recovered from its sampled version. Thus, we need to sample at least twice the rate of the highest frequency in the signal. See Appendix for more detail.

Aliasing:

Signals which include frequencies outside the bandlimit determined by the sampling rate will be aliased when sampled. The replicated spectra will overlap and high frequencies will appear shifted or aliased as low frequencies. Each frequency is shifted down to below the maximum frequency (half the sampling frequency). See Appendix below for more on sampling.


If the analog signal contains higher frequencies than half the sampling frequency, as in this example, the digitized signal will contain spurious oscillations not present in the original signal.

Power spectrum of an EEG signal originally bandlimited to 40Hz. The presence of 50 Hz noise in the original signal (a) causes an aliasing error in the 30Hz component in the sampled signal (b) if the sampling frequency is 80Hz.

[ Quantization:

Quantization produces a discrete signal, whose samples can only take certain values, using either rounding or truncation. The range of values is typically divided evenly (uniform quantization). Signals are commonly quantized to 8, 12 or 16 bits. The quantization interval = (high limit - low limit)/(2# of bits). Decreasing the range of the limits can therefore improve quantization.


Quantization can be described by a statistical model with probability densities for rounding (e) and truncation (f) for a given quantization interval, delta.

]

Fourier Spectrum Analysis:

The frequency resolution of the frequency plot is determined by the total number of samples, n, used in the DFT and the sampling rate or frequency. The maximum frequency contained in the DFT is determined by the sampling rate where fmax = (sampling rate)/2. Thus, the frequency resolution is (sampling rate)/npts. The number of points in the time domain should be a power of 2 for computational efficiency.


A lower sampling rate can improve spectral resolution. Part a uses twice the sampling rate of part b. By lowering the sampling rate (still avoiding aliasing), we obtain more samples in the interesting range of the spectrum.


Windowing:

Calculation of various functions requires the knowledge of the signal from minus infinity to plus infinity. The signal, of course, is not available for arbitrarily long durations. We must use a windowing signal instead.

A window w(t) is defined as a real and even time limited function (w(t) = 0 for |t| > T/2). The FT of the window is therefore real, even and not band-limited. Multiplying the signal by the window function will zero the signal outside the window duration (observation period) resulting in a windowed, time-limited signal s_w(t) = s(t)w(t). In the frequency domain, we have S_w(f) = S(f) * W(f). Windowing convolves the true spectrum of the signal with the FT of the window. Thus, a window with very narrow spectrum will cause low distortions. Sidelobes cause distortions. The simplest window is rectangular. More useful are, for example, the Hamming window and the Hann window designed to minimize the effects of the sidelobes.


Filtering:

Digital filtering can be used to improve a signal by removing noise or other unwanted components from the signal after it has been acquired indigital form. Digital filters are more flexible and do not require the precision hardware of analog filters (performed with circuitry). The design of these filters is a whole field and outside of the scope of this course. In their simplest form, they are functions that are convolved with the signal.

Filters are characterized by their behavior in the frequency domain. Low pass filters remove high frequencies (the stop band) and leave the low frequencies alone (the pass band). High pass filters remove low frequencies and leave the high frequencies alone. Band pass filters only pass frequencies in a given range. Band stop filters remove frequencies in a given range. None are ideal, however, and the degree to which they cut-off the designated frequencies (the steepness of the transition from stopband to passband; the size of undesired side lobes) characterizes their behavior.



Appendix: Sampling Theorem

Sampling:

Sampling a function can be expressed as a multiplication with a comb function (a train of delta functions):

Sampling x(t) with an interval of b is then:

In the Fourier domain, the comb is convolved with the Fourier transform of the function and acts as a replicator:

We can recover the original signal by low-pass filtering X_s(f) (multiply by a rect) to select out the central order, as long as they do not overlap. The sampling theorem specifies this.

Dirac delta function:

The dirac delta function is a generalized function, or distribution representing an infinitely brief, infinitely strong, unit area impulse. It is represented graphically as an arrow of unit height. It can be considered as the limit of a function, such as a Gaussian or rectangle, which gets narrower and taller preserving the area under the curve. It can also be considered to be the derivative of the unit step function.

Some properties:


Comb Function:

A train of impulses or delta functions is called a comb function:



From delta function properties, we can see:


Then, a comb with spacing b is:




Sampling with a Comb:





In multiplying, the comb acts to sample x(t). The samples are spaced by b.

Convolving with a Comb:

The comb acts as a replicator when it convolves something. Convolution with a shifted delta function is:





Convolution with a comb replicates the function at each delta function as you slide x along.

Fourier Transform of a Comb:

Remarkably, the Fourier transform of a comb is a comb.


The Fourier transform of a sampled function is a replication of the transform of the unsampled version.




Whitaker Shannon Sampling theorem:

Given a function x(t) bandlimited to +-W/2 (X(f) = 0 for f >= W/2), it can be recovered from its sampled version by:

where t_s is the sampling interval, f_s = 1/t_s is the sampling rate, f_c is the cut-off frequency.
1/t_s = W is the Nyquist sampling rate.

Thus, in general, we need to sample at least twice the rate of the highest frequency in the signal.

Aliasing:

When undersampled, the replicated spectra overlap and this causes aliasing.
Bottom navigation banner.