**
**

Computer Packages and Libraries

An introduction to features of packages (Matlab, Maple, AVS), and library routines, (NAG, IMSL, (Sca)LAPACK, (P) ESSL, Numerical Recipes).

(You might prefer to read this with no frames by typing training/package.html into your web browser location)

High Performance Computing

High Performance Computing (HPC) is an engineering discipline which develops the technology (hardware, algorithms, and software) to deliver cost-effective computational results.

Packages and Libraries

These tools enable:

- algorithms to be tested
- existing efficient algorithms to be exploited

Further Information (see also under each of the products)

Computing Services (look under documentation to find out how to use packages at the University)

http://www.soton.ac.uk/~sucsweb/

Netlib Repository

ftp://www.hensa.ac.uk/mirrors/netlib/

Matlab

Describes itself as "The Ultimate Computing Environment for Technical Education." Matlab is a versatile programmable calculator, with large number of built in functions.

Features

- Numerical Package, which handles data as matrices and vectors. It is easy to input data from Fortran and C.
- Superb for visualising and processing one, two- and three-dimensional data. This includes plotting, fitting and interpolating.
- Various toolboxes exist, which specialise in certain operations e.g. Signal processing.
- Easy to output graphs to Postscript for inclusion in documents.

N.B.

- The Matlab language has a poor syntax.
- May need to work to label graphs exactly as you require- (but not much harder than Gnuplot). This is a bit easier in Matlab 5.

Availability

Can buy student edition of Matlab Version 5 for £36

Information Sheet:

http://www.soton.ac.uk/~sucsweb/docs/pp/numerical/025pp.html

On university Unix and Windows/ DOS service.

Matlab:

Matlab ftp and a faster mirror (Contains useful Mathworks files + patches)

ftp://unix.hensa.ac.uk/mirrors/matlab

Future

There are various compilers for Matlab. Mathworks offer one that will compile your Matlab code into C, and generally makes it run about 5-10 times faster.

There are a number of research projects to convert Matlab into Fortran, C, or Fortran 90, and C with MPI (which would allow very large-scale computations to be performed on high performance parallel supercomputers).

Summary Sheet

These sections refer to the Faculty of Engineering and Applied Science Graduate School course "Data Handling for Research Students" booklet (2nd Edition), available from sjc95r@ecs.soton.ac.uk .

Key features

Basic Mathematics |
6.2 |

Help |
6.4 |

Array operations |
6.5 |

2D plotting and producing output |
6.7 |

3D plotting |
6.18 |

MATLAB Programming |
6.12 and 6.13 |

Advanced features

Handling Arrays |
6.6 |

Relational Operators |
6.8 |

Linear Algebra |
6.9.1 |

Text Handling |
6.11 |

Curve fitting and interpolation |
6.15.1 - 6.15.6 |

Sparse Matrices |
6.17.9 |

Optimisation tips |
6.17 |

Extras

Complex Numbers |
6.3 |

Linear Algebra what can go wrong |
6.9.2 - 6.9.5 |

Special Matrices |
6.10 |

Polynomials |
6.14 |

Numerical Analysis |
6.15.7- 6.15.10 |

Data Analysis |
6.16 |

Maple

A mathematical manipulation package.

Features

- Performs symbolic and numerical computation.
- Equations can be solved, expanded, differentiated or integrated.
- Allows easy visualisation of functions in one two and three dimensions.
- It is possible to export Maple worksheets as Latex documents.
- Very good help system- it is possible to learn to whole package using this.
- Can export (in version 4) Maple procedures to Fortran or C.

N.B.

- It can be hard to format graphs exactly as required.
- Difficult to use the package to process data files.

Availability

Product Sheet 24 available from SUCS:

http://www.soton.ac.uk/~sucsweb/docs/pp/numerical/024pp.html

It is on university Unix and Windows/ DOS service.

Maple homepage

Symbolic Computation Group, where Maple started as a research project

Excel

This is a spreadsheet package from Microsoft, and is part of the Microsoft Office suite. It might sound surprising to suggest using this in the context of high performance computing, but we require our solutions to be cost-effective.

Features

- Easy to produce simple graphs.
- Easy to load data.
- Links into Powerpoint (for presentations) and Word (for papers).
- Many built-in functions for analysing data interactively.
- Visual Basic programming language to add functions.

N.B.

- May need lots of memory to run Excel effectively
- Not very good for producing three-dimensional plots

Availability

Through various licensing agreements, students can obtain a cheap version of Office for around £100. Office Standard has Word, Excel, and Powerpoint (and some other things). Office Professional includes the Office Standard and Access (a database program).

AVS

AVS (Application Visualisation System) from Advanced Visual Systems/UNIRAS Ltd is a powerful computer graphics package for data visualisation.

