figure(1)

subplot(2,1,1);
plot(time,speed1,'green','LineWidth',2);


axis ([0  2  0  2700]);
grid on;
hold on;

subplot(2,1,2);
plot(time,te1,'red','LineWidth',2);

axis ([0  2  0 1]);
grid on;
hold on;