Back to home page

MITgcm

 
 

    


File indexing completed on 2018-03-02 18:37:28 UTC

view on githubraw file Latest commit add29e06 on 2018-01-31 20:35:05 UTC
09a6f3668a Jeff*0001 #include "ctrparam.h"
                0002 #include "ATM2D_OPTIONS.h"
                0003 C     !INTERFACE:
                0004       SUBROUTINE ATM2OCN_MAIN( iloop, aloop, inMonth,
                0005      &                                 myIter, myThid )
                0006 C     *==========================================================*
                0007 C     | Main call after atmos call; calls routine to convert/get |
                0008 C     | the atmos fluxes, do ther derivative term calculation,   |
                0009 C     | then add restoring and fixed fluxes, if any.             |
                0010 C     *==========================================================*
                0011         IMPLICIT NONE
                0012 
                0013 C     === Global Atmos/Ocean/Seaice Interface Variables ===
                0014 #include "ATMSIZE.h"
                0015 #include "SIZE.h"
                0016 #include "EEPARAMS.h"
                0017 #include "ATM2D_VARS.h"
                0018 
                0019 
                0020 C     !INPUT/OUTPUT PARAMETERS:
                0021 C     === Routine arguments ===
                0022 C     iloop - loop counter for main loop (coupled periods)
                0023 C     aloop - loop counter for atm time steps (within a coupled per.)
                0024 C     inMonth - current month
                0025 C     myThid - Thread no. that called this routine.
9274434acc Jean*0026       INTEGER iloop
09a6f3668a Jeff*0027       INTEGER aloop
                0028       INTEGER inMonth
                0029       INTEGER myIter
                0030       INTEGER myThid
                0031 
                0032 C     LOCAL VARIABLES:
                0033       _RL wght0,wght1
                0034       INTEGER intime0,intime1
                0035       LOGICAL iftime ! comes back true if time to do a file re-load
                0036       _RL  curTime   ! current time (s) of simulation starting from 0.0
                0037 
                0038       curTime = float(iloop-1)*dtcouplo + (float(aloop)-0.5)*dtatmo
                0039 
                0040       PRINT *,'Executing atm2ocn main',curTime
                0041       CALL CALC_FILELOAD( curTime, iloop, aloop, wght0, wght1,
                0042      &                    intime0, intime1, ifTime, myThid)
                0043 
                0044       CALL READ_ATMOS( inMonth,myThid)
                0045 
                0046       IF ( (atmosTauuFile.NE.' ').OR.
9274434acc Jean*0047      &   (atmosTauvFile.NE.' ').OR.(atmosWindFile.NE.' ')) THEN
09a6f3668a Jeff*0048         CALL SUBTRACT_MEANS( wght0, wght1,
                0049      &                       intime0, intime1, myThid)
                0050       ENDIF
                0051 
                0052       CALL CALC_1DTO2D( myThid)
                0053 
7ad882c4ff Jeff*0054       CALL FIXED_FLUX_ADD( inMonth, wght0,wght1,
09a6f3668a Jeff*0055      &              intime0,intime1,ifTime,myIter,myThid)
                0056 
                0057       CALL RELAX_ADD( wght0,wght1,
                0058      &              intime0,intime1,ifTime,myIter,myThid)
9274434acc Jean*0059 
09a6f3668a Jeff*0060       RETURN
                0061       END