NAG Fortran Library, Mark 21

FLDLL214ZL License Managed

Windows NT/2000/XP DLL, Intel Visual Fortran

Installer's Note


1. Introduction

This Installer's Note is essential reading for whoever is responsible for the installation of this implementation of the NAG Fortran Library. It is available together with the Users' Note (un.html) on the distribution medium.

Your attention is drawn to the terms and conditions of the Software License Agreement (in file lic_agr.txt, see Section 3.1) regarding the use of NAG software. Any request to use this software other than on the licensed computer must be referred to NAG, as should requests for information about the availability of other implementations.

2. Implementation Provided

2.1. Applicability

This implementation is a compiled, tested, ready-to-use version of the NAG Fortran Library that is considered suitable for operation on the computer systems detailed below:

hardware:         32-bit Intel systems and compatible
operating system: Windows NT/2000/XP
Fortran compiler: Intel(R) Fortran Compiler for 32-bit applications, Version 8.1
                  and compatible

2.2. Derivation

This implementation was produced at NAG Ltd., Oxford on the computing system detailed below:

hardware:         Intel Pentium 4, 2.79 GHz, 504 MB RAM
operating system: MS Windows XP Professional, Ver. 2002, Service Pack 2
                  MS Visual Studio .NET 2003
Fortran compiler: Intel(R) Fortran Compiler for 32-bit applications, Version 8.1
                  Build 20051008Z
                  Package ID: w_fc_pc_8.1.036

The entire NAG Fortran Library, Mark 21, was compiled with full optimization (/O3),

This library has been tested using the Basic Linear Algebra Subprograms (BLAS) and linear algebra routines (LAPACK) provided by NAG (see the Chapter Introductions for F06, F07 and F08 in the NAG Mark 21 Library Manual, which we will refer to as the Library Manual).

The library has been also tested with version 8.0 of the Intel Math Kernel Library for Windows (MKL). The MKL version 8.0 for Windows libraries are being supplied as a part of this product (see contents).

3. Distribution Medium

The software is ordinarily distributed on CD-ROM; it can also be downloaded from any of the NAG Web sites (see NAG Websites).

3.1. Contents

