qbode

qbode#

Purpose

Frequency response functions (in the xf format) for linear systems.

Syntax

xf = qbode(a,b,c,d,w)
xf = qbode(ss,w)
xf = qbode(num,den,w)
XF = qbode( ... ,'command')
     qbode( ... ,'iiplot ...') %see fe2ss for examples

Description

For state-space models described by matrices a, b, c, d, or the LTI state-space object sys (see Control System Toolbox), qbode uses an eigenvalue decomposition of a to compute, in a minimum amount of time, all the FRF xf at the frequency points w

 
    (10.65)

The result is stored in the xf format .

Frequencies can be given as

  • a numeric vector w generally in rad/s.
  • a string command, see nor2xf w. Thus @ll{10,100,5000} uses a log scale spacing of frequencies. This is normally in Hz.
  • with the po, command options detailed below, pole frequencies are added to capture the maxima.

Command options should follow the new urnPar format. Support of legacy calls is obtained when the first non blank character is not a {.

  • iiplotCurveName displays results in iiplot(see section 2.1.2)
  • po is used to save poles in ci.Stack{'IdMain'} so that they can be displayed. po2 uses the marker rather than vertical line display. po102 displays a IOMatrix navigation.
  • reset initializes the curve stack (otherwise multiple calls are superposed).
  • straval can be used to specify the computation strategy : 0 legacy, 1 by pole, 2 all poles at once (consumes more memory but is notably faster)
  • otval can be used to specify the output type double, struct or frd.
  • safeN is used if you suspect a system that is not diagonalizable where qbode will fail. A rational evolution of non diagonalizable blocks is then estimated from exact computation at N frequencies. This is in particular acceptable for rigid body modes. Specifying a N larger than 3 will allow safety checks and result in an error in presence of inconsistent results. In other cases, you should then use the direct routines res2xf, nor2xf, etc. or the bode function of the Control System Toolbox.
sys=demosdt('demoGartFEsys'); 
qbode(sys,'@ll{10,100,5000}','{iiplotGart,po,reset}') % Classical display
qbode(sys,'@log{1,2,500}','{iiplotGart,po2,stra2}') % Poles as dots, strategy 2
qbode(sys,'@log{1,2,500}','{iiplotGart,po102}') % IOmatrix for navigation

Legacy command options were

  • 'iiplot "Test"' displays results in iiplot(see section 2.1.2)
  • -po is used to save poles in ci.Stack{'IdMain'} so that they can be displayed. -po2 uses the marker rather than vertical line display. -po102 displays a IOMatrix navigation.
  • -reset initializes the curve stack (otherwise multiple calls are superposed).

For the polynomial models num, den , qbode computes the FRF at the frequency points w

 
    (10.66)

Warnings

  • All the SISO FRF of the system are computed simultaneously and the complex values of the FRF returned. This approach is good for speed but not always well numerically conditioned when using state space models not generated by the SDT.
  • As for all functions that do not have access to options (IDopt for identification and Up.copt for FE model update) frequencies are assumed to be given in the mathematical default (rad/s). If your frequencies w are given in Hz, use qbode(sys,w*2*pi).
  • Numerical conditioning problems may appear for systems with several poles at zero.

See also

demo_fe, res2xf, nor2xf, and bode of the Control System Toolbox