/[MITgcm]/MITgcm/pkg/seaice/ostres.F
ViewVC logotype

Annotation of /MITgcm/pkg/seaice/ostres.F

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


Revision 1.23 - (hide annotations) (download)
Wed Nov 17 14:58:23 2010 UTC (13 years, 6 months ago) by mlosch
Branch: MAIN
CVS Tags: checkpoint62v, checkpoint62u, checkpoint62t, checkpoint62s, checkpoint62r, checkpoint62q, checkpoint62p, checkpoint62o, checkpoint62w, checkpoint62z, checkpoint62y, checkpoint62x, checkpoint63g, checkpoint63, checkpoint63d, checkpoint63e, checkpoint63f, checkpoint63a, checkpoint63b, checkpoint63c
Changes since 1.22: +1 -47 lines
remove commented lines

1 mlosch 1.23 C $Header: /u/gcmpack/MITgcm/pkg/seaice/ostres.F,v 1.22 2010/10/29 15:26:29 jmc Exp $
2 edhill 1.8 C $Name: $
3 heimbach 1.2
4     #include "SEAICE_OPTIONS.h"
5    
6     CStartOfInterface
7 mlosch 1.17 SUBROUTINE ostres( COR_ICE, myThid )
8 jmc 1.22 C *==========================================================*
9 heimbach 1.2 C | SUBROUTINE ostres |
10     C | o Calculate ocean surface stress |
11 jmc 1.22 C *==========================================================*
12     C *==========================================================*
13 heimbach 1.2 IMPLICIT NONE
14    
15     C === Global variables ===
16     #include "SIZE.h"
17     #include "EEPARAMS.h"
18     #include "PARAMS.h"
19     #include "FFIELDS.h"
20     #include "SEAICE.h"
21     #include "SEAICE_PARAMS.h"
22    
23     C === Routine arguments ===
24     C myThid - Thread no. that called this routine.
25     _RL COR_ICE (1-OLx:sNx+OLx,1-OLy:sNy+OLy, nSx,nSy)
26     INTEGER myThid
27     CEndOfInterface
28    
29 mlosch 1.17 #ifndef SEAICE_CGRID
30 heimbach 1.2 C === Local variables ===
31 dimitri 1.4 C i,j,bi,bj - Loop counters
32 heimbach 1.2
33 dimitri 1.4 INTEGER i, j, bi, bj
34 heimbach 1.2 _RL SINWIN, COSWIN, SINWAT, COSWAT
35 mlosch 1.19 #ifdef SEAICE_BICE_STRESS
36 mlosch 1.14 _RL fuIce, fvIce
37     #endif
38 heimbach 1.2
39 mlosch 1.15 c introduce turning angle (default is zero)
40 mlosch 1.16 SINWIN=SIN(SEAICE_airTurnAngle*deg2rad)
41     COSWIN=COS(SEAICE_airTurnAngle*deg2rad)
42     SINWAT=SIN(SEAICE_waterTurnAngle*deg2rad)
43     COSWAT=COS(SEAICE_waterTurnAngle*deg2rad)
44 heimbach 1.2
45 dimitri 1.3 C-- Update overlap regions
46 dimitri 1.9 CALL EXCH_UV_XY_RL(WINDX, WINDY, .TRUE., myThid)
47 heimbach 1.2
48 dimitri 1.10 #ifndef SEAICE_EXTERNAL_FLUXES
49     C-- Interpolate wind stress (N/m^2) from South-West B-grid
50     C to South-West C-grid for forcing ocean model.
51     DO bj=myByLo(myThid),myByHi(myThid)
52     DO bi=myBxLo(myThid),myBxHi(myThid)
53     DO j=1,sNy
54     DO i=1,sNx
55 dimitri 1.7 fu(I,J,bi,bj)=HALF
56     & *(WINDX(I,J+1,bi,bj)+WINDX(I,J,bi,bj))
57     fv(I,J,bi,bj)=HALF
58     & *(WINDY(I+1,J,bi,bj)+WINDY(I,J,bi,bj))
59 heimbach 1.2 ENDDO
60     ENDDO
61     ENDDO
62     ENDDO
63 dimitri 1.9 CALL EXCH_UV_XY_RS(fu, fv, .TRUE., myThid)
64 dimitri 1.10 #endif /* ifndef SEAICE_EXTERNAL_FLUXES */
65 heimbach 1.2
66 mlosch 1.19 #ifdef SEAICE_BICE_STRESS
67 dimitri 1.11 C-- Compute ice-affected wind stress
68 dimitri 1.12 DO bj=myByLo(myThid),myByHi(myThid)
69     DO bi=myBxLo(myThid),myBxHi(myThid)
70     DO j=1,sNy
71     DO i=1,sNx
72 mlosch 1.16 fuIce=QUART*( DWATN(I,J,bi,bj)+DWATN(I,J+1,bi,bj) )*(
73 jmc 1.22 & COSWAT *
74 mlosch 1.21 & ( UICE(I,J, bi,bj)-GWATX(I,J, bi,bj)
75     & + UICE(I,J+1,bi,bj)-GWATX(I,J+1,bi,bj) )
76 mlosch 1.18 & -SIGN(SINWAT,COR_ICE(I,J,bi,bj)) *
77 mlosch 1.21 & ( VICE(I, J,bi,bj)-GWATY(I, J,bi,bj)
78     & + VICE(I+1,J,bi,bj)-GWATY(I+1,J,bi,bj) )
79 mlosch 1.16 & )
80     fvIce=QUART*( DWATN(I,J,bi,bj)+DWATN(I+1,J,bi,bj) )*(
81 jmc 1.22 & SIGN(SINWAT,COR_ICE(I,J,bi,bj)) *
82 mlosch 1.21 & ( UICE(I,J, bi,bj)-GWATX(I,J, bi,bj)
83     & + UICE(I,J+1,bi,bj)-GWATX(I,J+1,bi,bj) )
84 jmc 1.22 & + COSWAT *
85     & ( VICE(I, J,bi,bj)-GWATY(I, J,bi,bj)
86 mlosch 1.21 & + VICE(I+1,J,bi,bj)-GWATY(I+1,J,bi,bj) )
87 mlosch 1.16 & )
88 mlosch 1.21 fu(I,J,bi,bj)=(ONE-AREA(I,J,bi,bj))*fu(I,J,bi,bj)+
89     & AREA(I,J,bi,bj)*fuIce
90     fv(I,J,bi,bj)=(ONE-AREA(I,J,bi,bj))*fv(I,J,bi,bj)+
91     & AREA(I,J,bi,bj)*fvIce
92 dimitri 1.11 ENDDO
93     ENDDO
94     ENDDO
95 dimitri 1.12 ENDDO
96 dimitri 1.11 CALL EXCH_UV_XY_RS(fu, fv, .TRUE., myThid)
97 mlosch 1.19 #endif /* SEAICE_BICE_STRESS */
98 mlosch 1.17 #endif /* not SEAICE_CGRID */
99 dimitri 1.11
100 heimbach 1.2 RETURN
101     END

  ViewVC Help
Powered by ViewVC 1.1.22