Bug Plotting Heaviside Step Function
22 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I'd expect this:
fplot(@(t) (heaviside(t) - heaviside(t-1)), [-5 5]);
to show 1 between [0,1) and 0 elsewhere. Instead, I get a flat line of all zero. If I change the plot range:
fplot(@(t) (heaviside(t) - heaviside(t-1)), [-2 2]);
that creates the plot that I'd expect over that range.
Further exploration shows that this works:
fplot(@(t) (heaviside(t) - heaviside(t-1)), [-3 3.25]);
but this one does not:
fplot(@(t) (heaviside(t) - heaviside(t-1)), [-3 3.3]);
This looks like a bug in Matlab. Any ideas?
0 Kommentare
Antworten (0)
Siehe auch
Kategorien
Mehr zu Multirate Signal Processing finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!