/[MITgcm]/MITgcm/pkg/aim_v23/phy_inphys.F
ViewVC logotype

Annotation of /MITgcm/pkg/aim_v23/phy_inphys.F

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


Revision 1.4 - (hide annotations) (download)
Thu Jun 24 23:43:11 2004 UTC (19 years, 11 months ago) by jmc
Branch: MAIN
CVS Tags: checkpoint57m_post, checkpoint57g_pre, checkpoint57s_post, checkpoint58b_post, checkpoint57b_post, checkpoint57g_post, checkpoint56b_post, checkpoint57y_post, checkpoint65z, checkpoint65x, checkpoint65y, checkpoint54d_post, checkpoint65r, checkpoint65s, checkpoint65p, checkpoint65q, checkpoint65v, checkpoint65w, checkpoint65t, checkpoint65u, checkpoint65j, checkpoint65k, checkpoint65h, checkpoint65i, checkpoint65n, checkpoint54e_post, checkpoint65l, checkpoint65m, checkpoint65b, checkpoint65c, checkpoint65a, checkpoint65f, checkpoint65g, checkpoint65d, checkpoint65e, checkpoint62c, checkpoint57r_post, checkpoint57d_post, checkpoint57i_post, checkpoint59, checkpoint58, checkpoint55, checkpoint54, checkpoint57, checkpoint56, checkpoint58f_post, checkpoint57n_post, checkpoint58d_post, checkpoint58a_post, checkpoint57z_post, checkpoint54f_post, checkpoint62a, checkpoint62g, checkpoint62f, checkpoint62e, checkpoint62d, checkpoint62k, checkpoint62j, checkpoint62i, checkpoint62h, checkpoint62o, checkpoint62n, checkpoint62m, checkpoint62l, checkpoint62s, checkpoint62r, checkpoint62q, checkpoint62p, checkpoint62w, checkpoint62v, checkpoint62u, checkpoint62t, checkpoint62z, checkpoint62y, checkpoint62x, checkpoint58y_post, checkpoint58t_post, checkpoint55i_post, checkpoint58m_post, checkpoint57l_post, checkpoint57t_post, checkpoint55c_post, checkpoint57v_post, checkpoint57f_post, checkpoint64, checkpoint65, checkpoint60, checkpoint61, checkpoint62, checkpoint63, checkpoint57a_post, checkpoint57h_pre, checkpoint66g, checkpoint66f, checkpoint66e, checkpoint66d, checkpoint66c, checkpoint66b, checkpoint66a, checkpoint66o, checkpoint66n, checkpoint66m, checkpoint66l, checkpoint66k, checkpoint66j, checkpoint66i, checkpoint66h, checkpoint54b_post, checkpoint58w_post, checkpoint57h_post, checkpoint57y_pre, checkpoint55g_post, checkpoint58o_post, checkpoint57c_post, checkpoint58p_post, checkpoint58q_post, checkpoint55d_post, checkpoint58e_post, checkpoint54a_pre, checkpoint63p, checkpoint63q, checkpoint63r, checkpoint63s, checkpoint63l, checkpoint63m, checkpoint63n, checkpoint63o, checkpoint63h, checkpoint63i, checkpoint63j, checkpoint63k, checkpoint63d, checkpoint63e, checkpoint63f, checkpoint63g, checkpoint63a, checkpoint63b, checkpoint63c, checkpoint55d_pre, checkpoint57c_pre, checkpoint58r_post, checkpoint55j_post, checkpoint54a_post, checkpoint55h_post, checkpoint58n_post, checkpoint57e_post, checkpoint55b_post, checkpoint65o, checkpoint59q, checkpoint59p, checkpoint59r, checkpoint59e, checkpoint59d, checkpoint59g, checkpoint59f, checkpoint59a, checkpoint55f_post, checkpoint59c, checkpoint59b, checkpoint59m, checkpoint59l, checkpoint59o, checkpoint59n, checkpoint59i, checkpoint59h, checkpoint59k, checkpoint59j, checkpoint53g_post, checkpoint57p_post, checkpint57u_post, checkpoint57q_post, eckpoint57e_pre, checkpoint58k_post, checkpoint62b, checkpoint58v_post, checkpoint56a_post, checkpoint64y, checkpoint64x, checkpoint58l_post, checkpoint64z, checkpoint53f_post, checkpoint64q, checkpoint64p, checkpoint64s, checkpoint64r, checkpoint64u, checkpoint64t, checkpoint64w, checkpoint64v, checkpoint64i, checkpoint64h, checkpoint64k, checkpoint64j, checkpoint64m, checkpoint64l, checkpoint64o, checkpoint64n, checkpoint64a, checkpoint64c, checkpoint64b, checkpoint64e, checkpoint64d, checkpoint64g, checkpoint64f, checkpoint57h_done, checkpoint57j_post, checkpoint57f_pre, checkpoint61f, checkpoint58g_post, checkpoint58x_post, checkpoint61n, checkpoint58h_post, checkpoint56c_post, checkpoint58j_post, checkpoint57a_pre, checkpoint55a_post, checkpoint57o_post, checkpoint61q, checkpoint57k_post, checkpoint61z, checkpoint57w_post, checkpoint61e, checkpoint58i_post, checkpoint57x_post, checkpoint58c_post, checkpoint58u_post, checkpoint58s_post, checkpoint55e_post, checkpoint61g, checkpoint61d, checkpoint54c_post, checkpoint61b, checkpoint61c, checkpoint61a, checkpoint61o, checkpoint61l, checkpoint61m, checkpoint61j, checkpoint61k, checkpoint61h, checkpoint61i, checkpoint61v, checkpoint61w, checkpoint61t, checkpoint61u, checkpoint61r, checkpoint61s, checkpoint61p, checkpoint61x, checkpoint61y, HEAD
Changes since 1.3: +5 -1 lines
- include stability function into surf.Flux derivative relative to Ts
- calculate clear-sky radiation & surface temp. change
- update diagnostics (snap-shot, timeave & diagnostics)

