Changes between Initial Version and Version 2 of Ticket #152


Ignore:
Timestamp:
12/05/08 22:14:24 (16 years ago)
Author:
arango
Comment:

Done. The wetting and drying algorithm was redesigned so it is more robust. A new routine wetdry.F was introduced to compute the wet/dry mask (rmask_wet, umask_wet, and vmask_wet), time-averaged mask over all barotropic steps (rmask_wet_avg), and full land/sea and wet/dry masks (rmask_full, umask_full, vmask_full). The full mask are only used for output purposes.

The barotropic velocities masking due to wetting and drying is somewhat tricky. For example, we now have:

# ifdef WET_DRY
            cff5=ABS(ABS(umask_wet(i,j))-1.0_r8)
            cff6=0.5_r8+DSIGN(0.5_r8,ubar(i,j,knew))*umask_wet(i,j)
            cff7=0.5_r8*umask_wet(i,j)*cff5+cff6*(1.0_r8-cff5)
            ubar(i,j,knew)=ubar(i,j,knew)*cff7
            fac1=cff2/cff
            rhs_ubar(i,j)=(ubar(i,j,knew)*(Dnew(i,j)+Dnew(i-1,j))-      &
     &                     ubar(i,j,kstp)*(Dstp(i,j)+Dstp(i-1,j)))*     &
     &                    fac1
# endif

The computation of the depths and level thicknesses are moved from step2d to main3d. This is done for clarity and to facilitate nesting in the future. A new internal cpp option is introduced (MOVE_SET_DEPTH) to avoid doing this in the adjoint-based algorithm. This is temporary and it will removed when the testing in several adjoint-based applications is completed. I tied few adjoint-based computations and I got identical sanity checks.

Many thanks to John Warner for his help in rewriting the wetting and drying option. We hope that this algorithm is more robust and eliminated the problem reported at the open boundaries.

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #152

    • Property ResolutionFixed
    • Property Status newclosed
    • Property Summary *mask_wet not initializedWet/dry masks not initialized
  • Ticket #152 – Description

    initial v2  
    1 On the very first time through step2d, all the mask_wet arrays are still zero from the initialization to IniVal. This results in all of the ubar velocities ending up in the ELSE on line 2377 and getting set to zero (since they are multiplied by the zero umask_wet). The masks could be set in ini_fields before zeta gets modified.
     1On the very first time through '''step2d''', all the mask_wet arrays are still zero from the initialization to !IniVal. This results in all of the '''ubar''' velocities ending up in the ELSE on line 2377 and getting set to zero (since they are multiplied by the zero '''umask_wet'''). The masks could be set in '''ini_fields''' before '''zeta''' gets modified.