What is the output of the following code? [code]>>t=(0:17); >> p=dirac(0)==Inf; >> q=p*1; >> conv(q,t) [/code]

What is the output of the following code?
Code:
>>t=(0:17);
>> p=dirac(0)==Inf;
>> q=p*1;
>> conv(q,t)
A. An impulse response of step for a time from 0:16
B. An impulse response of unit ramp function for a time from 0:17
C. An impulse response of ramp function for a time from 0:18
D. Error in 3rd line
 
Answer: b
Explanation: The function p exists for only t=0 and q has only 1 element in it which is 1. So, truly, we’ve derived the convolution of a system which results in a ramp function whose slope is 1 and is ranging from 0 to 17 units in time since t is defined as such.
Output:
 

Tìm kiếm

Back
Top