Next: PBS
Up: OpenMP
Previous: OpenMP
Use OpenMP to solve the following problem.
Compute
.
For the first exercise, let
, and find the time it takes to
do the computation when
.
Next determine the random number generator on the system, and let
be random numbers. Again find the time it takes to perform
the computation. Do the calculation twice. First time through, determine all
2N random numbers first and distribute them out. The second time, have
each thread generate the random numbers for themselves.
E. Bruce Pitman
Mon Nov 5 15:15:58 EST 2001