previous up next
Go up to 2 Examples
Go forward to 2.2 Distributed Factorization of Integers
RISC-Linz logo

2.1 A First Example

The screenshot below demonstrates the use of the system by a simple example:

      deneb!1> maple
          |\^/|     Maple V Release 4 (Johannes Kepler University Linz)
      ._|\|   |/|_. Copyright (c) 1981-1996 by Waterloo Maple Inc. All rights
       \  MAPLE  /  reserved. Maple and Maple V are registered trademarks of
       <____ ____>  Waterloo Maple Inc.
            |       Type ? for help.
      > read `dist.maple`;
      Distributed Maple V1.0 (c) 1998 Wolfgang Schreiner (RISC-Linz)
      See http://www.risc.uni-linz.ac.at/software/distmaple
      > dist[initialize]([[deneb,solaris], [iris,irix]]);
      connecting deneb...
      connecting iris...
                                           okay

      > t1 := dist[start](int, x^n, x);
                                          t1 := 0
       
      > t2 := dist[start](int, x^n, n);
                                          t2 := 1
       
      > dist[wait](t1) + dist[wait](t2);     
                                      (n + 1)     n
                                     x           x
                                     -------- + -----
                                      n + 1     ln(x)
       
      > dist[terminate]();
                                           okay
       
      > quit;

In this session, we first load the package dist.maple which prints a copyright message. Then we call the procedure dist[initialize] with an argument list that tells the system to start a distributed session connecting (in addition to the current Maple kernel) two Maple kernels running on machine deneb of type solaris and on machine iris of type irix, respectively. After the connection has been established and the distributed session has been initialized, two calls of dist[start] create two tasks computing int(x^n, x) and int(x^n, n) respectively. The two dist[wait] tasks let the current execution block until the corresponding task results are available and then return these results. Finally the distributed session is closed by a call of dist[terminate].


Maintainer: Wolfgang Schreiner
Last Modification: July 6, 2001

previous up next