Parallel Computation Laboratory
|
|
Write parallel implementations of the backtracking algorithm for solving the
problem of placing N queens on a board of size N such that no queen can
beat another. Use the mechanisms of
- Unix processes, signals, and pipes (no shared memory), and
- the Message Passing Interface (MPI)
for implementing a procedure
nqueens(N, w, file)
that computes all solutions and, if w is true, writes them to
file.
Run the programs with input sizes N = 2i, 2i+1, ..., 2i+k
and w = true, false such that the corresponding program runs take
between 1 second and at least one minute and use 1, 2, 4, 6, 8, 16 processors
(as many as available).
- Use for time measurements wall clock times (return value of
times()
, see the man pages). The timings must start before
nqueen
is called and stop after nqueens
returns.
- The result of this exercise is a paper containing the
- Documented source code,
- Output for one test run of each program (just one page, truncated),
- Tables with absolute runtimes,
- Runtime diagrams,
- Speedup diagrams,
- Efficiency diagrams,
- Your analysis of the results, your experiences and conclusions.
- 1 extra point for each the fastest Unix program and for the fastest MPI
program that solves the largest problem (w=true) with not more than 8
processors in not more than one minute.
Deadline and Presentation: June 16.
Maintained by: Wolfgang Schreiner
Last Modification: May 11, 1997
[Up]
[RISC-Linz] [University]
[Search]