About This Manual Conventions .xv Related Documentation xv PART I Signal Processing and Signal Analysis Chapter 1 Introduction to Digital Signal Processing and Analysis in LabVIEW The Importance of Data Analysis 1-1 Sampling Signals .1-2 Aliasing 1-4 Increasing Sampling Frequency to Avoid Aliasing .1-6 Anti-Aliasing Filters 1-7 Converting to Logarithmic Units .1-8 Displaying Results on a Decibel Scale 1-9 Chapter 2 Signal Generation Common Test Signals 2-1 Frequency Response Measurements 2-5 Multitone Generation .2-5 Crest Factor .2-6 Phase Generation .2-6 Swept Sine versus Multitone .2-8 Noise Generation .2-10 Normalized Frequency .2-12 Wave and Pattern VIs 2-14 Phase Control .2-14 Chapter 3 Digital Filtering Introduction to Filtering .3-1 Advantages of Digital Filtering Compared to Analog Filtering 3-1 Common Digital Filters .3-2 Impulse Response 3-2 Classifying Filters by Impulse Response 3-3 Filter Coefficients . 3-4 Characteristics of an Ideal Filter 3-5 Practical (Nonideal) Filters 3-6 Transition Band . 3-6 Passband Ripple and Stopband Attenuation . 3-7 Sampling Rate . 3-8 FIR Filters 3-9 Taps . 3-11 Designing FIR Filters 3-11 Designing FIR Filters by Windowing 3-14 Designing Optimum FIR Filters Using the Parks-McClellan Algorithm . 3-15 Designing Equiripple FIR Filters Using the Parks-McClellan Algorithm . 3-16 Designing Narrowband FIR Filters 3-16 Designing Wideband FIR Filters 3-19 IIR Filters . 3-19 Cascade Form IIR Filtering . 3-20 Second-Order Filtering . 3-22 Fourth-Order Filtering 3-23 IIR Filter Types . 3-23 Minimizing Peak Error . 3-24 Butterworth Filters 3-24 Chebyshev Filters . 3-25 Chebyshev II Filters 3-26 Elliptic Filters . 3-27 Bessel Filters . 3-28 Designing IIR Filters . 3-30 IIR Filter Characteristics in LabVIEW . 3-31 Transient Response . 3-32 Comparing FIR and IIR Filters 3-33 Nonlinear Filters 3-33 Example: Analyzing Noisy Pulse with a Median Filter 3-34 Selecting a Digital Filter Design . 3-35 Chapter 4 Frequency Analysis Differences between Frequency Domain and Time Domain 4-1 Parseval’s Relationship . 4-3 Fourier Transform . 4-4 Discrete Fourier Transform (DFT) 4-5 Relationship between N Samples in the Frequency and Time Domains .4-5 Example of Calculating DFT .4-6 Magnitude and Phase Information .4-8 Frequency Spacing between DFT Samples .4-9 FFT Fundamentals .4-12 Computing Frequency Components 4-13 Fast FFT Sizes .4-14 Zero Padding .4-14 FFT VI .4-15 Displaying Frequency Information from Transforms 4-16 Two-Sided, DC-Centered FFT 4-17 Mathematical Representation of a Two-Sided, DC-Centered FFT .4-18 Creating a Two-Sided, DC-Centered FFT .4-19 Power Spectrum .4-22 Converting a Two-Sided Power Spectrum to a Single-Sided Power Spectrum 4-23 Loss of Phase Information .4-25 Computations on the Spectrum 4-25 Estimating Power and Frequency 4-25 Computing Noise Level and Power Spectral Density .4-27 Computing the Amplitude and Phase Spectrums 4-28 Calculating Amplitude in Vrms and Phase in Degrees .4-29 Frequency Response Function .4-30 Cross Power Spectrum .4-31 Frequency Response and Network Analysis .4-31 Frequency Response Function .4-32 Impulse Response Function .4-33 Coherence Function .4-33 Windowing .4-34 Averaging to Improve the Measurement .4-35 RMS Averaging .4-35 Vector Averaging 4-36 Peak Hold 4-36 Weighting 4-37 Echo Detection .4-37 Chapter 5 Smoothing Windows Spectral Leakage 5-1 Sampling an Integer Number of Cycles 5-2 Sampling a Noninteger Number of Cycles 5-3 Windowing Signals 5-5 Characteristics of Different Smoothing Windows 5-11 Main Lobe . 5-12 Side Lobes . 5-12 Rectangular (None) . 5-13 Hanning . 5-14 Hamming . 5-15 Kaiser-Bessel 5-15 Triangle . 5-16 Flat Top . 5-17 Exponential . 5-18 Windows for Spectral Analysis versus Windows for Coefficient Design 5-19 Spectral Analysis . 5-19 Windows for FIR Filter Coefficient Design . 5-21 Choosing the Correct Smoothing Window 5-21 Scaling Smoothing Windows 5-23 Chapter 6 Distortion Measurements Defining Distortion 6-1 Application Areas . 6-2 Harmonic Distortion 6-2 THD 6-3 THD + N . 6-4 SINAD 6-4 Chapter 7 DC/RMS Measurements What Is the DC Level of a Signal? 7-1 What Is the RMS Level of a Signal? . 7-2 Averaging to Improve the Measurement . 7-3 Common Error Sources Affecting DC and RMS Measurements 7-4 DC Overlapped with Single Tone . 7-4 Defining the Equivalent Number of Digits . 7-5 DC Plus Sine Tone 7-5 Windowing to Improve DC Measurements 7-6 RMS Measurements Using Windows . 7-8 Using Windows with Care 7-8 Rules for Improving DC and RMS Measurements . 7-9 RMS Levels of Specific Tones . 7-9 Chapter 8 Limit Testing Setting up an Automated Test System .8-1 Specifying a Limit .8-1 Specifying a Limit Using a Formula .8-3 Limit Testing .8-4 Applications .8-6 Modem Manufacturing Example .8-6 Digital Filter Design Example .8-7 Pulse Mask Testing Example 8-8 PART II Mathematics Chapter 9 Curve Fitting Introduction to Curve Fitting .9-1 Applications of Curve Fitting 9-2 General LS Linear Fit Theory 9-3 Polynomial Fit with a Single Predictor Variable .9-6 Curve Fitting in LabVIEW 9-7 Linear Fit .9-8 Exponential Fit 9-8 General Polynomial Fit 9-8 General LS Linear Fit 9-9 Computing Covariance .9-10 Building the Observation Matrix 9-10 Nonlinear Levenberg-Marquardt Fit .9-11 Chapter 10 Probability and Statistics Statistics .10-1 Mean 10-3 Median .10-3 Sample Variance and Population Variance .10-4 Sample Variance .10-4 Population Variance 10-5 Standard Deviation 10-5 Mode 10-5 Moment about the Mean . 10-5 Skewness 10-6 Kurtosis . 10-6 Histogram 10-6 Mean Square Error (mse) 10-7 Root Mean Square (rms) . 10-8 Probability .10-8 Random Variables . 10-8 Discrete Random Variables 10-9 Continuous Random Variables . 10-9 Normal Distribution 10-10 Computing the One-Sided Probability of a Normally Distributed Random Variable 10-11 Finding x with a Known p 10-12 Probability Distribution and Density Functions 10-12 Chapter 11 Linear Algebra Linear Systems and Matrix Analysis . 11-1 Types of Matrices 11-1 Determinant of a Matrix 11-2 Transpose of a Matrix . 11-3 Linear Independence . 11-3 Matrix Rank 11-4 Magnitude (Norms) of Matrices . 11-5 Determining Singularity (Condition Number) 11-7 Basic Matrix Operations and Eigenvalues-Eigenvector Problems 11-8 Dot Product and Outer Product . 11-10 Eigenvalues and Eigenvectors 11-12 Matrix Inverse and Solving Systems of Linear Equations 11-14 Solutions of Systems of Linear Equations 11-14 Matrix Factorization 11-16 Pseudoinverse 11-17 Chapter 12 Optimization Introduction to Optimization . 12-1 Constraints on the Objective Function 12-2 Linear and Nonlinear Programming Problems . 12-2 Discrete Optimization Problems . 12-2 Continuous Optimization Problems 12-2 Solving Problems Iteratively . 12-3 Linear Programming 12-3 Linear Programming Simplex Method 12-4 Nonlinear Programming 12-4 Impact of Derivative Use on Search Method Selection 12-5 Line Minimization .12-5 Local and Global Minima 12-5 Global Minimum .12-6 Local Minimum .12-6 Downhill Simplex Method 12-6 Golden Section Search Method .12-7 Choosing a New Point x in the Golden Section 12-8 Gradient Search Methods 12-9 Caveats about Converging to an Optimal Solution .12-10 Terminating Gradient Search Methods .12-10 Conjugate Direction Search Methods 12-11 Conjugate Gradient Search Methods .12-12 Theorem A 12-12 Theorem B .12-13 Difference between Fletcher-Reeves and Polak-Ribiere 12-14 Chapter 13 Polynomials General Form of a Polynomial .13-1 Basic Polynomial Operations .13-2 Order of Polynomial 13-2 Polynomial Evaluation 13-2 Polynomial Addition .13-3 Polynomial Subtraction .13-3 Polynomial Multiplication .13-3 Polynomial Division 13-3 Polynomial Composition .13-5 Greatest Common Divisor of Polynomials 13-5 Least Common Multiple of Two Polynomials 13-6 Derivatives of a Polynomial 13-7 Integrals of a Polynomial .13-8 Indefinite Integral of a Polynomial .13-8 Definite Integral of a Polynomial 13-8 Number of Real Roots of a Real Polynomial 13-8 Rational Polynomial Function Operations .13-11 Rational Polynomial Function Addition 13-11 Rational Polynomial Function Subtraction .13-11 Rational Polynomial Function Multiplication .13-12 Rational Polynomial Function Division 13-12 Negative Feedback with a Rational Polynomial Function 13-12 Positive Feedback with a Rational Polynomial Function . 13-12 Derivative of a Rational Polynomial Function . 13-13 Partial Fraction Expansion 13-13 Heaviside Cover-Up Method 13-14 Orthogonal Polynomials 13-15 Chebyshev Orthogonal Polynomials of the First Kind . 13-15 Chebyshev Orthogonal Polynomials of the Second Kind . 13-16 Gegenbauer Orthogonal Polynomials . 13-16 Hermite Orthogonal Polynomials . 13-17 Laguerre Orthogonal Polynomials 13-17 Associated Laguerre Orthogonal Polynomials . 13-18 Legendre Orthogonal Polynomials . 13-18 Evaluating a Polynomial with a Matrix . 13-19 Polynomial Eigenvalues and Vectors . 13-20 Entering Polynomials in LabVIEW . 13-22 PART III Point-By-Point Analysis Chapter 14 Point-By-Point Analysis Introduction to Point-By-Point Analysis . 14-1 Using the Point By Point VIs 14-2 Initializing Point By Point VIs 14-2 Purpose of Initialization in Point By Point VIs 14-2 Using the First Call? Function 14-3 Error Checking and Initialization . 14-3 Frequently Asked Questions 14-5 What Are the Differences between Point-By-Point Analysis and Array-Based Analysis in LabVIEW? 14-5 Why Use Point-By-Point Analysis? 14-6 What Is New about Point-By-Point Analysis? 14-7 What Is Familiar about Point-By-Point Analysis? 14-7 How Is It Possible to Perform Analysis without Buffers of Data? . 14-7 Why Is Point-By-Point Analysis Effective in Real-Time Applications? 14-8 Do I Need Point-By-Point Analysis? 14-8 What Is the Long-Term Importance of Point-By-Point Analysis? . 14-9 Case Study of Point-By-Point Analysis 14-9 Point-By-Point Analysis of Train Wheels 14-9 Overview of the LabVIEW Point-By-Point Solution . 14-11 Characteristics of a Train Wheel Waveform . 14-12 Analysis Stages of the Train Wheel PtByPt VI .14-13 DAQ Stage 14-13 Filter Stage 14-13 Analysis Stage .14-14 Events Stage 14-15 Report Stage 14-15 Conclusion .14-16 Appendix A References Appendix B Technical Support and Professional Services AnalysisConcept