NAG recommends that users read the following minimum reference material before calling any library routine:
(a) Essential Introduction
(b) Chapter Introduction
(c) Routine Document
(d) Implementation-specific Users' Note
First check that you are set up to use MPICH by invoking the mpichversion and mpif77 -v commands. This should report the version of MPICH and the version of the Intel Fortran Compiler and confirm that you are not using some other implementation of MPI (such as LAM or SGI-MPT).
> mpichversion MPICH Version: 1.2.7p1 > mpif77 -v mpif77 for 1.2.7 (release) of : 2005/11/04 11:54:51 Version 9.1
Assuming that a link to libnagmpi.a and libnagmpi_sup.a has been placed in a directory in the search path of the linker, and the same applies for the Intel(R) Math Kernel Library (MKL), then you may link to the NAG Parallel Library as follows:
mpif77 driver.f -lnagmpi -lnagmpi_sup -lmkl_lapack -lmkl_ipf -lguidewhere driver.f is your application program. More generally, the linking command can be:
/path/to/MPICH/bin/mpif77 driver.f -L /path/to/NAGLibraries -lnagmpi \ -lnagmpi_sup -L /path/to/MKL/lib/64 -lmkl_lapack -lmkl_ipf -lguideTo link with the shared library version of MKL, one would use this form:
/path/to/MPICH/bin/mpif77 driver.f -L /path/to/NAGLibraries -lnagmpi \ -lnagmpi_sup -L /path/to/MKL/lib/64 -lmkl_lapack64 -lmkl -lguide
mpirun -np 4 a.outinstructs the system to execute the executable program a.out in four parallel processes. Consult local documentation for full details of the facilities of mpirun. If the executable uses shared libraries that are not on the linker's default path, make sure that LD_LIBRARY_PATH is set in your shell startup file to point to where the shared libraries are.
The example programs are most easily accessed by using the script nagmpiexample, which will copy an example program and its data, compile it, link it with the libraries and run it.
For example, give the command
nagmpiexample f04ebfpto run the F04EBFP example program.
The values of the machine constants are:
The basic parameters of the model
X02BHF = 2 X02BJF = 53 X02BKF = -1021 X02BLF = 1024 X02DJF = .TRUE.Derived parameters of the floating-point arithmetic
X02AJF = 1.110223024625157E-016 X02AKF = 2.225073858507201E-308 X02ALF = 1.797693134862316E+308 X02AMF = 2.225073858507201E-308 X02ANF = 2.225073858507201E-308Parameters of other aspects of the computing environment
X02AHF = 1.427247692705960E+045 X02BBF = 2147483647 X02BEF = 15 X02DAF = .FALSE.
On-line documentation is provided, in PDF form, with this implementation. Please refer to local information for access to this documentation.
The NAG Response Centres are available for general enquiries from all users and also for technical queries from sites with an annually licensed product or support service.
The Response Centres are open during office hours, but contact is possible by fax, email and phone (answering machine) at all times.
When contacting a Response Centre, it helps us deal with your enquiry quickly if you can quote your NAG site reference and NAG product code (in this case FDL6403DC).
The NAG websites provide information about implementation availability, descriptions of products, downloadable software, product documentation and technical reports. The NAG websites can be accessed at the following URLs:
http://www.nag.co.uk/, http://www.nag.com/ or http://www.nag-j.co.jp/
NAG Ltd Wilkinson House Jordan Hill Road OXFORD OX2 8DR NAG Ltd Response Centre United Kingdom email: email@example.com Tel: +44 (0)1865 511245 Tel: +44 (0)1865 311744 Fax: +44 (0)1865 310139 Fax: +44 (0)1865 310139 NAG Inc 1431 Opus Place, Suite 220 Downers Grove IL 60515-1362 NAG Inc Response Center USA email: firstname.lastname@example.org Tel: +1 630 971 2337 Tel: +1 630 971 2337 Fax: +1 630 971 2706 Fax: +1 630 971 2706 Nihon NAG KK Hatchobori Frontier Building 2F 4-9-9 Hatchobori Chuo-ku Tokyo 104-0032 Japan email: email@example.com Tel: +81 (0)3 5542 6311 Fax: +81 (0)3 5542 6312