% plot_angular_velocity.m

clear; close all;

M=dlmread('free_rotating_block.mov');

wx=M(:,11); wy=M(:,12); wz=M(:,13);

t=1.e-2*[0:length(wx)-1]';

plot(t,wx,t,wy,t,wz,'LineWidth',2);
grid on;
xlim([0,5]);
ylim([-4,6]);
set(gca,'FontSize',14);
xlabel('Time (s)','FontSize',14);
ylabel('Angular Velocity (rad/s)','FontSize',14);
title('Free rotating block simulation','FontSize',14)
legend('\omega{x}','\omega{y}','\omega{z}',3);