Skip to content

Commit

Permalink
ww3_nonlinear_cg: add debug output ...
Browse files Browse the repository at this point in the history
  • Loading branch information
aronroland committed Oct 5, 2024
1 parent 833e724 commit cacffb8
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
8 changes: 8 additions & 0 deletions model/src/w3profsmd_pdlib.F90
Original file line number Diff line number Diff line change
Expand Up @@ -5685,6 +5685,7 @@ SUBROUTINE PDLIB_JACOBI_GAUSS_SEIDEL_BLOCK(IMOD, FACX, FACY, DTG, VGX, VGY, LCAL
! init matrix and right hand side
!
call print_memcheck(memunit, 'memcheck_____:'//' WW3_PROP SECTION 2')

!
IF (.not. LSLOC) THEN
IF (IMEM == 1) THEN
Expand All @@ -5694,6 +5695,8 @@ SUBROUTINE PDLIB_JACOBI_GAUSS_SEIDEL_BLOCK(IMOD, FACX, FACY, DTG, VGX, VGY, LCAL
ENDIF
B_JAC = ZERO
ENDIF

IF (IAPROC == 1) WRITE(*,*) 'SUM B_JAC and ASPAR_DIAG_ALL', SUM(B_JAC), SUM(ASPAR_DIAG_ALL)
call print_memcheck(memunit, 'memcheck_____:'//' WW3_PROP SECTION 3')
!
! source terms
Expand Down Expand Up @@ -5835,6 +5838,7 @@ SUBROUTINE PDLIB_JACOBI_GAUSS_SEIDEL_BLOCK(IMOD, FACX, FACY, DTG, VGX, VGY, LCAL
#endif
END IF
END DO
IF (IAPROC == 1) WRITE(*,*) 'IMEM SUM ESUM', IP, SUM(ESUM)
ENDIF ! IMEM

#ifdef W3_DEBUGSOLVERCOH
Expand Down Expand Up @@ -5922,6 +5926,7 @@ SUBROUTINE PDLIB_JACOBI_GAUSS_SEIDEL_BLOCK(IMOD, FACX, FACY, DTG, VGX, VGY, LCAL
PRE_VA(:, IP)=REAL(eSum)
#endif
eSum(1:NSPEC) = eSum(1:NSPEC) / ASPAR_DIAG(1:NSPEC)
IF (IAPROC == 1) WRITE(*,*) 'SUM ESUM AFTER DIV', IP, SUM(ESUM)
#ifdef W3_DEBUGFREQSHIFT
WRITE(740+IAPROC,*) 'JSEA=', JSEA, ' nbIter=', nbIter
DO ISP=1,NSPEC
Expand Down Expand Up @@ -6294,6 +6299,9 @@ SUBROUTINE PDLIB_JACOBI_GAUSS_SEIDEL_BLOCK(IMOD, FACX, FACY, DTG, VGX, VGY, LCAL
ENDIF ! FLSOU
END DO ! JSEA

IF (IAPROC == 1) WRITE(*,*) 'SUM VA', SUM(VA)
STOP

#ifdef WEIGHTS
INQUIRE ( FILE='weights.ww3', EXIST = lexist )
if (.not. lexist) then
Expand Down
1 change: 1 addition & 0 deletions model/src/w3srcemd.F90
Original file line number Diff line number Diff line change
Expand Up @@ -2244,6 +2244,7 @@ SUBROUTINE W3SRCE ( srce_call, IT, ISEA, JSEA, IX, IY, IMOD, &
END IF
#endif


!
#ifdef W3_DEBUGSRC
IF (IX .eq. DEBUG_NODE) THEN
Expand Down
5 changes: 5 additions & 0 deletions model/src/w3wavemd.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1560,6 +1560,8 @@ SUBROUTINE W3WAVE ( IMOD, ODAT, TEND, STAMP, NO_OUT &
END IF ! PDLIB
#endif

IF (IAPROC == 1) WRITE(*,*) 'SUM B_JAC W3WAVE', SUM(B_JAC)


#ifdef W3_PDLIB
#ifdef W3_DEBUGSRC
Expand Down Expand Up @@ -1811,6 +1813,8 @@ SUBROUTINE W3WAVE ( IMOD, ODAT, TEND, STAMP, NO_OUT &
END IF
END IF

IF (IAPROC == 1) WRITE(*,*) 'SUM B_JAC W3WAVE BEFORE PDLIB_W3XYPUG_BLOCK_IMPLICIT', SUM(B_JAC)

IF (LPDLIB) THEN
!
#ifdef W3_PDLIB
Expand All @@ -1831,6 +1835,7 @@ SUBROUTINE W3WAVE ( IMOD, ODAT, TEND, STAMP, NO_OUT &
#endif
#ifdef W3_PDLIB
CALL PDLIB_W3XYPUG_BLOCK_IMPLICIT(IMOD, FACX, FACX, DTG, VGX, VGY, UGDTUPDATE )
IF (IAPROC == 1) WRITE(*,*) 'SUM B_JAC W3WAVE AFTER PDLIB_W3XYPUG_BLOCK_IMPLICIT', SUM(B_JAC)
#endif
#ifdef W3_PDLIB
ELSE IF(FSTOTALEXP .and. (IT .ne. 0)) THEN
Expand Down

0 comments on commit cacffb8

Please sign in to comment.