/[MITgcm]/MITgcm/pkg/streamice/streamice_vel_solve.F
ViewVC logotype

Diff of /MITgcm/pkg/streamice/streamice_vel_solve.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.9 by jmc, Tue Sep 9 23:09:21 2014 UTC revision 1.12 by dgoldberg, Wed Jul 13 09:32:45 2016 UTC
# Line 25  C     === Global variables === Line 25  C     === Global variables ===
25  #include "PARAMS.h"  #include "PARAMS.h"
26  #include "STREAMICE.h"  #include "STREAMICE.h"
27  #include "STREAMICE_CG.h"  #include "STREAMICE_CG.h"
28  !#ifdef ALLOW_PETSC  
 !#include "finclude/petsc.h"  
 !#endif  
29    
30  #ifdef ALLOW_AUTODIFF_TAMC  #ifdef ALLOW_AUTODIFF_TAMC
31  # include "tamc.h"  # include "tamc.h"
# Line 58  C     LOCAL VARIABLES Line 56  C     LOCAL VARIABLES
56        _RL max_vel, tempu, tempv, err_lastchange, cgtol        _RL max_vel, tempu, tempv, err_lastchange, cgtol
57        CHARACTER*(MAX_LEN_MBUF) msgBuf        CHARACTER*(MAX_LEN_MBUF) msgBuf
58        LOGICAL CONVERGED        LOGICAL CONVERGED
59  #ifdef ALLOW_PETSC  
 !      myThidTemp = myThid  
 !      call streamice_initialize_petsc (myThidTemp)  
 #endif  
60  !       _RL taudx (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)  !       _RL taudx (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
61  !       _RL taudy (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)  !       _RL taudy (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
62    
# Line 128  C     LOCAL VARIABLES Line 123  C     LOCAL VARIABLES
123        _EXCH_XY_RL( tau_beta_eff_streamice , myThid )        _EXCH_XY_RL( tau_beta_eff_streamice , myThid )
124        _EXCH_XY_RL( visc_streamice , myThid )        _EXCH_XY_RL( visc_streamice , myThid )
125    
126    ! to stop ifort complaining
127            err_init = 0. _d 0
128    
129        if (STREAMICE_chkresidconvergence .or.        if (STREAMICE_chkresidconvergence .or.
130       &    (streamice_maxnliter_cpl.eq.0 .and. myIter.eq.0)) then       &    (streamice_maxnliter_cpl.eq.0 .and. myIter.eq.0)) then
131    
132    
133          CALL STREAMICE_GET_VEL_RESID_ERR ( err_init, myThid )          CALL STREAMICE_GET_VEL_RESID_ERR ( err_init, myThid )
134    
135  #ifdef ALLOW_AUTODIFF_TAMC  #ifdef ALLOW_AUTODIFF_TAMC
# Line 154  C--------------------------------------- Line 153  C---------------------------------------
153    
154        DO iter=1,maxNLIter        DO iter=1,maxNLIter
155    
156    
157  C     To avoid using "exit", loop goes through all iterations  C     To avoid using "exit", loop goes through all iterations
158  C       but after convergence loop does nothing  C       but after convergence loop does nothing
159    
# Line 323  C       but after convergence loop does Line 323  C       but after convergence loop does
323         ENDIF ! (err_max .GT. streamice_nonlin_tol * err_init)         ENDIF ! (err_max .GT. streamice_nonlin_tol * err_init)
324        ENDDO        ENDDO
325    
326  #ifdef ALLOW_PETSC  
 !      call streamice_finalize_petsc (myThidTemp)  
 !      call streamice_finalize_petsc (myThid)  
 #endif  
327    
328  C END NL ITER. LOOP  C END NL ITER. LOOP
329  C-------------------------------------------------------------------  C-------------------------------------------------------------------
330    
331        if (iter_numconv .lt. streamice_max_nl_iter) then        if (iter_numconv .lt. maxnliter) then
332         WRITE(msgBuf,'(A,I5,A)') 'VELOCITY SOLVE CONVERGED, ',         WRITE(msgBuf,'(A,I5,A)') 'VELOCITY SOLVE CONVERGED, ',
333       &         iter_numconv, ' iterations'       &         iter_numconv, ' iterations'
334         CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,         CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,

Legend:
Removed from v.1.9  
changed lines
  Added in v.1.12

  ViewVC Help
Powered by ViewVC 1.1.22