Anda di halaman 1dari 4

Frequency Response Plots :: Model Analysis (System Identification To...

http://www.mathworks.com/help/toolbox/ident/ug/bq1sjno.html

Frequency Response Plots


On this page What Is Frequency Response? How Frequency Response Helps to Validate Models What Does a Frequency-Response Plot Show? How to Plot Bode Plots Using the GUI How to Plot Bode and Nyquist Plots at the Command Line

What Is Frequency Response?


Frequency response plots show the complex values of a transfer function as a function of frequency. In the case of linear dynamic systems, the transfer function G is essentially an operator that takes the input u of a linear system to the output y:

For a continuous-time system, the transfer function relates the Laplace transforms of the input U(s) and output Y(s):

In this case, the frequency function G(iw) is the transfer function evaluated on the imaginary axis s=iw. For a discrete-time system sampled with a time interval T, the transfer function relates the Z-transforms of the input U(z) and output Y(z):

In this case, the frequency function G(eiwT) is the transfer function G(z) evaluated on the unit circle. The argument of the frequency function G(eiwT) is scaled by the sampling interval T to make the frequency function periodic with the sampling frequency .

How Frequency Response Helps to Validate Models


You can plot the frequency response of a model to gain insight into the characteristics of linear model dynamics, including the frequency of the peak response and stability margins. Frequency-response plots are available for all linear parametric models and spectral analysis (nonparametric) models. Note Frequency-response plots are not available for nonlinear models. In addition, Nyquist plots do not support time-series models that have no input. The frequency response of a linear dynamic model describes how the model reacts to sinusoidal inputs. If the input u(t) is a sinusoid of a certain frequency, then the output y(t) is also a sinusoid of the same frequency. However, the magnitude of the response is different from the magnitude of the input signal, and the phase of the response is shifted relative to the input signal. Frequency response plots provide insight into linear systems dynamics, such as frequency-dependent gains, resonances, and phase shifts. Frequency response plots also contain information about controller requirements and achievable bandwidths. Finally, frequency response plots can also help you validate how well a linear parametric model, such as a linear ARX model or a state-space model, captures the dynamics. One example of how frequency-response plots help validate other models is that you can estimate a frequency response from the data using spectral analysis (nonparametric model), and then plot the spectral analysis result on top of the frequency response of the parametric models. Because nonparametric and parametric models are derived using different algorithms, agreement between these models increases confidence in the parametric model results.

What Does a Frequency-Response Plot Show?


System Identification Tool GUI supports the following types of frequency-response plots for linear parametric models, linear state-space models, and nonparametric frequency-response models: Bode plot of the model response. A Bode plot consists of two plots. The top plot shows the magnitude by which

the transfer function G magnifies the amplitude of the sinusoidal input. The bottom plot shows the phase by which the transfer function shifts the input. The input to the system is a sinusoid, and the output is also a sinusoid with the same frequency. Bode plot of the disturbance model, called noise spectrum. This plot is the same as a Bode plot of the model

1 of 4

01-11-2010 22:08

Frequency Response Plots :: Model Analysis (System Identification To...

http://www.mathworks.com/help/toolbox/ident/ug/bq1sjno.html

response, but it shows the frequency response of the noise model instead. For more information, see Noise Spectrum Plots. (Only in the MATLAB Command Window) Nyquist plot. Plots the imaginary versus the real part of the transfer function. The following figure shows a sample Bode plot of the model dynamics, created in the System Identification Tool GUI.

How to Plot Bode Plots Using the GUI


To create a frequency-response plot for parametric linear models in the System Identification Tool GUI, select the Frequency resp check box in the Model Views area. For general information about creating and working with plots, see Working with Plots in the System Identification Tool GUI. To include or exclude a model on the plot, click the corresponding model icon in the System Identification Tool GUI. Active models display a thick line inside the Model Board icon. In addition to the frequency-response curve, you can display a confidence interval on the plot. The confidence interval corresponds to the range of response values with a specific probability of being the actual response of the system. The toolbox uses the estimated uncertainty in the model parameters to calculate confidence intervals and assumes the estimates have a Gaussian distribution. For example, for a 95% confidence interval, the region around the nominal curve represents the range of values that have a 95% probability of being the true system response. You can specify the confidence interval as a probability (between 0 and 1) or as the number of standard deviations of a Gaussian distribution. For example, a probability of 0.99 (99%) corresponds to 2.58 standard deviations. The following table summarizes the Frequency Function plot settings. Frequency Function Plot Settings Action Display the confidence interval. Command To display the dashed lines on either side of the nominal model curve, select Options > Show confidence intervals. Select this option again to hide the confidence intervals. To change the confidence value, select Options > Set % confidence level, and choose a value from the list. To enter your own confidence level, select Options > Set confidence level > Other. Enter the value as a probability (between 0 and 1) or as the number of standard deviations of a Gaussian distribution. Change the frequency values for computing the noise spectrum. Select Options > Frequency range and specify a new frequency vector in units of rad/s.

The default frequency vector is 128 linearly Enter the frequency vector using any one of following methods: distributed values, greater than zero and MATLAB expression, such as [1:100]*pi/100 or less than or equal to the Nyquist frequency.

2 of 4

01-11-2010 22:08

Frequency Response Plots :: Model Analysis (System Identification To...

http://www.mathworks.com/help/toolbox/ident/ug/bq1sjno.html

Action

Command

logspace(-3,-1,200). Cannot contain variables in the MATLAB


workspace. Row vector of values, such as [1:.1:100] Note To restore the default frequency vector, enter [].

Change frequency units between hertz and radians per second. Change frequency scale between linear and logarithmic. Change amplitude scale between linear and logarithmic. (Multiple-output system only) Select an input-output pair to view the noise spectrum corresponding to those channels. Note You cannot view cross spectra between different outputs.

Select Style > Frequency (Hz) or Style > Frequency (rad/s). Select Style > Linear frequency scale or Style > Log frequency scale. Select Style > Linear amplitude scale or Style > Log amplitude scale. Select the output by name in the Channel menu.

How to Plot Bode and Nyquist Plots at the Command Line


You can plot Bode and Nyquist plots for linear models using the bode, ffplot, and nyquist commands. All plot commands have the same basic syntax, as follows: To plot one model, use the syntax command(model). To plot several models, use the syntax command(model1,model2,...,modelN). In this case, command represents any of the plotting commands. To display confidence intervals for a specified number of standard deviations, use the following syntax:

command(model,'sd',sd)
where sd is the number of standard deviations of a Gaussian distribution. For example, a confidence value of 99% for the nominal model curve corresponds to 2.58 standard deviations. To display a filled confidence region, use the following syntax:

command(model,'sd',sd,'fill')
The following table summarizes commands that generate Bode and Nyquist plots for linear models. For detailed information about each command and how to specify the frequency values for computing the response, see the corresponding reference page.

Command

Description Plots the magnitude and phase of the frequency response on a logarithmic frequency scale. Plots the magnitude and phase of the frequency response on a linear frequency scale (hertz). Plots the imaginary versus real part of the transfer function. Note Does not support time-series models.

Example To create the bode plot of the model mod, use the following command:

bode

bode(mod)
To create the bode plot of the model mod, use the following command:

ffplot

ffplot(mod)
To plot the frequency response of the model mod, use the following command:

nyquist

nyquist(mod)

3 of 4

01-11-2010 22:08

Frequency Response Plots :: Model Analysis (System Identification To...

http://www.mathworks.com/help/toolbox/ident/ug/bq1sjno.html

Free Control Systems Interactive Kit


Learn more about resources for designing, testing, and implementing control systems. Get free kit

Trials Available
Try the latest control systems products. Get trial software

1984-2010- The MathWorks, Inc.

Site Help - Patents Piracy - RSS

Trademarks

Privacy Policy

Preventing

4 of 4

01-11-2010 22:08

Anda mungkin juga menyukai