Debian Codegraph @

debian/patches/fortran_patches

raw
1 From: Carlo Segre <[email protected]>
2 Date: Tue, 6 Aug 2024 12:53:43 +0200
3 Subject: Patches to the FORTRAN source
4
5 * Enable FEFF to calculate chi
6 * Modify array dimensioning for increased capacity
7 ---
8 src/feff6/feff.f | 10 +++++-----
9 src/lib/iff_show.f | 8 ++++----
10 2 files changed, 9 insertions(+), 9 deletions(-)
11
12 diff --git a/src/feff6/feff.f b/src/feff6/feff.f
13 index 3f7497b..0ec0092 100644
14 --- a/src/feff6/feff.f
15 +++ b/src/feff6/feff.f
16 @@ -117,11 +117,11 @@ c Dump out fbetac for central atom and first pot
17 call genfmt (ipr3, critcw, sig2g, iorder)
18 endif
19
20 -c if (mchi .eq. 1) then
21 -c call echo('Calculating chi...')
22 -c call ff2chi (ipr4, critcw, s02, tk, thetad, icsig,
23 -c 1 vrcorr, vicorr)
24 -c endif
25 + if (mchi .eq. 1) then
26 + call echo('Calculating chi...')
27 + call ff2chi (ipr4, critcw, s02, tk, thetad, icsig,
28 + 1 vrcorr, vicorr)
29 + endif
30
31 call echo('Feff done. Have a nice day.')
32 end
33 diff --git a/src/lib/iff_show.f b/src/lib/iff_show.f
34 index b628372..f54f7af 100644
35 --- a/src/lib/iff_show.f
36 +++ b/src/lib/iff_show.f
37 @@ -431,8 +431,8 @@ c
38 character*(*) s, t , messg*256
39 integer k, j, istrln
40 external istrln
41 - k = max(13, istrln(s))
42 - j = max(2, istrln(t))
43 + k = min(max(13, istrln(s)),256)
44 + j = min(max(2, istrln(t)), 252-k)
45 write(messg,11) s(1:k), ' = ', t(1:j)
46 call echo(messg)
47 11 format('$',3a)
48 @@ -443,8 +443,8 @@ c
49 character*(*) s, t , messg*256
50 integer k, j, istrln
51 external istrln
52 - k = max(14, istrln(s))
53 - j = max(2, istrln(t))
54 + k = min(max(14, istrln(s)), 256)
55 + j = min(max(2, istrln(t)), 253-k)
56 write(messg,11) s(1:k), ': ', t(1:j)
57 call echo(messg)
58 11 format (3a)