How run two algorithms with parallel ?

답변 (1개)

mizuki
mizuki 2016년 12월 4일

0 개 추천

Parallel Computing Toolbox can allow you to run two processes in parallel.
1. Write two algorithms on two separated functions/scripts - alg1.m and alg2.m
2. PARFOR makes the operations inside of the for-loop parallel:
algs = {'alg1', 'alg2'};
parfor i = 1:length(algs)
algs{i}
end

댓글 수: 1

That should look more like
algs = {@alg1, @alg2};
parfor i = 1:length(algs)
algs{i}()
end
You might need to addAttachedFiles

댓글을 달려면 로그인하십시오.

카테고리

도움말 센터File Exchange에서 Parallel Computing에 대해 자세히 알아보기

제품

질문:

2016년 12월 2일

댓글:

2016년 12월 4일

Community Treasure Hunt

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

Start Hunting!

Translated by