I4dvar compilation error about i4dvar.f90 and mod_fourdvar

Discussion about tangent linear and adjoint models, variational data assimilation, and other related issues.

Moderators: arango, robertson

Post Reply
Message
Author
MIKESHEN
Posts: 4
Joined: Mon Jan 22, 2018 6:15 pm
Location: Zhejiang University

I4dvar compilation error about i4dvar.f90 and mod_fourdvar

#1 Unread post by MIKESHEN »

Hello, i upgrade ROMS to the new version:
run the build_roms_4dvshc.csh file.
I have check my bash.csh .h and .mk files. Still with some trouble like this:
i4dvar.f90:319.10:

USE mod_fourdvar
1
Error: 'increment' of module 'mod_fourdvar', imported at (1), is also the name of the current program unit

Any help or suggestion will be highly appreciated.
Attachments
build_roms_4dvshc.c
(12.34 KiB) Downloaded 503 times
wc13 (2).h
(4.77 KiB) Downloaded 535 times
Linux-gfortran.mk
(11.76 KiB) Downloaded 522 times

TMCuong
Posts: 1
Joined: Mon Apr 14, 2014 4:25 pm
Location: Centre for Oceanography

Re: I4dvar compilation error about i4dvar.f90 and mod_fourdvar

#2 Unread post by TMCuong »

Hi there, I encountered similar error with gfortran 9.3. However, ROMS run well with intel fortran compiler instead of gfortran.

User avatar
arango
Site Admin
Posts: 1368
Joined: Wed Feb 26, 2003 4:41 pm
Location: DMCS, Rutgers University
Contact:

Re: I4dvar compilation error about i4dvar.f90 and mod_fourdvar

#3 Unread post by arango »

Yes, gfortran is a stricter compiler. Other compilers relax the Fortran standard rule that we cannot have a module, subroutine, or variable with the same name. I missed this one. Thank you for reporting this issue. Please, update your code.

MIKESHEN
Posts: 4
Joined: Mon Jan 22, 2018 6:15 pm
Location: Zhejiang University

Re: I4dvar compilation error about i4dvar.f90 and mod_fourdvar

#4 Unread post by MIKESHEN »

thanks a lot for your fast answer!
Greetings! i was able to solve the problem~

Post Reply