воскресенье, 26 марта 2017 г.

Combine Stem and Line

x = linspace(0,2*pi,60);
a = sin(x);
b = cos(x);
stem(x,a+b);

hold on
plot(x,a)
plot(x,b)
hold off

legend('a+b','a = sin(x)','b = cos(x)')
xlabel('Time in \musecs')
ylabel('Magnitude')
title('Linear Combination of Two Functions');

Комментариев нет:

Отправить комментарий