How to broadcast a variable in spmd mode

3 vues (au cours des 30 derniers jours)
Wenyu Li
Wenyu Li le 10 Avr 2017
The question I'm trying to solve is to broadcast a scalar variable x inside a spmd mode into an array of size numlab that can be seen by all the parallel workers. I know that in MPI this is called a broadcast operation but I can't find similar operations in MATLAB.

Réponses (1)

Edric Ellis
Edric Ellis le 11 Avr 2017
The broadcast function to use inside an spmd block is labBroadcast.

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by