How do i plot this rect function and unit step function into matlab?

Antworten (2)

madhan ravi
madhan ravi am 2 Nov. 2018

0 Stimmen

See rectangularpulse and piecewise are sufficient enough to finish your homework.
Remark: use symbolic variables using symbolic toolbox

1 Kommentar

If you still don’t figure it out , post the code which you tried here so that it can be corrected .

Melden Sie sich an, um zu kommentieren.

Tilkesh
Tilkesh am 28 Mär. 2022

0 Stimmen

function y = rect(x, D)
% function y = rect(x, D)
if nargin == 1, D = 1;
x = abs(x);
y = double(x<D/2);
y(x == D/2) = 0.5;
end

Kategorien

Mehr zu Labels and Styling finden Sie in Hilfe-Center und File Exchange

Tags

Gefragt:

am 2 Nov. 2018

Beantwortet:

am 28 Mär. 2022

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by