next up previous
Next: Appendix: Basic Ideas of Up: New Objects Previous: Data Objects

Model Objects

The object of identified models is idmodel  (see help(idmodel)). This also allows the straightforward handling of all properties, but offers much more. Based on the own functions tf(),  zpk(),  ss(),  direct transfer is possible to the Control System Toolbox,  moreover, certain functions of the Control System Toolbox can be directly called. For example, if name of the model object is mod, the commands nyquist(mod)  or bode(mod)  use the corresponding functions of the Control System Toolbox. The implementation even defines a simple arithmetic, so the commands 1/mod (inverse of the model), isstable(mod) (is the model stable?), stable(mod)  (stabilized model, by reflection of the unstable poles), and mod1==mod2 (are the two models identical?) work just as expected. For comparison, also models of the Control System Toolbox can be converted to an idmodel object by using the function idmodel. Finally, this object is prepared to accomodate also models from the System Identification Toolbox (see the full list of properties), and smooth conversions between the two main model object types are also planned. However, this still needs further development work, and will require information about the decision on models in the System Identification Toolbox.

The model object can even store the data used for identification, in the property data. Therefore, plot(idmobj) can plot not only the transfer function, but also the measured data, and the error of identification.

load bandpmod
        version = 1.2
        date = '22-Oct-1998 09:09:26'
        history = {[1x48 char]}
        data = [1x1 fiddata]
        variable = 's'
        num = [-4.0066e-18 -5.1034e-13 -9.2494e-11 2.7921e-09 1.5859e-05]
        denom = [-9.4278e-23 -2.3515e-19 -3.3573e-15 -5.1609e-12 -3.3479e-08
                 -2.3288e-05 -0.093552]
        representation = 'polynomial'
        freqvect = [16x1 double]
        fscale = 3835
        delays = 0
        covariance = [13x13 double]
        fitinfo = [18x1 double]
>> set(bkfit)
        name:  string
        version:  version number, set by the system
        date:  string (date + time)
        notes:  string
        history:  cell vector of strings
        data:  optional, input data of estimation (tiddata or fiddata)
        algorithm:  structure describing the algorithm
        userdata:  user-defined
        variable:  [ 'z^-1' | 's' | 'r' | 'w' ]
        representation:  [ 'polynomial' | 'orthopol' ]
        num:  cell array of numerators
        denom:  cell array of denominators
        ntr:  cell array of transient numerator polynomials
        Znum:  array of weight vectors of numerator
        Zdenom:  array of weight vectors of denominator
        Zntr:  array of weight vectors of transient numerator
        freqvect:  column vector or array, freqs x channels
        chnames:  string cell array, length: channels
        chtypes:  string cell array, [ 'input' | 'output' ]
        fscale:  scalar, optimum scaling frequency
        delays:  vector of delay values
        units:  cell array of strings
        covariance:  array of covariances
        fixedpar:  nx2 array of fixed parameters
        fitinfo:  cell array of information on fit

next up previous
Next: Appendix: Basic Ideas of Up: New Objects Previous: Data Objects
István Kollár