Skip to content

Commit

Permalink
Merge branch 'NOAA-EMC:develop' into testing/pdlib_small_mesh
Browse files Browse the repository at this point in the history
  • Loading branch information
MatthewMasarik-NOAA authored Feb 6, 2024
2 parents 9b39136 + fd6d559 commit 50a8d3c
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
8 changes: 6 additions & 2 deletions model/src/w3fld1md.F90
Original file line number Diff line number Diff line change
Expand Up @@ -550,9 +550,13 @@ SUBROUTINE W3FLD1( ASPC, FPI, WNDX,WNDY, ZWND, &
TAUDIR=atan2(TAUY, TAUX)
! Note: add another criterion (stress direction) for iteration.
CRIT1=(ABS(USTAR-USTRB)*100.0)/((USTAR+USTRB)*0.5) .GT. 0.1
CRIT2=(ABS(TAUDIR-TAUDIRB)*100.0/(TAUDIR+TAUDIRB)*0.5) .GT. 0.1
IF ((TAUDIR+TAUDIRB).NE.0.) THEN
CRIT2=(ABS(TAUDIR-TAUDIRB)*100.0/(TAUDIR+TAUDIRB)*0.5) .GT. 0.1
ELSE
CRIT2=.TRUE.
ENDIF
IF (CRIT1 .OR. CRIT2) THEN
! IF ((ABS(USTAR-USTRB)*100.0)/((USTAR+USTRB)*0.5) .GT. 0.1) THEN
! IF ((ABS(USTAR-USTRB)*100.0)/((USTAR+USTRB)*0.5) .GT. 0.1) THEN
USTRB=USTAR
TAUDIRB=TAUDIR
CTR=CTR+1
Expand Down
7 changes: 5 additions & 2 deletions model/src/ww3_prnc.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1059,15 +1059,15 @@ PROGRAM W3PRNC
! Manages the simple closure of the grid
!
IF (ICLO.EQ.ICLOSE_NONE) THEN
IF (IX21(IX,1).LT.1.OR.IX21(IX,1).GT.NXI-1) WRITE(NDSO,1042) IX, IY, X, Y
IF (IX21(IX,1).LT.1.OR.IX21(IX,1).GT.NXI-1) WRITE(NDSO,1041) IX, X, Y
IX21(IX,1) = MAX ( 1 , MIN(IX21(IX,1),NXI-1) )
IX22(IX,1) = IX21(IX,1) + 1
ELSE
IX21(IX,1) = MAX ( 1 , MIN(IX21(IX,1),NXI) )
IX22(IX,1) = MOD(IX21(IX,1),NXI)+1
END IF
IY21(IX,1) = 1 + INT((Y-Y0I)/SYI)
IF (IY21(IX,1).LT.1.OR.IY21(IX,1).GT.NYI-1) WRITE(NDSO,1042) IX, IY, X, Y
IF (IY21(IX,1).LT.1.OR.IY21(IX,1).GT.NYI-1) WRITE(NDSO,1041) IX, X, Y
IY21(IX,1) = MAX ( 1 , MIN(IY21(IX,1),NYI-1) )
IY22(IX,1) = IY21(IX,1) + 1
!
Expand Down Expand Up @@ -2438,6 +2438,9 @@ PROGRAM W3PRNC
' 2MS2 2MN2 2NK2 MNS2 MSN2 2SM2 3MSN2 ' &
' M4 MS4 MN4 M6 2MS6 2MN6'/)
!
1041 FORMAT (/' *** WAVEWATCH-III WARNING W3PRNC : '/ &
' GRID POINT ',I6,2F7.2,/ &
' NOT COVERED BY INPUT GRID.'/)
1042 FORMAT (/' *** WAVEWATCH-III WARNING W3PRNC : '/ &
' GRID POINT ',2I6,2F7.2,/ &
' NOT COVERED BY INPUT GRID.'/)
Expand Down

0 comments on commit 50a8d3c

Please sign in to comment.