CreateTransformations

W = Graphics;
% translate back to origin

disp('To rotate about a nonzero point, first translate back to origin');
pause
W = [W W(:,[2 4 1])];
A = T(-1,-1)*[W;ones(1,size(W,2))];
disp('W above translated back to origin');
WireFrame(A(1:2,:),'.k')
pause

% rotate
Rh = @(t) [cos(t) sin(t) 0; -sin(t) cos(t) 0; 0 0 1];
B = Rh(pi/4)*A;
pause

% translate back to initial postion
disp('W above translated back to origin, roated and translated back');
C = T( 1,1)*B;

Y = C(1:2,:)
WireFrame(Y,'.b')

