It is often needed to know how the frequency content of a signal changes with time. This is true even of short time-duration events like clicks, clunks, and slams. Traditional Fourier transform methods usually do not work well for these short duration events.
Wavelets are an alternative method to determine the frequency content vs time of transient events.
See Figure 1 (below) for a comparison of Fourier transform (FFT) methods vs the wavelet method.
Notice that the wavelet method provides more detailed information about what frequency content is present at various times.
The wavelet method gives much finer resolution in both time and frequency.
This article will cover the following:
The traditional FFT decomposes a time signal into its component sine functions of various frequency, amplitude, and phase.
From there, a spectrum (a plot of amplitude vs frequency) is generated. It is possible to calculate many spectrums for a single signal to see how the amplitudes and frequencies change with time.
When calculating a spectrum, there is an inverse relationship between observation time and frequency resolution. Essentially, the longer the time-chunk that is analyzed, the finer the frequency resolution that can be obtained in the spectrum.
This means that when analyzing very short-time events (transients) with a short time window, the frequency resolution is forced to be rather coarse. If the frequency resolution is refined, the time block will be much greater than the transient event.
Therefore, when doing an FFT on short time duration events, there is a fair bit of smearing in the frequency domain due to coarse frequency resolution. When attempting to dial in a finer frequency resolution, the time domain resolution will suffer (Figure 3, below).
This is a disadvantage when using the FFT on short-time events.
On the other hand, the signal can be decomposed into wavelets (instead of sine functions).
A wavelet is a function that rapidly increases, oscillates about a zero mean, and rapidly decays.
In order to understand how wavelets correspond to frequency and time, let’s take a look at scaling and shifting.
Scaling is straight forward, the wavelet is simply stretched or compressed in time.
A stretched wavelet (Figure 5, below, left) helps quantify the slow changing portion of a signal (low frequency) while a compressed wavelet (Figure 5, below, right) helps quantify the abruptly changing (high frequency) content of the signal.
The wavelet in the frequency domain has a band-pass characteristic. By stretching and compressing the wavelet, the center frequency of the band-pass filter is shifted higher or lower.
Now that the frequency component is understood, let’s discuss the time component.
The output of the wavelet analysis is frequency (scale) vs. time (shift). The wavelet is both shifted and scaled to determine how it aligns with various features of the signal.
For the purposes of simplicity, imagine that the wavelet is shifted though the time data. At each location, the shape of the wavelet is “compared” to the shape of the time data. Similarities between the time data and wavelet indicate that the frequency content that the wavelet represents is present.
What actually happens?
Wavelets of different scales and shifts are convolved with the original signal to determine if the original signal has similar frequency content.
Essentially, wavelets can be thought of as a discrete-time filter-bank of band-pass filters.
Comparison of FFT vs Wavelet:
By nature of the processing type, the traditional FFT has a fixed relationship between time and frequency.
Conversely, the wavelet does not have a fixed relationship between time and frequency.
As shown in Figure 7, wavelets have different behavior at different frequencies:
The change in the frequency resolution is due to the fact that the frequency scale for the wavelet processing is based on octaves.
Figure 8 (below) shows the wavelet result of a transient event. Look at the right side of Figure 7 to better understand how data is smeared in a wavelet map as shown in Figure 8.
An impulse in the time domain is represented by broadband frequency response in the frequency domain. Most transient events are "impulsive" in nature and therefore have a rather broadband signature in the frequency domain. Therefore, a fine frequency resolution at high frequencies is typically not necessary. However, the improved time resolution the wavelet has to offer can be hugely beneficial when analyzing transients.
Output Comparison – Fourier Transform vs. Wavelet:
Let’s take a closer look at the results to better understand the differences between FFT and wavelet analysis.
The colormap results for both the FFT and wavelet transformations are created by stacking a series of tracked results together.
In the case of the FFT, for each time increment an ‘amplitude vs frequency’ result is created. These results are stacked together to create the colormap.
In Figure 9 (below), each individual calculation of ‘amplitude vs frequency’ in the ‘waterfall’ map display (left) is shown. These individual calculations are smoothed together to create the ‘colormap’ display on the right.
Alternatively, the wavelet analysis will create an ‘amplitude vs time’ result for each frequency increment (as specified by the wavelets per octave setting). These individual calculations (as seen in the waterfall display, left) are smoothed together to create the ‘colormap’ display on the right.
Understanding the results helps to better understand the calculations that are being performed by Simcenter Testlab.
Performing Wavelet Analysis in Simcenter Testlab
To access the wavelet analysis functions, go to Tools -> Add-ins -> Time-Variant Frequency Analysis. This add-in requires 34 tokens.
To begin, create a data set in the “Time Data Selection” workbook. It is possible to import a data trace and only use a small segment for processing. Select the segment by clicking and dragging in the middle pane (it will become highlighted in black). Then select the “Use Segment for Processing” button (shown with a red box in Figure 12, below).
From here, there are two locations to do a wavelet calculation:
It is recommended to use the Time Frequency Analysis tab to play with the settings for the wavelet. The layout of the workbook allows for easy adjustment and analysis of the wavelet settings.
If batch processing is desired, it is recommended to use the Time Data Processing workbook. Determine the settings in the Time Frequency Analysis workbook and then easily batch process in the Time Data Processing workbook.
1. Time Frequency Analysis
Once the data set is created, go to the “Time Frequency Analysis” workbook (Figure 13, below).
The result is a colormap of frequency vs time.
Use the following guidelines to determine wavelet processing settings:
The wavelet result can be saved to the project by using the “Save…” button in the lower left corner of the screen.
2. Time Data Processing
Alternatively, it is possible to perform a wavelet analysis in “Time Data Processing”. Turn on the “Signature Throughput Processing” add in from the add-in list. This requires 36 tokens.
The “Time-Variant Frequency Analysis” add-in must also be turned on.
To calculate a wavelet:
By default, automatic wavelet parameters will be entered. To adjust these parameters, change the “Freq interval” drop down menu to “Manual”.
The processing settings are the same as those described in the above section.
Calculate and save the results to the project.
Methods to manage file sizes:
Wavelet analysis can produce a lot of high resolution data. It may be desired to reduce the file size of a wavelet analysis result – especially if doing batch processing on a large amount of data.
There are two main methods to reduce the file size: adjust the number wavelets per octave and down sample.
1. Adjust the number of wavelets per octave:
Reducing the number of wavelets per octave will reduce both file size and resolution of the resulting colormap.
Play with the settings to determine the minimum number of wavelets per octave required to obtain the desired level of resolution. In Figure 16 (below), the same data is re-processed multiple times to determine to optimal wavelets per octave setting:
The engineer selects to calculate the wavelet maps with 16 wavelets per octave: a good balance between resolution and file size.
2. Down sample:
Without down sampling, the time blocks in the wavelet map will have the same x-axis resolution as the original time trace sample frequency(for example, a 50,000 data point time history analyzed with 100 wavelets creates a dataset of 50,000 x 100 data points). This can consume a lot of disk space and processing time. Applying a down sampling ratio will reduce the file size.
To access the down sampling option in “Time Frequency Analysis”, select the “Settings…” button and then choose a “down sampling ratio”.
If processing wavelet maps in “Time Data Processing”, the down sampling ratio is available in the Section Settings pop-up window.
Reducing file size is especially important when batch processing wavelet maps.
Piston slap occurs when the piston inside of a cylinder hits the cylinder wall during the operating cycle. This causes an audible transient noise.
It may be desired to know the timing of the piston slap. Traditional FFT methods do not make it obvious when the piston slap occurs. Alternatively, the wavelet analysis highlights the timing and the frequency content of the piston slap.
In Figure 20 (below), time vs pressure data from a microphone near an engine block is displayed (top). Some of the transient events are highlighted. This data is analyzed in two way: FFT (middle) and wavelet (bottom).
The wavelet has much better time resolution. The FFT is smeared both in the time domain and the frequency domain.
Wavelet analysis can be used for any type of transient: piston slap, door slams, pyro-technic shock, diesel clatter, injection tick, button clicks, etc.
The main benefit of wavelet analysis is improved time and frequency resolution.
Questions? Contact email@example.com