blockBandLimitedWhiteNoise
Extends from Modelica.Blocks.Interfaces.PartialNoise (Partial noise generator).
Information
A summary of the common properties of the noise blocks is provided in the documentation of package Blocks.Noise. This BandLimitedWhiteNoise block generates reproducible, random noise at its output according to a band-limited white noise distribution. This is performed by using a normal distribution with mu=0 and sigma = sqrt(noisePower/samplePeriod).
In order for this block to produce meaningful results, you should set the following parameters:
- The samplePeriod of the block should be much faster (say by a factor of 100) than the fastest dynamics of the system fed by the block's outputs.
- The noisePower of the signal should be set to the expected power per frequency of the white noise. Since many system models assume a noise power of 1, this preset may be a reasonable first choice (= default).
About sampling frequencies
Ideal white noise contains all frequencies, including infinitely high ones. However, these usually cannot be observed in physical systems, since all physical systems in one way or the other contain low-pass filters. It is thus sufficient to generate a limited range of frequency content in the noise signal, as long as it exceeds the frequencies of the subsequent dynamics by a sufficiently high factor (of e.g. 100).
About noise power
Ideal white noise has a flat, i.e. constant, power spectral density for all frequencies. It has thus infinitely high power, because the total power of a signal can be obtained by integrating the power spectral density over all frequencies. The following three ways to think of the power of a signal may be helpful:
- The energy of a signal is the integral of its squared absolute value over time. The signal's power is this integral divided by the time span of the integral.
- The total power of a signal can also be obtained by integrating its (two-sided) power spectral density over all frequencies.
- The total power of a signal is finally also equal to its variance.
In order to set the correct level of the band-limited white noise power spectral density,
the variance of its normal distribution can thus be influenced directly.
Recalling that the samplePeriod of the noise signal generates frequency content in the
range ±0.5/samplePeriod, the variance must be increased to generate sufficient
total signal power. The total power must match the product of the noisePower and its
frequency bandwidth 1/samplePeriod: signal power = signal variance = noisePower / samplePeriod.
Example Examples.Noise.DrydenContinuousTurbulence demonstrates how to utilize this block to model wind gust.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| SI.Period | samplePeriod (from PartialNoise) | Period for sampling the raw random numbers | |
| Integer | localSeed (from PartialNoise) | The actual localSeed | |
| Real | noisePower | 1 | Power of white noise signal |
| Advanced › Noise generation | |||
| Boolean | enableNoise (from PartialNoise) | globalSeed.enableNoise | = true: y = noise, otherwise y = y_off |
| Real | y_off (from PartialNoise) | 0.0 | Sets y = y_off if enableNoise=false (or time<startTime, see below) |
| Advanced › Initialization | |||
| Boolean | useGlobalSeed (from PartialNoise) | true | = true: use global seed, otherwise ignore it |
| Boolean | useAutomaticLocalSeed (from PartialNoise) | true | = true: use automatic local seed, otherwise use fixedLocalSeed |
| Integer | fixedLocalSeed (from PartialNoise) | 1 | Local seed (any Integer number) |
| SI.Time | startTime (from PartialNoise) | 0.0 | Start time for sampling the raw random numbers |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| RealOutput | y (from SO) | Connector of Real output signal |