NAG
NAG (The Numerical Algorithms Group) provides sub-routine libraries in a range of computer languages for the solution of numerical and statistical problems.NAG Libraries and their Location
| Sub-Routine Type & Supported Complier | Library location | Object Library Name | Location of Header Files | Location of Examples | Location of Documents |
| GNU C/C++ | /apps/NAG/dll6a08dgl | libnagc_nag.a | include | examples | doc |
| FORTRAN 77 | /apps/NAG/fll6i21dgl | libnag.a | --- | examples | doc |
| FORTRAN 95 | /apps/NAG/fnl6i04dgl | libnagfl90.a | --- | examples | doc |
Example for Using NAG C Subroutine
NAG C Library is a collection of C functions for the solution of numerical and statistical problems. Use the following options to link your code to the NAG C Library.gcc d01ajce.c -I/apps/NAG/cll6a08dgl/include /apps/NAG/cll6a08dgl/lib/libnagc_nag.a -lpthread -lm -o d01ajce.exe
| Options | Description |
| gcc | calls the GNU C compiler |
| d01ajce.c | name of your source file to be compiled. In this case. In this particular case, d01ajce.c is a sample program you can find under /apps/NAG/dll6a08dgl/examples. |
| -I | A flag that indicates what directory will be searched for include files |
| -L | Flag a directory that contains the NAG object library |
| -lnagc | Flag linking other NAG C library |
| -o | A flag to direct output to a different file |
Each of these options must be included. The entire command should appear on the same line.
NAG Online Documentation
Additional Information - Information on subroutine searches, manuals and technical guides is provided by NAG