Advertisement
Guest User

Untitled

a guest
May 20th, 2019
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.36 KB | None | 0 0
  1. X = [2,3,4 ; 3,3,4 ; 4,4,4 ; 5,4,4 ; 5,4,5 ; 4,4,5 ; 3,3,5 ; 2,3,5 ; 2,3,4];
  2. Xprim = [2 0 0 0; 0 2 0 0; 0 0 2 0; 0 0 0 1];
  3. Xprim2 = [1/2 0 0 0; 0 1/2 0 0; 0 0 1/2 0; 0 0 0 1];
  4.  
  5. plot3(X(:,1), X(:,2), X(:,3));
  6. hold on
  7.  
  8. xj = [X ones(9,1)];
  9.  
  10. res = xj * Xprim;
  11. plot3(res(:,1), res(:,2), res(:,3));
  12.  
  13. res2 = xj * Xprim2;
  14. plot3(res2(:,1), res2(:,2), res2(:,3));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement