Ask Your Question
0

AGRIF+Sediment

asked 2022-09-06 21:33:51 +0200

andres gravatar image

Hi,

I am getting the following errors while compiling CROCO with AGRIF+Sediment module Is there a missing flag for the compilation?

OPENMP

RIF_MODELFILES/main.F > main_.f gfortran -c -O3 -fdefault-real-8 -fdefault-double-8 -IAGRIF -fopenmp main_.f -o main.o main_.f:1397:53:

   integer(4), parameter :: NST = NSAND+NMUD+NGRAV
                                                 1

Error: Symbol ‘ngrav’ at (1) has no IMPLICIT type main_.f:1398:45:

   integer(4), parameter :: ntrc_sed = NST
                                         1

Error: Symbol ‘nst’ at (1) has no IMPLICIT type main_.f:1404:12:

and with MPI

RIF_MODELFILES/main.F > main_.f mpif90 -c -O3 -fdefault-real-8 -fdefault-double-8 -IAGRIF main_.f -o main.o main_.f:1420:53:

   integer(4), parameter :: NST = NSAND+NMUD+NGRAV
                                                 1

Error: Symbol ‘ngrav’ at (1) has no IMPLICIT type main_.f:1421:45:

   integer(4), parameter :: ntrc_sed = NST
                                         1
edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted
0

answered 2022-09-07 10:37:47 +0200

Rachid gravatar image

Hi Andres

I. Agrif seems to struggle with defining NST as the sum of others parameters at line

   parameter (NST=NSAND+NMUD+NGRAV)

As a workaround you can force it with an explicit declaration of the number of sediment, for instance

   parameter (NST=2)

if you have NSAND=2, NMUD=0 and NGRAV=0. I have no idea why there is such behavour

II. Then I found an other issue if BBL is not activated, Agrif_lev_sedim is not declared, in param.h again :

 #if defined BBL && defined AGRIF
   integer Agrif_lev_sedim 
   parameter (Agrif_lev_sedim=0) 
  #endif

You can just suppress the reference to BBL :

 #if defined AGRIF
    integer Agrif_lev_sedim
    parameter (Agrif_lev_sedim=0)
 #endif

With these two changes, I'm able to compile BENGUELA with AGRIF and SEDIMENT activated. I haven't try to run it though... Attached the modified param.h

regards

Rachid

C:\fakepath\param.h

edit flag offensive delete link more

Comments

Thanks, that works (compiles). I will test a run.

andres gravatar imageandres ( 2022-09-07 21:56:00 +0200 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2022-09-06 21:33:51 +0200

Seen: 24 times

Last updated: Sep 07