The following shows the folder and file organization of the implementation materials as they will be installed.
                    |- in.html  (Installer's Note, (this document))
            |- doc -|- un.html  (Users' Note)
            |       |- lic_agr.txt
            |       |- FLDLL214Z_nag.dll  (self-contained DLL
            |       |                      including NAG BLAS/LAPACK)
	    |- bin -|- FLDLL214Z_mkl.dll  (DLL requiring
            |       |                      MKL BLAS/LAPACK)
	    |       |- *.dll              (other runtime DLLs)
            |       |- FLDLL214Z_nag.lib  (import library for
            |- lib -|                      FLDLL214Z_nag.dll)
            |       |- FLDLL214Z_mkl.lib  (import library for
            |                              FLDLL214Z_mkl.dll)
fldll214zl -|
            |- nag_interface_blocks -|- *
            |            |- source --|- ??????e.f
            |- examples -|- data ----|- ??????e.d
            |            |- results -|- ??????e.r
            |           |- absoft_fortran_examples -|- *.*
            |           |- c_examples -|- *.*
            |           |- cpp_examples -|- *.*
            |- samples -|- delphi_examples -|- *.*
            |           |- excel_examples -|- *.*
            |           |- vb6_examples -|- *.*
            |           |- vb.net2003_examples -|- *.*
            |         |- nag_example.bat
            |- batch -|- nag_example_mkl.bat
            |         |- envvars.bat
            |           |- nagmk21.h     (C header file)
            |- headers -|- nagmk21.hxx   (C++ header file)
            |           |- techdoc.html  (C/C++ headers documentation)
            |- vb_headers -|- vb6.txt      (Declare info for VB6/VBA)
            |              |- vbdnet.txt   (Declare info for VB.NET)
            |- MKL_ia32_8.0 -|- bin -|- *.dll
            |                |- lib -|- *.lib
            |- diagnostics -|- NAG_Fortran_DLL_info.exe
            |- HTMLHelp -|- nagdoc_fl21.chm  (Manual in HTMLHelp format)
            |           |- bin -|- * (directories of binaries
            |           |             for supported platforms)
            |- license -|- README.TXT
                        |- doc -|- * (End User Guide)
FLDLL214Z_nag.dll is a dynamic link library that includes NAG BLAS/LAPACK. FLDLL214Z_mkl.dll does not contain the NAG version of Basic Linear Algebra Subprograms (BLAS) nor the linear algebra functions (LAPACK). It has been tested with the BLAS/LAPACK provided by the MKL version 8.0 for Windows which is included in this product. Please see the Intel web site for further information about MKL (

By default, fldll214zl is installed beneath the folder C:\Program Files\NAG\FL21\.

The following shows the folder and file organization of the Library documentation materials as they will be installed. By default, manual is installed beneath the folder C:\Program Files\NAG\FL21\.

manual -|- examples -|- baseresults -|- ??????*.r
        |            |- source      -|- ??????*.f
        |            |- data        -|- ??????*.d
        |- html -|- mark21.html                (main HTML index)
        |        |
        |        |- [A00-X05] -|- *conts.html  (chapter contents)
        |        |
        |        |- frontmatter -|- *.html     (foreword & copyright)
        |        |
        |        |- genint -|- *.html  (general introductory material
        |        |                      and online help document)
        |        |
        |        |- indexes -|- gams -|- fl_gams.html  (GAMS index)
        |        |           |        |- *.html        (GAMS files)
        |        |           |
        |        |           |- kwic -|- fl_kwic.html  (KWIC index)
        |        |                    |- *.html        (KWIC files)
        |        |
        |        |- styles -|- libdoc.css      (main CSS stylesheet)
        |- pdf -|- frontmatter -|- mark21.pdf  (NAG copyright and main
                |               |               pdf page)
                |               |- foreword.pdf
                |- [A00-X05] -|- *conts.pdf    (chapter contents)
                |             |- *intro.pdf    (chapter introduction)
                |             |- *f.pdf        (routine documents)
                |- genint -|- *.pdf  (general introductory material
                |                     and online help document)
                |- indexes -|- *.pdf (bookmarked file containing links
                |                     to fl_kwic.html and fl_gams.html)
                |- INUNs -|- *.pdf   (implementation specific note)

3.2. File Sizes

The files sizes are given below. The actual disk space used is dependent on the hard disk allocation unit (cluster) size (this information is supplied by the DOS command CHKDSK):
dynamic link libraries:
  FLDLL214Z_nag.dll     13.0 Mb
  FLDLL214Z_mkl.dll     13.1 Mb

other runtime libraries:                 2.9 Mb
import libraries:                        2.1 Mb
interface blocks:                        3.7 Mb
example program material:               14.5 Mb
samples:                                 0.7 Mb
batch files:                            12.0 Kb
C and C++ headers:                       1.2 Mb
VB headers                               1.6 Mb
implementation specific documentation: 112.0 Kb
diagnostic material:                    40.0 Kb
HTMLHelp                                11.1 Mb
Library Manual:                        226.1 Mb

MKL for ia32 (version 8.0)
                (lib and bin folders):  71.3 Mb

licensing materials                      2.7 Mb

4. Installation

4.1. Installation of Library Software and Manual

4.1.1. Library Installation

You must have Administrator privileges to install this software.

If you have the Library materials on CD, insert the CD into your CD drive to display the NAG CD browser. Click on the Install ... button and follow the instructions to install the Library and/or the manual. If the CD does not autorun, run

  e:\Demo32 Fortran_Library_Browser.dbd
to run the browser, or run e:\setup.exe to run the Library installation directly, where e is the drive letter for your CD drive.

If you have downloaded the Library materials from our website, run the self-extracting executable to start the Library installation. The Library Manual materials are available as a separate download.

After installation, you should ensure that the software described in Section 3.1 is present and accessible.

If your machine has more than one processor, then it is recommended that you set the environment variable OMP_NUM_THREADS to the number of available processors, e.g.

This will enable the Intel MKL BLAS to make use of the extra processor(s) and will thus speed up the computation of many of the Library procedures.

The installation procedure will create a shortcut which starts a Command Prompt with the required local environment variables. The default location of this shortcut is in the Start Menu under

  Start|All Programs|NAG|FL21|NAG Fortran Library DLLs. Command Prompt

The local environment variable NAG_FLDLL214ZL is needed by the batch files nag_example.bat and nag_example_mkl.bat (see Section 4.3 of the Users' Note (un.html)).

The interface block files are supplied in both source form and pre-compiled module form. The location of the interface block files is added to the local INCLUDE environment variable by running the batch file envvars.bat. It may also have been set globally as part of the installation procedure. This is needed so that the compiler can access the modules at the compilation stage.

The installation procedure also creates a shortcut on the Start Menu to the Users' Note, which by default is located under

  Start|All Programs|NAG|FL21|NAG Fortran Library DLLs. Users' Note

There is also a shortcut to the diagnostic program NAG_Fortran_DLL_info.exe under

  Start|All Programs|NAG|FL21|NAG Fortran Library DLLs. Check Accessibility
(see Section 4.3.3).

In addition, if the VB declare statements are installed, shortcuts are provided giving easy access to the declaration files. By default these are located under

  Start|All Programs|NAG|FL21|NAG Fortran Library DLLs.
      VB6 Declare Statements
  Start|All Programs|NAG|FL21|NAG Fortran Library DLLs.
      VB.NET Declare Statements

Likewise, if the C and C++ header files are installed, a shortcut to a file which gives information on calling the the DLLs from C and C++ and includes links to the header files is provided. By default this is located under

  Start|All Programs|NAG|FL21|NAG Fortran Library DLLs.
      C & C++ Header Files Information

This software is provided with an uninstallation facility via

  Control Panel|Add or Remove Programs

Alternatively you could run the setup program again and select the Remove option.

4.1.2. Library Manual Installation

It is not necessary to install the Library Manual. Users may access it directly on the distribution CD, or it may be installed on a different workstation or server, or viewed from the NAG website (

If you have the Library materials on CD, insert the CD into your CD drive to display the NAG CD browser. Click on the Install ... button and follow the instructions to install the Library and/or the manual. If the CD does not autorun, run

  e:\Demo32 Fortran_Library_Browser.dbd
to run the browser, or run e:\setup_manual.exe to run the Library manual installation directly, where e is the drive letter for your CD drive.

If you have downloaded the Library Manual materials from our website, run the self-extracting executable to start the Library Manual installation.

The installation will create a shortcut to the main index file for the manual. The default location of this shortcut is in the Start Menu under

  Start|All Programs|NAG|FL21|NAG Fortran Library Manual

Free copies of Adobe Acrobat Reader can be downloaded from Please check this site for availability of a reader for your platform.

Please note that if you are using Adobe Acrobat 4.0 or earlier you might experience some problems when printing documents that contain mathematical characters, such as integral signs, square roots and large brackets. These characters will print correctly using Adobe Acrobat 5.0.

The HTML form of the Essential Introduction contains some mathematical characters that are displayed as question marks by releases of Netscape earlier than 6, but these are displayed correctly by Netscape 6 and Internet Explorer. They may also be viewed via the PDF.

If using Netscape, it might be necessary to re-install Acrobat to ensure that the Acrobat plug-in has been installed. If the plug-in has not been installed, Netscape may copy PDF files to a temporary folder, and then not be able to navigate from there.

4.1.3. MathPlayer Installation

The Library Manual is also available as an HTML Help file. In order to display the mathematical expressions correctly, you will need to install Design Science's MathPlayer plug-in. At the end of the main Library installation (see Section 4.1.1) there is an option to install MathPlayer. Selecting this option runs the MathPlayer 2.0b installation, which will install the MathPlayer files (approximately 2.4 Mb) under
  C:\Program Files\Design Science

MathPlayer may be removed via

  Control Panel|Add or Remove Programs
but note that clicking on the Change/Remove button for MathPlayer will remove the MathPlayer files without asking for any confirmation!

MathPlayer may also be downloaded from Design Science's web site:

4.1.4. License Management

The use of the NAG Fortran Library is controlled by the Kusari license management system. This release of the NAG Fortran Library uses version 2.1 of Kusari.

In order to enable the software, NAG will issue you with a license key. The license key is contained in a text file consisting of details of the software that will be enabled.

To request a license key, run the program khostid located in the license\bin\w32\ subdirectory of the software distribution. This utility must be run from a command prompt. Return the information that it displays, together with the product code (in this case FLDLL214Z), by e-mail (or FAX) to NAG. Alternatively, direct the output from this utility to a file and send both the file and the product code to NAG.

A short term (demonstration or trial) license key contains one or more lines like the following:

  FLDLL214Z TRIAL 2006/11/12 "EMnxidA3oeoj0F1Yvi5ibxPjB7"
Specifically, it has a line containing the word TRIAL. Longer term license keys must be locked to a specific computer, i.e. they will enable the software on one computer only. These license keys include the word NODE instead of the word TRIAL above.

Once you have obtained one of the above license keys, store the text of it in a file, say

The location of the license file must be made known to the NAG application by setting the environment variable NAG_KUSARI_FILE to the full pathname of the file before the application is invoked.

The environment variable may be set as follows:

  1. Open System in the Control Panel (this may be under the performance and maintenance category).
  2. On the Advanced tab, click Environment Variables, click New under System variables, insert NAG_KUSARI_FILE as the variable name and the name of the license file, e.g.
      c:\Program Files\NAG\FL21\fldll214zl\license.lic
    as the value.

Further details about Kusari and how it may be configured to suit your local circumstances are included in the Kusari License Management documentation in the license\doc\ subdirectory of the software distribution.

4.2. Release to Users

The Users' Note (doc\un.html) should be checked and amended as necessary (particularly Sections 4.1, 4.3 and 6). Advice on accessing the library (see Users' Note, Section 4.1) can be checked by running a few example programs following that advice; a suitable sample would be D01AUF, E04UCA and F07ADF. The installation can also be tested using the batch files nag_example* (see Users' Note, Section 4.3). The Users' Note (doc\un.html) should then be made available to users directly, or be absorbed into local access information.

The following material should also be made accessible to users:

documentation files:

The FL21\manual folder contains the online documentation. This should be made available to users, in addition to the following:

Manual in HTMLHelp format:

NAG DLLs and their dependencies:
import libraries:
module information files:
C header files:
VB declare information:
example program material:
samples illustrating usage from various environments:
batch file to set environment variables:
program to check DLL accessibility:
licensing materials:

Note that the example material has been adapted, if necessary, from that published in the Library Manual, so that programs are suitable for execution with this implementation with no further changes (but see Section 4.3.1 for comments about possible differences in results obtained). Making the example material directly available to users provides them with easily adaptable templates for their own problems.

4.3. Further Information

For best performance, we recommend that you should use the variant of the NAG Fortran Library which is based on the supplied MKL library i.e. FLDLL214Z_mkl.dll. However if you use a version of the MKL library different from the version used in creating this implementation and you have problems when calling a NAG routine, we suggest that you use FLDLL214Z_mkl.dll with the supplied MKL or the self-contained library FLDLL214Z_nag.dll. The corresponding import libraries for FLDLL214Z_mkl.dll and FLDLL214Z_nag.dll are FLDLL214Z_mkl.lib and FLDLL214Z_nag.lib respectively. For this DLL implementation, see also Section 3 of the Users' Note, and the information in Section 4 of the Users' Note pertaining to the platform from which you are calling the DLLs.

4.3.1. Example Programs

The example results distributed were generated at Mark 21, using the software described in Section 2.2. These example results may not be exactly reproducible if the example programs are run in a slightly different environment (for example, a different Fortran compiler, a different compiler library, or a different set of BLAS or LAPACK routines). The results which are most sensitive to such differences are: eigenvectors (which may differ by a scalar multiple, often -1, but sometimes complex); numbers of iterations and function evaluations; and residuals and other "small" quantities of the same order as the machine precision.

The installer should ensure that the advice given to users in Section 4.1 of the Users' Note (un.html) is suitable for the installation. This can be done by running a few example programs following that advice. The installation can also be tested using the batch files nag_example*.bat.

4.3.2. Maintenance Level

The maintenance level of the Library can be determined by compiling and executing the example that calls A00AAF, or you could call the batch file nag_example with the argument a00aaf. See Users' Note, Example Programs. This example prints out details of the implementation, including title and product code, compiler and precision used, mark and maintenance level.

Alternatively, run the diagnostic program NAG_Fortran_DLL_info.exe which itself calls A00AAF (see Section 4.3.3).

4.3.3. Accessibility Check

The diagnostic program NAG_Fortran_DLL_info.exe, which by default is located in C:\Program Files\NAG\FL21\fldll214zl\diagnostics, may be used to check whether the DLLs FLDLL214Z_nag.dll and FLDLL214Z_mkl.dll are accessible from the current environment. If this program is started from Windows Explorer or from the
  Start|All Programs|NAG|FL21|NAG Fortran Library DLLs. Check Accessibility
shortcut on the Start Menu, the DLLs will be found if the global PATH environment variable has been set to include their location. If it is run from a Command Prompt window, then the environment local to that window will prevail. (See Section 4.1 of the Users' Note for more information on environment variables.)

For each of the DLLs that it loads successfully, NAG_Fortran_DLL_info.exe will print the location of the DLL, and the implementation details as provided by a call to the routine A00AAF. It also calls A00ACF to check the availability of a valid license key if required by the implementation and reports if this is not found; "Status OK" indicates that a valid key was either found or not required.

5. Documentation

On-line documentation is bundled with this implementation. Please see Section 4.

6. Support from NAG

(a) Contact with NAG

Queries concerning this document or the implementation generally should be directed initially to your local Advisory Service. If you have difficulty in making contact locally, you can contact NAG directly at one of the addresses given in the Appendix. Users subscribing to the support service are encouraged to contact one of the NAG Response Centres (see below).

(b) NAG Response Centres

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 FLDLL214ZL).

(c) NAG Websites

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:, or

(d) NAG Electronic Newsletter

If you would like to be kept up to date with news from NAG then please register to receive our free electronic newsletter, which will alert you to special offers, announcements about new products or product/service enhancements, customer stories and NAG's event diary. You can register via one of our websites, or by contacting us at

(e) Product Registration

To ensure that you receive information on updates and other relevant announcements, please register this product with us. For NAG Library products this may be accomplished by filling in the online registration form at

7. User Feedback

Many factors influence the way that NAG's products and services evolve, and your ideas are invaluable in helping us to ensure that we meet your needs. If you would like to contribute to this process, we would be delighted to receive your comments. Please contact any of the NAG Response Centres (shown below).

Appendix - Contact Addresses

Wilkinson House
Jordan Hill Road
OXFORD  OX2 8DR                         NAG Ltd Response Centre
United Kingdom                          email:

Tel: +44 (0)1865 511245                 Tel: +44 (0)1865 311744
Fax: +44 (0)1865 310139                 Fax: +44 (0)1865 310139

1431 Opus Place, Suite 220
Downers Grove
IL 60515-1362                           NAG Inc Response Center
USA                                     email:

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

Tel: +81 (0)3 5542 6311
Fax: +81 (0)3 5542 6312