1 jmc 1.4 C $Header: /u/gcmpack/MITgcm/pkg/aim_v23/phy_inphys.F,v 1.3 2004/03/11 14:33:19 jmc Exp $
2 jmc 1.1 C $Name: $
3    
4     #include "AIM_OPTIONS.h"
5    
6     SUBROUTINE INPHYS (HSG, myThid)
7    
8     IMPLICIT NONE
9    
10     C--
11     C-- SUBROUTINE INPHYS (HSG,PPL,RLAT)
12     C--
13     C-- Purpose: Initialize common blocks for physical parametrization routines
14     C-- Input : HSG : sigma at half levels
15     C-- PPL : pressure levels for post-processing
16     C-- RLAT : gaussian-grid latitudes
17     C-- Initialized common blocks: PHYCON, FSIGLT, FORCON,
18     C-- CNVCON, LSCCON, RADCON, SFLCON, VDICON
19     C--
20     C Resolution parameters
21    
22     C-- size for MITgcm & Physics package :
23     #include "AIM_SIZE.h"
24    
25     #include "GRID.h"
26     #include "EEPARAMS.h"
27     #include "PARAMS.h"
28    
29     c #include "AIM_GRID.h"
30    
31     C Physical constants + functions of sigma and latitude
32    
33     #include "com_physcon.h"
34    
35     C Constants for sub-grid-scale physics
36    
37     #include "com_forcon.h"
38     #include "com_cnvcon.h"
39     #include "com_lsccon.h"
40     #include "com_radcon.h"
41     #include "com_sflcon.h"
42     #include "com_vdicon.h"
43    
44     C == Routine Arguments ==
45     INTEGER myThid
46     c REAL HSG(0:NLEV), PPL(NLEV), RLAT(NLAT)
47     _RL HSG(0:NLEV)
48    
49     #ifdef ALLOW_AIM
50    
51     C == Local Variables ==
52     INTEGER K
53    
54     _BEGIN_MASTER(myThid)
55    
56     C--- 1. Time independent parameters and arrays
57     C
58     C 1.1 Physical constants
59    
60     c P0 = 1. _d +5
61     c GG = 9.81 _d 0
62     c RD = 287. _d 0
63     c CP = 1004. _d 0
64 jmc 1.2 P0 = atm_Po
65 jmc 1.1 GG = gravity
66 jmc 1.2 RD = atm_Rd
67     CP = atm_Cp
68 jmc 1.1 C Latent heat is in J/g for consistency with spec.hum. in g/Kg
69     ALHC = 2501. _d 0
70 jmc 1.3 ALHF = 334. _d 0
71 jmc 1.1 SBC = 5.67 _d -8
72 jmc 1.3 C Heat capacity of rain is also in J/g/K for the same reasons
73     c rainCP = HeatCapacity_Cp / 1000. _d 0
74     rainCP = 4200. _d 0 / 1000. _d 0
75     tFreeze= celsius2K
76 jmc 1.1 C
77     C 1.2 Functions of sigma and latitude
78     C
79     SIGH(0)=HSG(0)
80     C
81     DO K=1,NLEV
82     SIG(K) = 0.5*(HSG(K)+HSG(K-1))
83     SIGL(K) = LOG(SIG(K))
84     SIGH(K) = HSG(K)
85     DSIG(K) = HSG(K)-HSG(K-1)
86     c POUT(K) = PPL(K)
87     GRDSIG(K) = GG/(DSIG(K)*P0)
88     GRDSCP(K) = GRDSIG(K)/CP
89     ENDDO
90     C
91     C Weights for vertical interpolation at half-levels(1,nlev) and surface
92     C Note that for phys.par. half-lev(k) is between full-lev k and k+1
93     C Fhalf(k) = Ffull(k)+WVI(K,2)*(Ffull(k+1)-Ffull(k))
94     C Fsurf = Ffull(nlev)+WVI(nlev,2)*(Ffull(nlev)-Ffull(nlev-1))
95     C
96     DO K=1,NLEV-1
97     WVI(K,1)=1./(SIGL(K+1)-SIGL(K))
98     WVI(K,2)=(LOG(SIGH(K))-SIGL(K))*WVI(K,1)
99     ENDDO
100     C
101     WVI(NLEV,1)=0.
102     WVI(NLEV,2)=-SIGL(NLEV)*WVI(NLEV-1,2)
103    
104     c--- jmc: write WVI to check:
105     WRITE(standardMessageUnit,'(A)')
106     & '- INPHYS: k,SIG, SIGH, SIGL, WVI(1), WVI(2):'
107     DO K=1,NLEV
108     WRITE(standardMessageUnit,'(I3,6F9.4)')
109     & k,SIG(k),SIGH(k),SIGL(k),WVI(K,1),WVI(K,2)
110     ENDDO
111     WRITE(standardMessageUnit,'(A)') '- INPHYS: end setup WVI.'
112     c--- jmc.
113    
114     c- jmc: initialize SLAT & CLAT in aim_dyn2aim.F
115     c DO J=1,NLAT
116     c SLAT(J)=SIN(RLAT(J))
117     c CLAT(J)=COS(RLAT(J))
118     c ENDDO
119    
120     C-- 2. Constants for physical parametrization routines:
121    
122     c_FM include "cls_inphys.h"
123     #include "phy_const.h"
124    
125 jmc 1.4 C- pot. temp. increment for computing stability function derivative
126     C note: use the discrete form: F(Ts+dTstab)-F(Ts-dTstab)/2.dTstab
127     dTstab = 1. _d 0
128    
129 jmc 1.1 _END_MASTER(myThid)
130    
131     #endif /* ALLOW_AIM */
132    
133     RETURN
134     END

  ViewVC Help
Powered by ViewVC 1.1.22