Products & Services Solutions Academia Support User Community Company

Learn more about Parallel Computing Toolbox   

distributed - Create distributed array from data in client workspace

Syntax

D = distributed(X)

Description

D = distributed(X) creates a distributed array from X. X is an array stored on the MATLAB client, and D is a distributed array stored in parts on the workers of the open MATLAB pool.

Constructing a distributed array from local data this way is appropriate only if the MATLAB client can store the entirety of X in its memory. To construct large distributed arrays, use one of the static constructor methods such as distributed.ones, distributed.zeros, etc.

Examples

Create a small array and distribute it:

Nsmall = 50;
D1 = distributed(magic(Nsmall));

Create a large distributed array using a static build method:

Nlarge = 1000;
D2 = distributed.rand(Nlarge);
  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS