1 |
C /u/gcmpack/models/MITgcmUV/model/src/ini_forcing.F,v 1.15 1998/12/15 00:20:34 adcroft Exp |
C $Header$ |
2 |
|
|
3 |
#include "CPP_OPTIONS.h" |
#include "CPP_OPTIONS.h" |
4 |
|
|
|
C I.Fukumori 8/24/98 |
|
|
CStartOfInterface |
|
5 |
SUBROUTINE SWFRAC( |
SUBROUTINE SWFRAC( |
6 |
I imax, fact, z, jwtype, |
I imax, fact, z, |
7 |
O swdk ) |
O swdk ) |
8 |
C /==========================================================\ |
C /==========================================================\ |
9 |
C | SUBROUTINE SWFRAC | |
C | SUBROUTINE SWFRAC | |
23 |
|
|
24 |
IMPLICIT NONE |
IMPLICIT NONE |
25 |
|
|
|
integer nwtype |
|
|
PARAMETER(nwtype=5) ! max number of different water types |
|
|
|
|
26 |
C === Routine arguments === |
C === Routine arguments === |
27 |
|
|
28 |
C input arguments |
C input arguments |
29 |
INTEGER imax ! number of vertical grid points |
C imax number of vertical grid points |
30 |
_RS fact ! scale factor to apply to depth array |
C fact scale factor to apply to depth array |
31 |
_RS z(imax) ! vertical depth for desired sw fraction |
C z vertical depth for desired sw fraction |
32 |
! (fact*z) is negative distance (m) from surface |
C (fact*z) is negative distance (m) from surface |
33 |
INTEGER jwtype ! index for jerlov water type |
C jwtype index for jerlov water type |
34 |
|
|
35 |
|
INTEGER imax |
36 |
|
_RS fact |
37 |
|
_RS z(imax) |
38 |
|
|
39 |
C output arguments |
C output arguments |
40 |
_RS swdk(imax) ! short wave (radiation) fractional decay |
C swdk short wave (radiation) fractional decay |
41 |
|
_RS swdk(imax) |
|
#ifdef ALLOW_KPP |
|
42 |
|
|
43 |
C === Local variables === |
C === Local variables === |
44 |
|
|
45 |
|
C max number of different water types |
46 |
|
integer nwtype |
47 |
|
PARAMETER(nwtype = 5) |
48 |
|
|
49 |
_RS facz |
_RS facz |
50 |
_RS rfac(nwtype),a1(nwtype),a2(nwtype) |
_RL rfac(nwtype),a1(nwtype),a2(nwtype) |
51 |
INTEGER i |
INTEGER i |
52 |
C |
C |
53 |
C Jerlov water type : I IA IB II III |
C Jerlov water type : I IA IB II III |
56 |
DATA rfac / 0.58 , 0.62 , 0.67 , 0.77 , 0.78 / |
DATA rfac / 0.58 , 0.62 , 0.67 , 0.77 , 0.78 / |
57 |
DATA a1 / 0.35 , 0.6 , 1.0 , 1.5 , 1.4 / |
DATA a1 / 0.35 , 0.6 , 1.0 , 1.5 , 1.4 / |
58 |
DATA a2 / 23.0 , 20.0 , 17.0 , 14.0 , 7.9 / |
DATA a2 / 23.0 , 20.0 , 17.0 , 14.0 , 7.9 / |
59 |
|
INTEGER jwtype |
60 |
C |
C |
61 |
|
jwtype=1 |
62 |
DO i = 1,imax |
DO i = 1,imax |
63 |
facz = fact*z(i) |
facz = fact*z(i) |
64 |
IF (facz .LT. (-200.)) THEN |
IF (facz .LT. (-200.)) THEN |
69 |
ENDIF |
ENDIF |
70 |
ENDDO |
ENDDO |
71 |
|
|
|
#endif |
|
|
|
|
72 |
RETURN |
RETURN |
73 |
END |
END |