%  Version 2  
%   
%  --- THIS IS THE VERSION TO BE MIMICKED IN PARTS 2 and 3  ---
%
%  Before running this code,
%  execute the code for part 1 and do NOT clear the workspace.
% Step 1:
shift_horiz = 0.8;
shift_vert = -0.3;   % define the shift's components
shift_vector = [shift_horiz; shift_vert];  
                     % define the vector of the shift
shift_matrix = repmat(shift_vector, 1, length(x_letter));
              % see the end of the Introduction
% Step 2:
letter_matrix = [x_letter; y_letter];
              % create the matrix containing the coordinates of the letter
% Step 3:
letter_matrix_shifted = letter_matrix + shift_matrix;
              % shift the letter  
% Step 4:
x_letter_shifted = letter_matrix_shifted(1,:);
y_letter_shifted = letter_matrix_shifted(2,:);
              %  extract the 1st and 2nd rows of the shifted 
              %  letter matrix and put them into two separate row-vectors
figure(4022);
plot(x_letter,y_letter,x_letter_shifted,y_letter_shifted,'k')
axis([0 2 -0.5 1])
            % plot the original (default blue) and the shifted (black) letters 
            % inside the rectangle  [0 2] x [-0.5 1]