Advertisement
Guest User

script prova gpuArray

a guest
May 25th, 2019
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.26 KB | None | 0 0
  1. X = [-15:15 0 -15:15 0 -15:15];
  2. gpuX = gpuArray(X);
  3. gpuE = expm(diag(gpuX,-1)) * expm(diag(gpuX,1));
  4. gpuM = mod(abs(gpuE),2);
  5. gpuF = gpuM + fliplr(gpuM);
  6. imagesc(gpuF);
  7. colormap(flip(gray));
  8.  
  9. Link: https://it.mathworks.com/help/parallel-computing/gpuarray.html
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement