Back to home page

MITgcm

 
 

    


File indexing completed on 2025-11-07 06:08:44 UTC

view on githubraw file Latest commit b7411f1a on 2025-11-06 19:05:26 UTC
7eca977925 Jean*0001 #include "OCN_CPL_OPTIONS.h"
                0002 
                0003 CBOP
                0004 C     !ROUTINE: OCN_EXPORT_DATA
                0005 
                0006 C     !INTERFACE:
                0007       SUBROUTINE OCN_EXPORT_DATA(
                0008      I                      myTime, myIter, myThid )
                0009 
                0010 C     !DESCRIPTION: \bv
                0011 C     *==========================================================*
                0012 C     | SUBROUTINE OCN_EXPORT_DATA
                0013 C     | o Routine for controlling
                0014 C     |   - export of ocean coupling data to coupler layer
                0015 C     |     but only if using Sequential coupling.
                0016 C     *==========================================================*
                0017 C     | This version talks to the MIT Coupler. It uses the MIT
                0018 C     | Coupler "checkpoint1" library calls.
                0019 C     *==========================================================*
                0020 C     \ev
                0021 
                0022 C     !USES
                0023       IMPLICIT NONE
                0024 C     == GLobal variables ==
                0025 #include "SIZE.h"
                0026 #include "EEPARAMS.h"
                0027 #include "PARAMS.h"
                0028 #include "CPL_PARAMS.h"
                0029 
                0030 C     !INPUT/OUTPUT PARAMETERS:
                0031 C     == Routine arguments ==
                0032 C     myTime  :: Current time in simulation.
                0033 C     myIter  :: Current timestep number.
                0034 C     myThid  :: Thread number for this instance of the routine.
                0035       _RL     myTime
                0036       INTEGER myIter
                0037       INTEGER myThid
                0038 CEOP
                0039 
                0040 #ifdef COMPONENT_MODULE
                0041 C     !LOCAL VARIABLES:
                0042 C     msgBuf  :: Informational/error message buffer
                0043       CHARACTER*(MAX_LEN_MBUF) msgBuf
                0044 
                0045 C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
                0046 C     Note MIT Coupler checkpoint1 does not allow asynchronous posting of
                0047 C     data, so ordering has to be consistent with coupling layer ordering.
                0048 C--------------------------------------------------------------------------
                0049 C     Sequential coupling: Send data to coupling layer
                0050 
                0051       IF ( ocn_cplSequential ) THEN
                0052         IF ( debugMode ) THEN
                0053          _BEGIN_MASTER( myThid )
                0054          WRITE(msgBuf,'(A,I10)')
                0055      &    '  Exporting  oceanic surface fields at iter=', myIter
                0056          CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
                0057      &                       SQUEEZE_RIGHT, myThid )
                0058          _END_MASTER( myThid )
                0059         ENDIF
                0060 
                0061         CALL OCN_STORE_MY_DATA(
                0062      I           myTime, myIter, myThid )
                0063 
4e3940889d Jean*0064         CALL OCN_EXPORT_FIELDS ( myIter, myThid )
7eca977925 Jean*0065 
                0066       ENDIF
                0067 
                0068 #endif /* COMPONENT_MODULE */
                0069 
                0070       RETURN
                0071       END