| 4 |
SUBROUTINE ATM2OCN_MAIN( iloop, aloop, inMonth, |
SUBROUTINE ATM2OCN_MAIN( iloop, aloop, inMonth, |
| 5 |
& myIter, myThid ) |
& myIter, myThid ) |
| 6 |
C *==========================================================* |
C *==========================================================* |
| 7 |
C | Main call after atmos call, calculate ocean/seaice | |
C | Main call after atmos call; calls routine to convert/get | |
| 8 |
c | fluxes | |
C | the atmos fluxes, do ther derivative term calculation, | |
| 9 |
|
C | then add restoring and fixed fluxes, if any. | |
| 10 |
C *==========================================================* |
C *==========================================================* |
| 11 |
IMPLICIT NONE |
IMPLICIT NONE |
| 12 |
|
|
| 19 |
|
|
| 20 |
C !INPUT/OUTPUT PARAMETERS: |
C !INPUT/OUTPUT PARAMETERS: |
| 21 |
C === Routine arguments === |
C === Routine arguments === |
| 22 |
|
C iloop - loop counter for main loop (coupled periods) |
| 23 |
|
C aloop - loop counter for atm time steps (within a coupled per.) |
| 24 |
C inMonth - current month |
C inMonth - current month |
| 25 |
C myThid - Thread no. that called this routine. |
C myThid - Thread no. that called this routine. |
| 26 |
INTEGER iloop |
INTEGER iloop |
| 27 |
INTEGER aloop |
INTEGER aloop |
| 28 |
INTEGER inMonth |
INTEGER inMonth |
| 29 |
INTEGER myIter |
INTEGER myIter |
| 32 |
C LOCAL VARIABLES: |
C LOCAL VARIABLES: |
| 33 |
_RL wght0,wght1 |
_RL wght0,wght1 |
| 34 |
INTEGER intime0,intime1 |
INTEGER intime0,intime1 |
| 35 |
LOGICAL iftime |
LOGICAL iftime ! comes back true if time to do a file re-load |
| 36 |
_RL curTime ! current time (s) of simulation starting from 0.0 |
_RL curTime ! current time (s) of simulation starting from 0.0 |
| 37 |
|
|
| 38 |
curTime = float(iloop-1)*dtcouplo + (float(aloop)-0.5)*dtatmo |
curTime = float(iloop-1)*dtcouplo + (float(aloop)-0.5)*dtatmo |
| 41 |
CALL CALC_FILELOAD( curTime, iloop, aloop, wght0, wght1, |
CALL CALC_FILELOAD( curTime, iloop, aloop, wght0, wght1, |
| 42 |
& intime0, intime1, ifTime, myThid) |
& intime0, intime1, ifTime, myThid) |
| 43 |
|
|
| 44 |
CALL READ_ATMOS(inMonth,myThid) |
CALL READ_ATMOS( inMonth,myThid) |
| 45 |
|
|
| 46 |
IF ( (atmosTauuFile.NE.' ').OR. |
IF ( (atmosTauuFile.NE.' ').OR. |
| 47 |
& (atmosTauvFile.NE.' ').OR.(atmosWindFile.NE.' ')) THEN |
& (atmosTauvFile.NE.' ').OR.(atmosWindFile.NE.' ')) THEN |
| 49 |
& intime0, intime1, myThid) |
& intime0, intime1, myThid) |
| 50 |
ENDIF |
ENDIF |
| 51 |
|
|
| 52 |
CALL CALC_1DTO2D(inMonth,myThid) |
CALL CALC_1DTO2D( myThid) |
| 53 |
|
|
| 54 |
CALL FIXED_FLUX_ADD(wght0,wght1, |
CALL FIXED_FLUX_ADD( wght0,wght1, |
| 55 |
& intime0,intime1,ifTime,myIter,myThid) |
& intime0,intime1,ifTime,myIter,myThid) |
| 56 |
|
|
| 57 |
CALL RELAX_ADD(wght0,wght1, |
CALL RELAX_ADD( wght0,wght1, |
| 58 |
& intime0,intime1,ifTime,myIter,myThid) |
& intime0,intime1,ifTime,myIter,myThid) |
| 59 |
|
|
| 60 |
RETURN |
RETURN |