Adrià Vilanova Martínez | ebb8779 | 2022-06-04 20:07:20 +0200 | [diff] [blame] | 1 | real*8 function magne(S, L) |
avm99963 | 45a8a46 | 2022-06-04 12:41:03 +0200 | [diff] [blame] | 2 | implicit none |
3 | integer*4, intent(in) :: L | ||||
4 | integer*2, intent(out) :: S(1:64,1:64) | ||||
5 | integer*4 :: i, j | ||||
6 | real*8 :: mag | ||||
7 | mag = 0d0 | ||||
8 | |||||
9 | do i = 1, L | ||||
10 | do j = 1, L | ||||
11 | mag = mag + S(i, j) | ||||
12 | enddo | ||||
13 | enddo | ||||
14 | |||||
15 | magne = mag | ||||
16 | return | ||||
Adrià Vilanova Martínez | ebb8779 | 2022-06-04 20:07:20 +0200 | [diff] [blame] | 17 | end function magne |