]> legacy.helldragon.eu Git - oldfortrancodes.git/blob - README.md
Initial commit by Marcello Galli
[oldfortrancodes.git] / README.md
1 Legacy codes for neutron reactor cross section management
2 =========================================================
3
4 These codes where developed between 1976 and 1985 at the
5 Italian Nuclear Energy Agency: *CNEN*, restructured
6 and renamed in 1982 as *ENEA*.
7
8 They are FORTRAN code, running on IBM mainframes, used to
9 compute cross sections for fast nuclear reactor. 
10
11 After the ending of the nuclear program in Italy the agency 
12 was restructured and changed name and purpose. It is now:
13 [*"ENEA: Agenzia nazionale per le nuove tecnologie, 
14 l'energia e lo sviluppo economico sostenibile"*]
15 (http://www.enea.it/). Some activity
16 on nuclear reactors has been maintained, but these codes, 
17 intended for fast reactor, where forgotten and lost. 
18
19 Marcello Galli wrote most of them; they are saved
20 here to be included in the collection of the 
21 [*Software Heritage*] project (https://www.softwareheritage.org/). 
22  
23 Micro
24 -----
25
26 M.Galli, then student of Physics at the Bologna University,
27 wrote this code for his thesis, between 1976 and 1977; 
28 it was used for the interpretation of cross section measurements
29 performed in Bologna, in the RB2 experimental reactor, at
30 [Montecuccolino](https://www.bibliotecasalaborsa.it/cronologia/bologna/1963/1136)
31
32 It is written in FORTRAN 66, about one thousand lines; in this
33 period punched cards where used with a rigid 80-columns formatting.
34 The code was run on the IBM 3090 of the Bologna CNEN center.
35
36 There was no dynamic allocation of arrays in old FORTRAN.
37 Here, at the beginning, the FORTRAN code compute the dimension of all the
38 needed arrays, then a little assembler routine (maybe by R.Simonini) is called to allocate
39 space for a big array named: "A". This is divided into small arrays when
40 passed to the routines of the code, along with the needed dimensions
41 of the arrays, which are defined in the routines.
42 FORTRAN gives arguments to routines by address, making possible
43 to obtain some kind of dynamical dimensions in this way.
44   
45 We can note here a peculiar usage of labels; the common usage, at that time, was
46 a progressive numbering, here instead label numbering is used to ease code
47 reading: low numbers are loop ending statements, intermediate values
48 are target of goto statements, higher values are used for format statements. 
49 There are almost no comments... to save punching time,
50 but the author maintained somewhere an hand written and detailed documentation.
51
52 In old FORTRAN the last characters of each card where used for card numbering; 
53 the numbers that can be seen here in the source code have been inserted later,
54 by some IBM archive system (maybe the old 'librarian' system), 
55 the numbers in the original card deck here different: when changing or adding a card 
56 the deck wasn't renumbered... punching again all the cards. 
57
58
59 Reference: 
60
61    Marcello Galli
62    
63    Thesis, degree in physics, Bologna University, 1977.
64    
65    Interpretazione di Misure Integrali di Sezioni d'Urto 
66    di Materiali di Interesse per i Reattori Veloci Effettuate 
67    con la Tecnica della Reattivita Nulla
68
69 Geres
70 -----
71
72 This is a FORTRAN-77 program of about two thousand lines, 
73 written around 1980 by M.Galli,
74 then a contractor at the CNEN research center in Bologna;  
75 C.Petrella contributed to the code; some parts are taken
76 from the [MC2-II] (https://www.ne.anl.gov/codes/mc2-2/) code.
77
78 The program was used to compute heterogeneous cross section, starting
79 from data from the MC2-II code, for fast reactor calculations. 
80 The code was run on an IBM 3090 computer.
81
82 We have the rigid 80-columns format of the old FORTRAN, but the
83 TSO IBM option had been introduced at the CNEN research center,
84 with visual terminals and interactive usage. We hadn't
85 punched cards anymore.
86
87 If we compare this program with the "Micro" program of same years before,
88 by the same author, we can see many differences due to the use of a 
89 visual editor and a slightly different coding style:
90 there are more and clearer comments (no need to punch more cards),
91 and the code structure is more clear. 
92 We haven't yet structured programming, and the author uses
93 the same tricks we have seen in the Micro program:
94 fortran common areas to isolate part of the code and different label numbers
95 for loop, goto and formatting statements; to ease code readability. 
96
97 The main program has the unique function of allocating a
98 big array, in a common area; this array is subdivided in different,
99 smaller, arrays when subroutines are called. The subroutine: 'address'
100 computes the dimension of the smaller arrays. 
101
102 Magnetic tapes where used for input and output data: some megabytes
103 of data where, at that time, too much for the limited computer memory. 
104
105
106 Teseo
107 -----
108
109 Teseo is a program of about twenty thousand statements, written 
110 by M.Galli, between 1984 and 1987, in FORTRAN-IV, running on an IBM 3090 computer. 
111 It computes data for the MC2-II code, starting from the 
112 [ENDF-B IV](https://t2.lanl.gov/nis/data/endf/endfiv.htmldata) 
113 evaluated nuclear data files.
114
115 It used a somewhat modular structure, being divided into four independent parts, 
116 communicating via temporary files; the available memory on mainframe 
117 computers of that period was limited.
118 In this program we can see some changes in the coding style, under the influence of 
119 more modern versions of FORTRAN, as the one used on the Vax mini-computers, 
120 which was FORTRAN-77 with  Dec extension;  
121 these extensions weren't available on the IBM, and the code is still 
122 FORTRAN IV, we find some indentation here and there, 
123 but not the: "if, then, else, endif" statements introduced in FORTRAN-77.  
124
125
126 Other programs
127 --------------
128
129 Data produced by different
130 codes for nuclear reactor projects had different formatting;
131 to allow for interoperability many little programs where 
132 needed to change data format. Some of these old FORTRAN
133 code codes are saved in the *other* folder.
134
135 ------------------------------------------------------------
136
137 These programs are here as an example of  old FORTRAN usage,
138 to be included in the collection of the 
139 [*Software Heritage*] project (https://www.softwareheritage.org/).
140