main content

perform rational fitting to complex frequency-凯发k8网页登录

perform rational fitting to complex frequency-dependent data

description

use the rational object and an interpolative algorithm to create a rational fit to frequency-dependent data.

the complex frequencies are given by the equation:

f(s) = residues(1)s-poles(1) residues(2)s-poles(2) ... residues(n)s-poles(n) directtermwhere, s=j2πfreq

creation

description

fit = rational(freq,data) returns a rational object with complex frequencies using the given frequency vector and network parameter data.

example

fit = rational(s) returns a rational object for n-port s-parameters.

fit = rational(___,tol) returns a rational object fit that satisfies a relative error tolerance.

[fit,error] = rational(___) also returns the error of the fit.

fit = rational(...,name,value) sets properties using one or more name-value pairs. for example, fit = rational(s,'tolerance',-34)sets the relative error tolerance in decibels for the fit.

input arguments

nonnegative frequencies, specified as a vector of nonnegative frequencies in hz.

data types: double

network parameter data, specified as a vector, a 2-d array or a 3-d array. the length of the data values must equal the length of the frequency values.

relative error tolerance, specified as a scalar less than or equal to zero. tol value sets the input for the 'tolerance' property.

data types: double

n-port s-parameters, specified as an n-by-n matrix of elements of s sharing identical poles.

properties

relative error tolerance, specified as a scalar less than or equal to zero.

data types: double

behavior of fit for large s-parameters, specified as true or false. when true, the direct term in the fit is set to zero so that the rational fit f(s) tends to zero as s approaches infinity. when false, a nonzero direct term is allowed.

data types: logical

maximum number of poles, specified as a scalar nonnegative integer.

data types: double

display options for the fitting algorithm of the rational object, specified as one of the following:

  • 'off' - no display

  • 'on' - printed information

  • 'plot' - plots of the interpolation progress

  • 'both' - -both printed information and plots.

data types: char

object functions

time response for rational object and rationalfit function object
step-signal response of rational object and rationalfit function object
frequency response of rational object and rationalfit function object
impulse response for rational function object
return true if rationalfit output is passive at all frequencies
enforce passivity of rationalfit output or a rational object
plot passivity of n-by-n rationalfit function output
generate spice file from rationalfit of s-parameters

examples

create s-parameters from the file named passive.s2p.

s = sparameters('passive.s2p');

perform rational fitting of the s-parameters.

fit = rational(s);

create an s-parameters object from the file named default.s2p. perform rational fitting of the s-parameters.

s = sparameters('default.s2p');
fit = rational(s,'display', 'plot')

fit = 
  rational with properties:
      numports: 2
      numpoles: 14
         poles: [14x1 double]
      residues: [2x2x14 double]
    directterm: [2x2 double]
         errdb: -21.0060

calculate the zeros, poles, gain, and dc gain of the rational object.

[z,p,k,dcgain] = zpk(fit)
z=2×2 cell array
    {13x1 double}    {13x1 double}
    {13x1 double}    {13x1 double}
p=2×2 cell array
    {14x1 double}    {14x1 double}
    {14x1 double}    {14x1 double}
k = 2×2
1010 ×
    4.2525    0.0285
    2.6654   -0.1416
dcgain = 2×2
   -0.0336   -0.0060
   -0.6717    0.4098

see also

introduced in r2020a

试用 matlab、simulink 以及其他产品

网站地图