I get the following error message when compiling COAWST code using AVERAGE_DETIDE cpp option and gfortran compiler:
Code: Select all
/apps/gcc/installed/bin/gfortran -c -frepack-arrays -fopenmp -O3 -ffast-math -ftree-vectorize -funroll-loops -w -ffree-form -ffree-line-length-none -frecord-marker=4 -fconvert=big-endian set_avg.f90
set_avg.f90:1912.32:
integer, intent(in) :: NTC
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:1928.30:
integer, dimension(2*NTC+1) :: indx
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:1931.33:
real(r8), dimension(0:2*NTC) :: Ak
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:1932.33:
real(r8), dimension(0:2*NTC) :: tide_harmonics
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:1933.33:
real(r8), dimension(0:2*NTC,0:2*NTC) :: C, Y
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:2009.16:
NTC2=2*NTC
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:2021.21:
DO nk=1,NTC
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:2026.23:
DO mk=1,NTC
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:2030.15:
END DO
1
Error: Expecting END IF statement at (1)
set_avg.f90:2031.13:
END DO
1
Error: Expecting END IF statement at (1)
set_avg.f90:2032.10:
tide_harmonics(0)=1.0_r8
1
Error: Unclassifiable statement at (1)
set_avg.f90:2033.21:
DO nk=1,NTC
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:2034.47:
tide_harmonics(nk )=SinOmega(nk)
1
Error: Unexpected STATEMENT FUNCTION statement at (1)
set_avg.f90:2035.12:
tide_harmonics(nk+NTC)=CosOmega(nk)
1
Error: Unclassifiable statement at (1)
set_avg.f90:2036.13:
END DO
1
Error: Expecting END IF statement at (1)
set_avg.f90:2134.21:
DO nk=1,NTC
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:2139.23:
DO mk=1,NTC
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current program unit
set_avg.f90:2143.15:
END DO
1
Error: Expecting END IF statement at (1)
set_avg.f90:2144.13:
END DO
1
Error: Expecting END IF statement at (1)
set_avg.f90:2145.24:
tide_harmonics(0)=1.0_r8
1
Error: 'tide_harmonics' at (1) is not a variable
set_avg.f90:2146.21:
DO nk=1,NTC
1
Error: Name 'ntc' at (1) is an ambiguous reference to 'ntc' from current progr unit
set_avg.f90:2147.47:
tide_harmonics(nk )=SinOmega(nk)
1
Error: Unexpected STATEMENT FUNCTION statement at (1)
set_avg.f90:2148.26:
tide_harmonics(nk+NTC)=CosOmega(nk)
1
Error: 'tide_harmonics' at (1) is not a variable
set_avg.f90:2149.13:
END DO
1
Error: Expecting END IF statement at (1)
set_avg.f90:2261.10:
C(0,0)=1.0_r8 ! time-averaged coefficient
1
Error: Unclassifiable statement at (1)
Fatal Error: Error count reached limit of 25.
Any comments or suggestion on how to solve this error?
Thank you so much in advance!