Computers in Biology and Medicine 38 (2008) 53 – 61 www.intl.elsevierhealth.com/journals/cobm Design of a DSP-based instrument for real-time classification of pulmonary sounds Sameer Alsmadi a ,Yasemin P. Kahya b, ∗ a Institute of Biomedical Engineering, Bo˘ gaziçi University, 34342 Bebek, ˙ Istanbul, Turkey b Department of Electrical and Electronic Engineering, Bo˘ gaziçi University, 34342 Bebek, ˙ Istanbul, Turkey Received 28 August 2006; received in revised form 24 May 2007; accepted 5 July 2007 Abstract Auscultation of pulmonary sounds provides valuable clinical information but has been regarded as a tool of low diagnostic value due to the inherent subjectivity in the evaluation of these sounds. In this work, a Digital Signal Processor is used to design an instrument capable of acquiring, parameterizing and subsequently classifying lung sounds into two classes with an aim to evaluate them objectively in real time. The instrument operates on sound signal from a chest microphone and flow signal from a pneumotachograph. The classification is carried out separately on the 12 reference libraries (pathological and healthy) of six sub-phases of a full respiration cycle and the results are combined to arrive at a final decision. The k-nearest neighbour and minimum distance classifiers with different distance metrics have been implemented in the instrument. The instrument was tested in the clinical environment, attaining 96% accuracy in real-time classification. 2007 Elsevier Ltd. All rights reserved. Keywords: Pulmonary sounds; Autoregressive modelling; Digital signal processor; Real-time classification; Classifiers and distance metrics 1. Introduction Pulmonary sounds are believed to be produced due to air turbulence in the airways of the lungs although the exact mechanism of sound generation is still unknown. Since the lungs and the chest wall effectively act as a low-pass filter, the sounds transmitted to the skin are actually considered to be the filtered version of the original generated sounds [1]. On the other hand, the changes in lung structure that occur in some pathological conditions change the spectrum of sounds heard over the chest wall and may further cause the presence of additional abnormal sounds. Normal lung sounds are the respiratory sounds of healthy subjects heard over the chest wall above a certain flow rate and have a frequency range of 200–600 Hz. A sample of a lung sound waveform with the superimposed flow rate signal of a healthy subject is depicted in Fig. 1. Pathological lung sounds, on the other hand, usually contain higher frequency components with additional respira- tory sounds superimposed over them. These additional sounds ∗ Corresponding author. Tel.: +90 212 359 6851; fax: +90 212 287 2465. E-mail address: kahya@boun.edu.tr (Y.P. Kahya). 0010-4825/$ - see front matter 2007 Elsevier Ltd. All rights reserved. doi:10.1016/j.compbiomed.2007.07.001 are called adventitious breath sounds and, depending on their duration, they can be either continuous (i.e. wheezing if high pitched, rhonchi if low pitched), or discontinuous (i.e. fine crackles if high pitched, coarse crackles if low pitched) [2]. Since the invention of the first stethoscope by the French physician René Laënnec in 1816, auscultation via a stetho- scope is widely used by physicians as a simple, non-invasive and patient-friendly diagnostic method of chest diseases [2], where the sounds heard over the chest surface are correlated with the underlying pulmonary pathology. Despite its popular- ity, however, a stethoscope is not an ideal acoustic instrument since it does not provide a frequency-independent transmis- sion of sounds. Instead, it selectively amplifies lung sounds below 112Hz below which human ear is insensitive and atten- uates sounds at higher frequencies [3], which may result in loss of valuable information found at these frequencies since pul- monary sounds are known to contain frequencies up to 2000 Hz. In addition, auscultation with a stethoscope is a subjective pro- cess that depends on the experience and hearing capability of the individual, which may lead to a large variability in findings [4]. Moreover since auscultation does not allow a permanent record of data, long-term monitoring of pulmonary sounds