Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
LabVIEW-Measurements.pdf
Скачиваний:
61
Добавлен:
29.05.2015
Размер:
3.37 Mб
Скачать

Chapter 11 Introduction to Measurement Analysis in LabVIEW

By analyzing and processing the digital data, you can extract the useful information from the noise and present it in a form more comprehensible than the raw data, as shown in Figure 11-2.

Figure 11-2. Processed Data

The LabVIEW block diagram programming approach and the extensive set of LabVIEW Measurement Analysis VIs simplify the development of analysis applications.

The LabVIEW Measurement Analysis VIs give you the most recent data analysis techniques using VIs that you can wire together. Instead of worrying about implementation details for analysis routines, as you do in conventional programming languages, you can concentrate on solving your data analysis problems.

Data Sampling

Sampling Signals

To use digital signal processing techniques, you must first convert an analog signal into its digital representation. In practice, this is implemented by using an analog-to-digital (A/D) converter. Consider an analog signal x(t) that is sampled every ∆ t seconds. The time interval ∆ t is known as the sampling interval or sampling period. Its reciprocal, 1/∆ t, is known as the sampling frequency, with units of samples/second. Each of the discrete values of x(t) at t = 0, ∆ t, 2∆ t, 3∆ t, etc., is known as a sample. Thus, x(0), x(∆ t), x(2∆ t), ...., are all samples. The signal x(t) can thus be represented by the discrete set of samples

{x(0), x(∆ t), x(2∆ t), x(3∆ t), …, x(kt), … }

LabVIEW Measurements Manual

11-2

www.ni.com

Chapter 11 Introduction to Measurement Analysis in LabVIEW

Figure 11-3 below shows an analog signal and its corresponding sampled version. The sampling interval is ∆ t. Observe that the samples are defined at discrete points in time.

1.1

t = distance between samples along time axis

t

0.0

-1.1

 

 

 

 

 

 

 

 

 

 

0.0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1.0

Figure 11-3. Analog Signal and Corresponding Sampled Version

The following notation represents the individual samples:

x[i] = x(it)

for

i = 0, 1, 2, …

If N samples are obtained from the signal x(t), then x(t) can be represented by the sequence

X = {x[0], x[1], x[2], x[3], …, x[N– 1] }

This is known as the digital representation or the sampled version of x(t). Note that the sequence X = {x[i]} is indexed on the integer variable i, and does not contain any information about the sampling rate. So by knowing just the values of the samples contained in X, you will have no idea of what the sample rate is.

Sampling Considerations

A/D converters (ADCs) are an integral part of National Instruments DAQ boards. One of the most important parameters of an analog input system is the rate at which the DAQ device samples an incoming signal. The sampling rate determines how often an analog-to-digital (A/D) conversion takes place. A fast sampling rate acquires more points in a given

© National Instruments Corporation

11-3

LabVIEW Measurements Manual

Chapter 11 Introduction to Measurement Analysis in LabVIEW

time and can therefore often form a better representation of the original signal than a slow sampling rate. Sampling too slowly may result in a poor representation of your analog signal. Figure 11-4 shows an adequately sampled signal, as well as the effects of undersampling. The effect of undersampling is that the signal appears as if it has a different frequency than it truly does. This misrepresentation of a signal is called an alias.

Adequately Sampled Signal

Aliased Signal Due to Undersampling

Figure 11-4. Aliasing Effects of an Improper Sampling Rate

According to Shannon’s theorem, to avoid aliasing you must sample at a rate greater than twice the maximum frequency component in the signal you are acquiring. For a given sampling rate, the maximum frequency that can be represented accurately, without aliasing, is known as the Nyquist frequency. The Nyquist frequency is one half the sampling frequency. Signals with frequency components above the Nyquist frequency will appear aliased between DC and the Nyquist frequency. The alias frequency is the absolute value of the difference between the frequency of the input signal and the closest integer multiple of the sampling rate. Figures 11-5 and 11-6 illustrate this phenomenon. For example, assume fs, the sampling frequency, is 100 Hz. Also, assume the input signal contains the following frequencies—25 Hz, 70 Hz, 160 Hz, and 510 Hz. These frequencies are shown in Figure 11-5.

LabVIEW Measurements Manual

11-4

www.ni.com

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]