Question: Multithreading loops

December 11 2012 vicaut 55
Maple 15
0

How is it possible to let multiple cores compute a loop faster?

For exaple:

for i = 1 to 1000 do

*computation(i)*

end do

The goal is to let a quad core cpu split the 1000 independant computations in 4 packages of 250 each to speed up the computation by the factor 4 so that core1 computes i from 1 to 250, core2 from 251 to 500 and so on, at the same time. Is this possible?

Please Wait...