AVS is an application builder that allows users to visualise their data by constructing applications from a series of software components called modules. Each

module performs a specific task e.g. importing data, processing/filtering data and rendering. Applications are constructed with a GUI (Graphical User Interface)

and the user only has to direct the path of the program and data. The number of modules is such (230+ supplied and 500 public domain) that many visualisation

applications can be constructed without programming. However, a key feature of the system is that it is extensible by the user as additional modules can be written,

in C or FORTRAN, and integrated into the system.

N.B.

- All the flexibility of AVS does make it a little difficult to load in data for the first time.

Availability

This page has links to tutorials on AVS

http://www.soton.ac.uk/~sucsweb/docs/pp/graphics/083pp.html

NAG Libraries

The NAG Fortran library is a set of mathematical, graphical and statistical routines made available by the Numerical Algorithms Group Limited at Oxford. The Mark 17

version of the library contains over eleven hundred user-callable routines which are divided into 41 chapters.

Availability

Fortran Library information (supported by SUCS Unix service)

http://www.soton.ac.uk/~sucsweb/docs/pp/program/112pp.html

C information:

http://www.soton.ac.uk/~sucsweb/docs/pp/numerical/132pp.html

NAG Documentation:

http://www.soton.ac.uk/~sucsweb/docs/pp/program/021pp.html

NAG libraries:

http://www.soton.ac.uk/~sucsweb/unix/apps/naghelp/summaries/

IMSL Libraries

The IMSL Libraries provide numerical, statistical and graphics routines for use by Fortran and C programmers.

Availability

Information Sheet:

http://www.soton.ac.uk/~sucsweb/docs/pp/program/176pp.html

Digital Visual Fortran Professional 5.0.A

This includes the full IMSL libraries, so these are available on the HPCC Dec Alpha Cluster (codename Arthur).

Linear Algebra Routines

ScaLAPACK

This is a library of high-performance linear algebra routines for distributed memory message-passing MIMD computers and networks of workstations supporting parallel virtual machine (PVM) and/ or MPI (Message-passing interface). It is built on (P)BLAS and LAPACK.

(P)BLAS

(Parallel) __B__asic __L__inear __A__lgebra __S__ubprograms" are suite of routines for basic linear algebra. They will solve systems of linear equations, linear least squares problems, eigenvalue and eigenvector problems, singular value problems.

Availability

The code for each routine is freely available.

ScaLAPACK home page (and mirrors for Netlib files)

http://www.netlib.org/scalapack/index.html

http://www.hensa.ac.uk/ftp/mirrors/netlib/master

BLAS routines:

ftp://www.hensa.ac.uk/mirrors/netlib/blas

(index.html did not correctly download files for me, but downloading directly from the directory was fine)

Vendors will often supply an implementation of these tuned for their machine…

(P) ESSL

ESSL is an Engineering and Scientific Subroutine Library, provided by IBM providing linear algebra, matrix operations, eigensystem analysis, fast Fourier transforms, sorting and searching, interpolation and random number generation routines.

PESSL is a parallel implementation of a subset of the routines from IBM's ESSL library. It is based on the public domain ScaLAPACK library.

Availability

It is supplied by IBM on the SP2:

http://www.soton.ac.uk/~_sp2adm/software/pessl.htm

See also the SP2 web pages

http://www.soton.ac.uk/~_sp2adm/software/index.html

Numerical Recipes

This book is one of the most important references for numerical methods, and it contains full implementations of most of the important techniques you will require. When using a package, or a library, it is important to understand the algorithm you are using, and whether it is appropriate. Numerical Recipes is not just a source of code, but it is a source of good numerical practise.

Features

- Solution of Linear Systems
- Interpolation and Extrapolation
- Integration of Functions
- Evaluation of Functions
- Special Functions (e.g. Bessel functions)
- Random Numbers
- Sorting
- Root finding and Non-linear equations
- Minimization or Maximization of Functions
- Eigensystems
- Fast Fourier Transform
- Fourier and Spectral Applications
- Statistical Description of Data
- Modelling of Data
- Integration of Ordinary Differential Equations
- Two Point Boundary Value Problems
- Integral Equations and Inverse Theory
- Partial Differential Equations

Availability

Buy the book! (Cost ~£36 pounds for F77 or C, and £20 for the accompanying volume for F90)

A CD-ROM is also available, which has the code and examples along with a host of additional routines.

You can download chapters from the web for the Fortran 77 and C books from:

http://cfatab.harvard.edu/nr/nronline.html

Summary

Use a package, library, or write your own code to provide "cost-effective computational results". This requires understanding hardware, algorithms, and software, and making informed choices about how to arrive at the best solution.

Next session we will return to the algorithms which underlie these packages and libraries.

Last updated 8-Dec-97. Maintained by SJ Cox