% The X, Y axes of the image must correspond to those of the world, 
% the first component of the vector of coordinates must be columns (j) and the second rows (i).
function J=myImwarp(I, t)
    
    [m,n] = size(I);
    
    J = zeros([m,n]);
    for i = 1:m % Rows: Y axis
        for j = 1:n % Cols: X axis
            aux=fix(t\[j;i;1]); % vector of coordinates [X;Y;1]
            u=aux(2); % Y component
            v=aux(1); % X component
            if 0<u && u<=m && 0<v && v<=n
                J(i,j) = I(u,v);
            end  
        end
    end
       

end 