FUNCTION REFERENCE

gpuArray

Array on the GPU; MatRust returns the input unchanged.

Array on the GPU; MatRust returns the input unchanged.

Syntax

G = gpuArray(X)

MatRust computes on the CPU, so gpuArray is the identity: the result keeps the class of X and works with every function. gather turns it back.

Example

g = gpuArray([1 2 3]); y = gather(g) * 2;   % [2 4 6]

Differences from MATLAB: Runs on the CPU in MatRust; class(G) is the class of X, not 'gpuArray'.

These are the engine’s help pages. Each page keeps its compatibility notes. File operations are unavailable in the browser.