User`s guide

gpuArray
10-13
Description
A gpuArray object represents an array stored on the GPU. You can use the array for
direct calculations, or in CUDA kernels that execute on the GPU. You can return the
array to the MATLAB workspace with the gather function.
Methods
Other overloaded methods for a gpuArray object are too numerous to list here. Most
resemble and behave the same as built-in MATLAB functions. See “Run Built-In
Functions on a GPU ”.
Among the gpuArray methods there are several for examining the characteristics of a
gpuArray object. Most behave like the MATLAB functions of the same name:
Function Description
classUnderlying Class (data type) of the elements in the array
existsOnGPU Indication if array exists on the GPU and is accessible
isreal Indication if array elements are real
length Length of vector or largest array dimension
ndims Number of dimensions in the array
size Size of array dimensions
See Also
CUDAKernel, GPUDevice