Preface....5
Motivation....5
Target Audience....6
Salient Features of the Book....6
Organization of the Book....7
Acknowledgments....9
Contents....10
About the Authors....15
Chapter 1: Generation of Continuous-Time Signals....17
1.1 Continuous-Time Signal....18
1.1.1 Continuous-Time Periodic Signal....19
1.1.2 Exponential Function....24
1.2 Non-stationary Signal....33
1.3 Non-sinusoidal Waveform....37
1.3.1 Square Waveform....37
1.3.2 Triangle and Sawtooth Waveform....38
1.3.3 Sinc Function....38
1.3.4 Pulse Signal....41
1.3.5 Gaussian Function....42
Bibliography....49
Chapter 2: Sampling and Quantization of Signals....50
2.1 Sampling of Signal....51
2.1.1 Violation of Sampling Theorem....54
2.1.2 Quantization of Signal....60
2.1.2.1 Mid-Tread Quantizer....61
2.1.3 Mid-Rise Quantizer....64
2.2 Non-uniform Quantization....70
2.3 Signal Reconstruction....74
2.3.1 Zero-Order Hold Interpolation....75
2.3.2 First-Order Hold Interpolation....77
2.3.3 Ideal or Sinc Interpolation....79
Bibliography....85
Chapter 3: Generation and Operation on Discrete-Time Sequence....86
3.1 Generation of Discrete-Time Signals....88
3.2 Mathematical Operation on Discrete-Time Signals....99
3.2.1 Amplitude Modification on DT Signal....99
3.2.1.1 Time Scaling Operation....106
3.2.1.2 Time Shifting Operation....108
3.2.1.3 Time Reversal Operation....110
3.3 Convolution....112
3.4 Correlation....126
Bibliography....137
Chapter 4: Discrete-Time Systems....138
4.1 Discrete-Time System....140
4.2 Representation of DT Systems....140
4.2.1 Difference Equation Representation of Discrete-Time Linear Time-Invariant System....140
4.2.2 State-Space Model of a Discrete-Time System....145
4.2.2.1 State-Space to Transfer Function....145
4.2.3 Impulse Response and Step Response of Discrete-Time System....149
4.2.4 Pole-Zero Plot of Discrete-Time System....154
4.3 Responses of Discrete-Time System....157
4.4 Different Representations and Response of Unit Delay Discrete-Time System....160
4.5 Properties of Discrete-Time System....164
4.5.1 Linearity Property....164
4.5.2 Time-Invariant and Time-Variant System....166
4.5.3 Causal and Non-causal System....168
4.5.4 Stability of Discrete-Time System....169
4.5.5 Invertibility of Discrete-Time System....173
Bibliography....180
Chapter 5: Transforms....181
5.1 Introduction to Transform....183
5.2 Z-Transform....183
5.2.1 Z-Transform of Standard Test Sequences....184
5.3 Inverse Z-Transform....187
5.4 Family of Fourier Series and Transforms....188
5.4.1 Continuous-Time Fourier Transform (CTFT)....189
5.4.2 Fourier Transform of Standard Test Signals....193
5.4.3 Discrete-Time Fourier Transform (DTFT)....205
5.4.4 Analysis of Discrete-Time LTI System Using DTFT....207
5.4.5 Discrete Fourier Transform....210
5.4.6 Properties of DFT....214
5.4.7 Limitations of Fourier Transform....218
5.5 Discrete Cosine Transform (DCT)....220
5.6 Short-Time Fourier Transform....224
5.6.1 Shortcoming of STFT....233
5.7 Continuous Wavelet Transform (CWT)....233
5.7.1 Continuous Wavelets Family....234
5.7.2 Drawback of CWT....235
5.8 Discrete Wavelet Transform....235
Bibliography....244
Chapter 6: Filter Design Using Pole-Zero Placement Method....245
6.1 First-Order IIR Filter....246
6.2 Moving Average filter....253
6.3 M-Point Exponentially Weighted Moving Average Filter (EWMA)....256
6.4 Digital Resonator....260
6.5 Notch Filter....262
6.6 All-Pass Filter....265
6.7 Comb Filter....269
6.7.1 Location of Poles and Zeros of Comb Filter....270
Bibliography....275
Chapter 7: FIR Filter Design....276
7.1 FIR Filter....277
7.2 Classification of FIR Filter....277
7.3 Design of FIR Filter....284
7.3.1 Steps in Window-Based FIR Filter Design....285
7.3.2 Window-Based FIR Lowpass Filter....286
7.3.3 Window-Based FIR Highpass Filter....289
7.3.4 Window-Based FIR Bandpass Filter....291
7.3.5 Window-Based FIR Band Reject Filter....293
7.3.6 Design of FIR Filter Using Built-In Function....295
7.3.7 Window Functions....301
7.4 Frequency Sampling-Based FIR Filter Design....304
7.5 Design of Optimal FIR filter....306
7.6 Applications of FIR Filter....307
Bibliography....315
Chapter 8: Infinite Impulse Response Filter....316
8.1 IIR Filter....317
8.2 Mapping Techniques in the Design of IIR Filter....319
8.2.1 Backward Difference Method....320
8.2.2 Impulse Invariant Technique....323
8.2.3 Bilinear Transformation Technique (BLT)....333
8.2.4 Matched Z-Transform Technique....336
8.3 Analog Frequency Transformation....339
8.4 Butterworth Filter....341
8.5 Chebyshev Filter....357
8.6 Chebyshev Type II IIR Filter....371
8.7 Elliptic Filter....375
Bibliography....389
Chapter 9: Quantization Effect of Digital Filter Coefficients....390
9.1 Number Representation....391
9.2 Fixed-Point Quantization....391
9.2.1 Fixed-Point Quantization by Rounding....392
9.2.2 Fixed-Point Quantization Using Two´s Complement Truncation....393
9.2.3 Fixed-Point Quantization Using Magnitude Truncation....394
9.3 Coefficient Quantization....396
9.4 Limit Cycle Oscillations....405
9.5 Cascade Form of a Higher Order Filters....410
Bibliography....414
Chapter 10: Multirate Signal Processing....416
10.1 Multirate Operators....418
10.1.1 Downsampling Operation....418
10.1.2 Upsampling Operation....422
10.2 Noble Identity....426
10.2.1 Noble Identity for Downsampling Operation....426
10.2.2 Noble Identity for Upsampling Operation....428
10.3 Polyphase Decomposition....430
10.4 Filter Bank....432
10.4.1 Two-Channel Filter Bank....433
10.4.2 Relationship Between Analysis and Synthesis Filters....434
10.4.3 Two-Channel Filter Bank Without Filters....437
10.4.4 Three-Channel Filter Bank Without Filters....439
10.5 Tree-Structured Filter Bank....441
10.6 Transmultiplexer....444
Bibliography....453
Chapter 11: Adaptive Signal Processing....455
11.1 Wiener Filter....456
11.1.1 Wiener Filter in Frequency Domain....459
11.2 Adaptive Filter....463
11.2.1 LMS Adaptive Filter....464
11.2.2 Normalized LMS Algorithm....469
11.2.3 Sign LMS Algorithm....471
11.3 RLS Algorithm....474
Bibliography....480
Chapter 12: Case Study....481
12.1 Case Study 1: Speech Recognition Using MFCC (Mel-Frequency Cepstral Coefficient)....481
12.1.1 Speaker Identification....482
12.1.2 Speaker Verification System....483
12.1.3 Mel-Frequency Cepstral Coefficient (MFCC) Feature....484
12.1.3.1 Pre-emphasis....484
12.1.3.2 Sampling and Windowing....484
12.1.3.3 Discrete Fourier Transform (DFT)....486
12.1.3.4 Mel-Frequency Bandpass Filter....488
12.1.3.5 Log Operation....490
12.1.3.6 Discrete Cosine Transform (DCT)....490
12.2 Case Study 2: QRS Detection in ECG Signal Using Pan-Tomkins Algorithm....491
12.2.1 ECG Signal Preprocessing....493
12.2.1.1 Bandpass filter....494
12.2.1.2 Derivative Process....495
12.2.1.3 Squaring Operation....495
12.2.2 Moving Window Integration....496
12.2.3 Fiducial Mark....496
12.2.4 Decision Rule Approach....498
12.3 Case Study 3: Power Quality Disturbance Detection....500
12.3.1 Generation of Power Quality Disturbance....501
12.3.2 Simulation of Power Quality Disturbance....503
12.3.3 Time-Frequency Representation of Power Quality Disturbance....504
12.3.4 Time-Scale Representation of Power Quality Disturbance....505
Bibliography....508
Appendix....509
Chapter 1: Generation Of Continuous-Time Signals....509
Answers to PreLab Questions....509
Answers to Objective Questions....511
Chapter 2: Sampling and Quantization of Signals....512
Answers to PreLab Questions....512
Answers to Objective Questions....513
Chapter 3: Generation and Operation on Discrete-Time Sequence....513
Answers to PreLab Questions....513
Answers to Objective Questions....515
Chapter 4: Discrete-Time Systems....515
Answers to PreLab Questions....515
Answers to Objective Questions....518
Chapter 5: Transforms....518
Answers to PreLab Questions....518
Answers to Objective Questions....520
Chapter 6: Filter Design Using Pole-Zero Placement Method....520
Answers to PreLab Questions....520
Answers to Objective Questions....521
Chapter 7: FIR Filter Design....521
Answers to PreLab Questions....521
Answers to Objective Questions....523
Chapter 8: Infinite Impulse Response Filter....523
Answers to PreLab Questions....523
Answers to Objective Questions....525
Chapter 9: Quantization Effect of Digital Filter Coefficients....525
Answers to PreLab Questions....525
Answer to Objective Questions....526
Chapter 10: Multirate Signal Processing....527
Answers to PreLab Questions....527
Answers to Objective Questions....529
Chapter 11: Adaptive Signal Processing....529
Answers to PreLab Questions....529
Answers to Objective Questions....530
Index....531
Digital signal processing deals with extraction of useful information from signals. Signal processing algorithms help observe, analyse and transform signals. The objective of this book is to develop signal processing algorithms using Python. Python is an interpreted, object-oriented high-level programming language widely used in various software development fields such as data science, machine learning, web development and more.
Digital Signal Laboratory is playing an important role in realizing signal processing algorithms, utilizing different software solutions. The intention of this textbook is to implement signal processing algorithms using Python. Since Python is an open-source language, students, researchers, and faculty can install and work with it without spending money, reducing the financial burden on institutions. Each chapter in this book begins with prelab questions, a set of Python examples to illustrate the concepts, exercises to strengthen the understanding of the concepts, and objective questions to help students prepare for competitive examinations.
This book serves as an undergraduate textbook, it can be used for individual study, and it can also be used as the textbook for related courses.