13
JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

Embed Size (px)

Citation preview

Page 1: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

JINRLIB program library

Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N.

Joint Institute for Nuclear Research

Page 2: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research
Page 3: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

to provide the stable and permanent support for JINR users and their computers of various types;

to preserve results of job, done by old generation of specialists in numeric methods;

to stimulate JINR scientists to their own programs development.

Page 4: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

JINRLib structure

The foundation of JINRLib is a kernel of very popular in the past Dubna, MathLib and KernLib from CERN libraries.

The replenishment originates by new programs created by JINR researchers and their collaborants.

The librarian programs identify by unique index or name. They apply:

as object modules;as standalone packages;

Page 5: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

Organization principles and technology for object modules maintenance

Program included in JINRLib as an object module is a set of 3 things:

• the source – file containing Fortran or C code; • the program description; • the test, input data for test, results of test.

All programs operate with 64-bits floating-point numbers.

Page 6: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

Each program is situated in separate directory, named by librarian index. For example, program A101 is kept in A101 directory as a set of 6 files: A101.for - the source, A101.txt, A101E.txt - description (Russian and English), T_A101.for - the test, A101.dat - data for test, A101.res - result of running test.

The head librarian directory is called JINRLIB. It contains:- the program for full rebuilding of library;- the result of this rebuilding;- the A101 – Z999 subdirectories for corresponding indexes;- temporary files for building;

Page 7: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

JINRLib is tested under Unix (Linux) and Windowscomputer platforms:

- “the individual work” with each program: source checking, complete testing, results analyze, standardization of program description.

- the real building of library is individual for each platform and for each used compiler. This is “script”, containing the environment settings, compilation and linkage.

The main efforts – to extremely simplify library building: “from single button”.

Page 8: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

dir=`ls`for name in $dirdo. . . . . . . . .####### Special compilation

mode: z008if test -d $name then case $name in####### Fortran + C: z008) cd $name

g77 -c $name.f gcc -c "$name"c.c ar rv ../libjinr.a $name.o "$name"c.o ranlib ../libjinr.a rm *.o

cd .. ;;. . . . . . . . . esac fidone

JINRLib building.

Shell-script for Linux.

Page 9: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

ImplementationIn JINR Central Information and Computer Complex object

modules JINRLIB are ready for: OS Scientific Linux 4, CPU x86_64:GNU Fortran 77 compiler (g77) - libjinr.a; GNU Fortran 95 compiler (gfortran) - libjinr95.a;Intel Fortran Compiler (ifort) – libjinri.a.OS Scientific Linux 3, CPU i386:GNU Fortran 77 compiler (g77) - libjinr.a.

Placement: /usr/libexec/CERNLIB/jinr

JINRLib for OS Windows 9X/NT/2000/XP is ready for: GNU Fortran 77, Compaq Visual Fortran, Fortran PowerStation, Microsoft Fortran.

Page 10: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

Examples of JINRLib object modules usage

Scientific Linux

g77

Compilation: g77 myprog.f -L/usr/libexec/CERNLIB/jinr –ljinr or: g77 myprog.f –L$CERN/jinr –ljinrView of library content: ar t /usr/libexec/CERNLIB/jinr/libjinr.a

Windows 9X/NT/2000/XP

Compaq Visual Fortran 6.6

Compilation from command-line: fl32 myprog.for %PLACE%\jinrlib.libGUI-regime: Project/Settings/Link: add jinrlib.lib to Object/Library/modules setting FullPath.View of library content : lib /list %PLACE%\jinrlib.lib

Page 11: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

Standalone packages maintenance

Some programs cannot be applied as Object Modules (e.g. they are not portable, the source is inaccessible,...). Nevertheless, by author’s wish they also may be put into JINRLib. There are about 40 such kind of programs subdivided into following classes (according classification used in JINR Publishing Department):• High energy theoretical physics• Low energy theoretical physics• Heavy ion physics• Automatization of data processing• Computing mathematics and technique

Page 12: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

WWW-maintenance for JINRLIB

WebSite http://www.jinr.ru/programs/jinrlibprovides electronic access to JINRLIB, starting from catalog, full description of any program, down to program sources and object modules.

Some program packages have counters of visitors, certainly showing user’s interest to them. The most popular are now the classical mathematical packages. As for specific applied packages, each of them has its own range of users.

Page 13: JINRLIB program library Popkova L.B., Sapozhnikov A.P., Sapozhnikova T.F., Fedorova R.N. Joint Institute for Nuclear Research

http://www.jinr.ru/programs/jinrlib