Main Content

stepresp

Step-signal response for rational objects

Description

[outputsignal,tout] = stepresp(h,ts,n,trise) computes the time domain response of a rational function object, h, to a step signal based on the number of samples, n, sample time ts, and the rise time of the input signal trise.

example

Examples

collapse all

Calculate the step response of a rational function object from the file passive.s2p. Read passive.s2p.

S = sparameters("passive.s2p");
freq = S.Frequencies;

Get S11 and convert to a TDR transfer function.

s11 = rfparam(S,1,1);
Vin = 1;
tdrfreqdata = Vin*(s11+1)/2;

Fit to a rational object.

tdrfit = rational(freq,tdrfreqdata);

Define parameters for a step signal. Define parameters for a step signal.

Ts = 1.0e-11;
N = 10000;
Trise = 1.0e-10;

Calculate the step response for TDR and plot it.

[tdr,t1] = stepresp(tdrfit,Ts,N,Trise);
figure
plot(t1*1e9,tdr)
ylabel('TDR')
xlabel('Time (ns)')

Figure contains an axes object. The axes object with xlabel Time (ns), ylabel TDR contains an object of type line.

Input Arguments

collapse all

Rational function object, specified as a rational or a rationalfit object.

Data Types: double
Complex Number Support: Yes

Sample time of the input signal, specified as a positive scalar integer in seconds.

Data Types: double

Number of samples, specified as a positive scalar integer.

Data Types: double

Time taken for step signal to reach maximum value, specified as a positive scalar integer in seconds.

Data Types: double

Output Arguments

collapse all

Computed step response, returned as a real finite vector.

Data Types: double

Sample time of the output signal, returned as a nonnegative vector of time values with discrete step size ts corresponding to the data in outputsignal in seconds.

Data Types: double

More About

collapse all

Version History

Introduced in R2010a