Opened 10 years ago

Closed 10 years ago

#475 closed upgrade (Done)

Changed gasdev.F which is used to generate randim numbers

Reported by: arango Owned by: arango
Priority: major Milestone: Release ROMS/TOMS 3.4
Component: Nonlinear Version: 3.4
Keywords: Cc:

Description

Updated couple of routines associated with the floats:

  • Changed routine gasdev.F which is used to compute normally-distributed random number sequences. This routine has several F90 constructs that maybe problematic in old compilers. This is obviously a compiler bug. If so, we get usually error in the following expression:
              CALL array_copy (PACK(v1(ng:n), mask(ng:n)), v1(ng:), nn, m)
    
    Some compilers either fail to recognize the vector array out of the intrinsic PACK function or its numerical representation even if the routine array_copy is inside of an interface. To avoid this problem, the above statement is replaced by:
              mc=COUNT(mask(ng:n))
              v3(1:mc)=PACK(v1(ng:n), mask(ng:n))
              CALL array_copy (v3(1:mc), v1(ng:), nn, m)
    
    Many thanks to first Julio Sheinbaum for reporting this one during the ROMS 4D-Var workshop and recently to Diego Narvaez when trying the floats.
  • Corrected an out-of-range computation in grid_coords.F when computing the initial depths for out-of-bounds initial float locations. The following conditional is added:
          IF (MyThread(l).and.                                          &
     &        ((DRIFTER(ng)%Tinfo(ixgrd,l).ge.0.5_r8).and.              &
     &         (DRIFTER(ng)%Tinfo(iygrd,l).ge.0.5_r8).and.              &
     &         (DRIFTER(ng)%Tinfo(ixgrd,l).le.                          &
     &          REAL(Lm(ng),r8)+0.5_r8).and.                            &
     &         (DRIFTER(ng)%Tinfo(iygrd,l).le.                          &
     &          REAL(Mm(ng),r8)+0.5_r8))) THEN
        ...

Change History (1)

comment:1 Changed 10 years ago by arango

  • Resolution set to Done
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.