| 1 |
! { dg-do compile } |
| 2 |
|
| 3 |
subroutine expa (ip, iq, sabb) |
| 4 |
implicit none |
| 5 |
integer, intent(in) :: ip, iq |
| 6 |
real :: sabb(25, 8), arg(25), argj, dist |
| 7 |
integer :: i, j |
| 8 |
integer :: nuca, nucb, nucab, nuco |
| 9 |
|
| 10 |
arg = [(i * 7.5, i = 1, 25)] |
| 11 |
nuca = nuco (ip) |
| 12 |
nucb = nuco (iq) |
| 13 |
nucab = nuca * nucb |
| 14 |
dist = 0.7854 |
| 15 |
do j = 1, nucab |
| 16 |
argj = min (arg(j) * dist, 80.0) |
| 17 |
sabb(j, 1) = exp (-argj) |
| 18 |
end do |
| 19 |
call acomp (sabb, nuca) |
| 20 |
return |
| 21 |
entry rfinit |
| 22 |
stop 1 |
| 23 |
end subroutine expa |
| 24 |
|
| 25 |
subroutine acomp (saab, nuca) |
| 26 |
implicit none |
| 27 |
real :: aaint, saab |
| 28 |
integer :: i, ip, iq, j, nuc1, nuca |
| 29 |
dimension saab(nuca, nuca), aaint(nuc1, nuc1) |
| 30 |
|
| 31 |
do i = 2, nuca |
| 32 |
do j = 1, i - 1 |
| 33 |
saab(j, i) = saab(j, i) * 2.0d0 |
| 34 |
saab(i, j) = 0.0d0 |
| 35 |
end do |
| 36 |
end do |
| 37 |
return |
| 38 |
entry aaexp (aaint, nuc1) |
| 39 |
do ip = 2, nuc1 |
| 40 |
do iq = 1, ip - 1 |
| 41 |
aaint(iq, ip) = 0.5d0 * (aaint(iq, ip) + aaint(ip, iq)) |
| 42 |
end do |
| 43 |
end do |
| 44 |
end subroutine acomp |