After you estimate the frequency response, you can analyze
the results. If the frequency response plot does not match
the expected behavior of your system, you can use the time response
and FFT plots to help you improve the results.

Because frequency response estimation requires steady-state
input and output signals, transients produce inaccurate estimation
results.

For sinestream input signals, transients sometimes interfere
with the estimation either directly or indirectly through spectral
leakage. For chirp input signals, transients interfere with estimation.

Increase the number of periods for frequencies that
do not reach steady state by changing the NumPeriods and SettlingPeriods properties.
See Modifying Input Signals for Estimation.

(Sinestream input) Not enough periods for the output to reach
steady state.

Increase the number of periods for frequencies that
do not reach steady state by changing the NumPeriods
and SettlingPeriods. See Modifying Input Signals for Estimation.

Check that filtering is enabled during estimation.
You enable filtering by setting the ApplyFilteringInFRESTIMATE option
to on. For information about how estimation uses
filtering, see the frestimate reference
page.

(Chirp input) Signal sweeps through the frequency range too
quickly.

After you try the suggested actions, recompute the estimation
either:

At all frequencies

In a particular frequency range (only for sinestream
input signals)

To recompute the estimation in a particular frequency
range:

Determine the frequencies for which you want to recompute
the estimation results. Then, extract a portion of the sinestream
input signal at these frequencies using fselect.

For example, these commands extract a sinestream input signal
between 10 and 20 rad/s from the input signal input:

When the FFT plot shows large amplitudes at frequencies other
than the input signal, your model is operating outside the linear
range. This condition can causes problems when you want to analyze
your linear system response to small perturbations.

For models operating in the linear range, the input amplitude A_{1} in y(t) must
be larger than the amplitudes of other harmonics, A_{2} and A_{3}.

Adjust the amplitude of your input signal to decrease the impact
of other harmonics, and repeat the estimation. Typically, you should
decrease the input amplitude level to keep the model operating in
the linear range.

For more information about modifying signal amplitudes, see
one of the following:

When the time response grows without bound, frequency response
estimation results are inaccurate. Frequency response estimation is
only accurate close to the operating point.

If the model captures a growing transient, increase the
number of periods in the input signal by changing NumPeriods.
Repeat the estimation using a steady-state operating point.

Discontinuities or noise in the time response indicate that
the amplitude of your input signal is too small to overcome the effects
of the discontinuous blocks in your model. Examples of discontinuous
blocks include Quantizer, Backlash,
and Dead Zones.

If you used a sinestream input signal and estimated with filtering,
turn filtering off in the Simulation Results Viewer to see the unfiltered
time response.

The following model with a Quantizer block shows
an example of the impact of an input signal that is too small. When
you estimate this model, the unfiltered simulation output includes
discontinuities.

frestimate does not
support estimating frequency response estimation of Simulink^{®} models
with blocks that model noise. Locate such blocks with frest.findSources and disable them
using the BlocksToHoldConstant option of frestimate.

If you need to estimate a model with noise, use frestimate to simulate an output signal
from your Simulink model for estimation—without modifying
your model. Then, use the Signal Processing Toolbox™ or System Identification Toolbox™ software
to estimate a model.

To simulate the output of your model in response to a specified
input signal:

Create a random input signal.
For example:

in = frest.Random('Ts',0.001,'NumSamples',1e4);

You can also specify your own custom signal
as a timeseries object.
For example:

t = 0:0.001:10;
y = sin(2*pi*t);
in_ts = timeseries(y,t);

Simulate the model to obtain the
output signal. For example:

[sysest,simout] = frestimate(model,op,io,in_ts)

The second output argument of frestimate, simout,
is a Simulink.Timeseries object that stores the simulated
output. in_ts is the corresponding input data.

Generate timeseries objects
before using with other MathWorks^{®} products: