Mu Analysis and Synthesis Toolbox
  Go to function:
    Search    Help Desk 
vinterp, vdcmate    Examples   See Also

Interpolate or decimate VARYING matrices

Syntax

Description

In the first form, vinterp produces a regularly spaced interpolated version of the input VARYING matrix. The input arguments are

stepsize
independent variable stepsize
finaliv
end value for independent variable (Optional: the default is the final independent variable in the input)
order
type of interpolation (optional, default = 0)
 0 zero-order hold
 1 linear interpolation

The end value for the independent variable may or may not be in the actual output. This is consistent with the usual MATLAB treatment of regularly spaced vectors. For example, consider

Note that the value of 6 does not appear in the vector.

In the second form, vinterp produces a VARYING matrix vout that is an interpolated version of vin. The independent variables of vout are the same as the independent variables of varymat. The input arguments are:

varymat

VARYING matrix with desired independent variables

order

type of interpolation (optional, default = 0)

 0 zero-order hold

 1 linear interpolation

vdcmate decimates the VARYING matrix vin, whose independent variable must be linearly spaced and in ascending order. If spacing has a value of n, then the output contains only the matrices corresponding to every nth independent variable of the input. If no spacing is specified, the default is 10.

Examples

siggen creates a sinewave. This is effectively sampled by vdcmate and then interpolated by vinterp. Note that the default interpolation is a zero-order hold, giving a stair-step output, yi. If a linearly interpolated output were specified, it would look identical to yd since the MATLAB plot command displays a linear interpolation.

See Also

dtrsp, sort, sortiv, tackon, trsp



[ Previous | Help Desk | Next ]