39 REAL,
PARAMETER,
PUBLIC ::
kwvb=6.28e-5
41 REAL,
PARAMETER,
PUBLIC ::
kwvbeq=6.28e-5/7.
43 REAL,
PARAMETER,
PUBLIC ::
kwvo=6.28e-5
47 REAL,
PARAMETER,
PUBLIC ::
mxasym=0.1
51 REAL,
PARAMETER,
PUBLIC ::
n2min=1.e-8
53 REAL,
PARAMETER,
PUBLIC ::
fcrit2=0.5
61 REAL,
PARAMETER,
PUBLIC ::
taumin=1.e-10
65 REAL,
PARAMETER,
PUBLIC ::
tndmax=500./86400.
67 REAL,
PARAMETER,
PUBLIC ::
umcfac=0.5
76 REAL,
PARAMETER,
PUBLIC ::
pi_gwd=4.0*atan(1.0)
79 SUBROUTINE gw_main_d(pcols, pver, dt, pgwv, effgworo_dev, &
80 & effgwbkg_dev, pint_dev, t_dev, u_dev, u_devd, v_dev, v_devd, &
81 & sgh_dev, pref_dev, pmid_dev, pdel_dev, rpdel_dev, lnpint_dev, zm_dev, &
82 & qvt_dev, rog, mapl_vireps_, rlat_dev)
97 REAL :: effgwbkg_dev(pcols)
99 REAL :: effgworo_dev(pcols)
101 REAL :: pint_dev(pcols, pver+1)
103 REAL :: t_dev(pcols, pver)
105 REAL :: u_dev(pcols, pver)
106 REAL :: u_devd(pcols, pver)
108 REAL :: v_dev(pcols, pver)
109 REAL :: v_devd(pcols, pver)
111 REAL :: sgh_dev(pcols)
113 REAL :: pref_dev(pver+1)
115 REAL :: pmid_dev(pcols, pver)
117 REAL :: pdel_dev(pcols, pver)
119 REAL :: rpdel_dev(pcols, pver)
121 REAL :: lnpint_dev(pcols, pver+1)
123 REAL :: zm_dev(pcols, pver)
125 REAL :: zi_dev(pcols, pver+1)
127 REAL :: qvt_dev(pcols, pver)
129 REAL :: rlat_dev(pcols)
131 REAL :: dudt_gwd_dev(pcols, pver)
132 REAL :: dudt_gwd_devd(pcols, pver)
134 REAL :: dvdt_gwd_dev(pcols, pver)
135 REAL :: dvdt_gwd_devd(pcols, pver)
137 REAL :: dtdt_gwd_dev(pcols, pver)
138 REAL :: dtdt_gwd_devd(pcols, pver)
140 REAL :: dudt_org_dev(pcols, pver)
142 REAL :: dvdt_org_dev(pcols, pver)
144 REAL :: dtdt_org_dev(pcols, pver)
146 REAL :: taugwdx_dev(pcols)
148 REAL :: taugwdy_dev(pcols)
150 REAL :: tauox_dev(pcols, pver+1)
152 REAL :: tauoy_dev(pcols, pver+1)
154 REAL :: feo_dev(pcols, pver+1)
156 REAL :: fepo_dev(pcols, pver+1)
158 REAL :: taubkgx_dev(pcols)
160 REAL :: taubkgy_dev(pcols)
162 REAL :: taubx_dev(pcols, pver+1)
164 REAL :: tauby_dev(pcols, pver+1)
166 REAL :: feb_dev(pcols, pver+1)
168 REAL :: fepb_dev(pcols, pver+1)
170 REAL :: utbsrc_dev(pcols, pver)
172 REAL :: vtbsrc_dev(pcols, pver)
174 REAL :: ttbsrc_dev(pcols, pver)
183 INTEGER :: ktopbg, ktoporo
224 REAL :: alpha(0:pver)
226 REAL :: dback(0:pver)
228 REAL :: c(-pgwv:pgwv)
230 REAL :: att_dev(pcols, pver)
231 REAL :: att_devd(pcols, pver)
236 REAL :: hkl, hkk, tvfac, tv,
rog 250 att_dev(i, k) = t_dev(i, k)*pwr10*pwr20
254 zi_dev(i, pver+1) = 0.
256 hkl = lnpint_dev(i, k+1) - lnpint_dev(i, k)
257 hkk = 1. - pint_dev(i, k)*hkl*rpdel_dev(i, k)
258 tvfac = 1. + mapl_vireps_*qvt_dev(i, k)
259 tv = att_dev(i, k)*tvfac
260 zm_dev(i, k) = zi_dev(i, k+1) +
rog*tv*hkk
261 zi_dev(i, k) = zi_dev(i, k+1) +
rog*tv*hkl
273 CALL gw_intr_d(i, pcols, pver, dt, pgwv, effgworo_dev, effgwbkg_dev&
274 & , pint_dev, att_dev, u_dev, u_devd, v_dev, v_devd&
275 & , sgh_dev, pref_dev, pmid_dev, pdel_dev, rpdel_dev, &
276 & lnpint_dev, zm_dev, rlat_dev, dudt_gwd_dev, dudt_gwd_devd, &
277 & dvdt_gwd_dev, dvdt_gwd_devd, dtdt_gwd_dev, &
278 & dudt_org_dev, dvdt_org_dev, dtdt_org_dev, taugwdx_dev, &
279 & taugwdy_dev, tauox_dev, tauoy_dev, feo_dev, taubkgx_dev, &
280 & taubkgy_dev, taubx_dev, tauby_dev, feb_dev, fepo_dev, &
281 & fepb_dev, utbsrc_dev, vtbsrc_dev, ttbsrc_dev)
294 CALL gw_intr_d(i, pcols, pver, dt, pgwv, effgworo_dev, effgwbkg_dev&
295 & , pint_dev, att_dev, u_dev, u_devd, v_dev, v_devd&
296 & , sgh_dev, pref_dev, pmid_dev, pdel_dev, rpdel_dev, &
297 & lnpint_dev, zm_dev, rlat_dev, dudt_gwd_dev, dudt_gwd_devd, &
298 & dvdt_gwd_dev, dvdt_gwd_devd, dtdt_gwd_dev, &
299 & dudt_org_dev, dvdt_org_dev, dtdt_org_dev, taugwdx_dev, &
300 & taugwdy_dev, tauox_dev, tauoy_dev, feo_dev, taubkgx_dev, &
301 & taubkgy_dev, taubx_dev, tauby_dev, feb_dev, fepo_dev, &
302 & fepb_dev, utbsrc_dev, vtbsrc_dev, ttbsrc_dev)
312 t_dev(i, k) = att_dev(i, k)/pwr10/pwr20
317 SUBROUTINE gw_intr_d(i, pcols, pver, dt, pgwv, effgworo_dev, &
318 & effgwbkg_dev, pint_dev, t_dev, u_dev, u_devd, v_dev, v_devd, sgh_dev&
319 & , pref_dev, pmid_dev, pdel_dev, rpdel_dev, lnpint_dev, zm_dev, &
320 & rlat_dev, dudt_gwd_dev, dudt_gwd_devd, dvdt_gwd_dev, dvdt_gwd_devd, &
321 & dtdt_gwd_dev, dudt_org_dev, dvdt_org_dev, dtdt_org_dev, taugwdx_dev&
322 & , taugwdy_dev, tauox_dev, tauoy_dev, feo_dev, taubkgx_dev, &
323 & taubkgy_dev, taubx_dev, tauby_dev, feb_dev, fepo_dev, fepb_dev, &
324 & utbsrc_dev, vtbsrc_dev, ttbsrc_dev)
331 INTEGER,
INTENT(IN) :: pcols
333 INTEGER,
INTENT(IN) :: pver
335 REAL,
INTENT(IN) :: dt
337 INTEGER,
INTENT(IN) :: pgwv
339 REAL :: effgwbkg_dev(pcols)
341 REAL :: effgworo_dev(pcols)
343 REAL :: pint_dev(pcols, pver+1)
345 REAL :: t_dev(pcols, pver)
347 REAL :: u_dev(pcols, pver)
348 REAL :: u_devd(pcols, pver)
350 REAL :: v_dev(pcols, pver)
351 REAL :: v_devd(pcols, pver)
353 REAL :: sgh_dev(pcols)
355 REAL :: pref_dev(pver+1)
357 REAL :: pmid_dev(pcols, pver)
359 REAL :: pdel_dev(pcols, pver)
361 REAL :: rpdel_dev(pcols, pver)
363 REAL :: lnpint_dev(pcols, pver+1)
365 REAL :: zm_dev(pcols, pver)
367 REAL :: rlat_dev(pcols)
369 REAL :: dudt_gwd_dev(pcols, pver)
370 REAL :: dudt_gwd_devd(pcols, pver)
372 REAL :: dvdt_gwd_dev(pcols, pver)
373 REAL :: dvdt_gwd_devd(pcols, pver)
375 REAL :: dtdt_gwd_dev(pcols, pver)
377 REAL :: dudt_org_dev(pcols, pver)
379 REAL :: dvdt_org_dev(pcols, pver)
381 REAL :: dtdt_org_dev(pcols, pver)
383 REAL :: taugwdx_dev(pcols)
385 REAL :: taugwdy_dev(pcols)
387 REAL :: tauox_dev(pcols, pver+1)
389 REAL :: tauoy_dev(pcols, pver+1)
391 REAL :: feo_dev(pcols, pver+1)
393 REAL :: fepo_dev(pcols, pver+1)
395 REAL :: taubkgx_dev(pcols)
397 REAL :: taubkgy_dev(pcols)
399 REAL :: taubx_dev(pcols, pver+1)
401 REAL :: tauby_dev(pcols, pver+1)
403 REAL :: feb_dev(pcols, pver+1)
405 REAL :: fepb_dev(pcols, pver+1)
407 REAL :: utbsrc_dev(pcols, pver)
409 REAL :: vtbsrc_dev(pcols, pver)
411 REAL :: ttbsrc_dev(pcols, pver)
414 INTEGER :: i, ii, k, kc
420 INTEGER :: ktopbg, ktoporo
464 REAL :: utosrcd(pver)
466 REAL :: vtosrcd(pver)
469 REAL :: alpha(0:pver)
471 REAL :: dback(0:pver)
473 REAL :: c(-pgwv:pgwv)
474 REAL :: cd(-pgwv:pgwv)
476 REAL :: tau(-pgwv:pgwv, 0:pver)
477 REAL :: taud(-pgwv:pgwv, 0:pver)
496 IF (pref_dev(k+1) .LT.
p_src) kbotbg = k
501 CALL gw_prof(i, k, pcols, pver, u_dev, v_dev, t_dev, pmid_dev, &
502 & pint_dev, rhoi, ni, ti, nm)
507 IF (pgwv .GT. 0 .AND.
do_bgnd)
THEN 509 CALL gw_bgnd_d(i, pcols, pver, c, u_dev, u_devd, v_dev, v_devd, &
510 & t_dev, pmid_dev, pint_dev, pdel_dev, rpdel_dev, &
511 & lnpint_dev, rlat_dev, kldv, kldvmn, ksrc, ksrcmn, rdpldv&
512 & , tau, ubi, ubid, ubm, ubmd, xv, xvd, yv, yvd, pgwv, &
516 & ktopbg, c, u_dev, v_dev, t_dev, pint_dev, &
517 & pdel_dev, rpdel_dev, lnpint_dev, rlat_dev, rhoi&
518 & , ni, ti, nm, dt, alpha, dback, kldv, kldvmn, &
519 & ksrc, ksrcmn, rdpldv, tau, taud, ubi, ubid, ubm&
520 & , xv, xvd, yv, yvd, utgw, utgwd, vtgw, vtgwd, &
521 & ttgw, taubx_dev, tauby_dev, feb_dev, fepb_dev, &
522 & utosrc, utosrcd, vtosrc, vtosrcd, ttosrc, tau0x&
523 & , tau0y, effgwbkg_dev)
526 dudt_gwd_devd(i, k) = utgwd(k) + utosrcd(k)
527 dudt_gwd_dev(i, k) = utgw(k) + utosrc(k)
528 dvdt_gwd_devd(i, k) = vtgwd(k) + vtosrcd(k)
529 dvdt_gwd_dev(i, k) = vtgw(k) + vtosrc(k)
534 dudt_gwd_devd(i, k) = 0.0_8
535 dudt_gwd_dev(i, k) = 0.
536 dvdt_gwd_devd(i, k) = 0.0_8
537 dvdt_gwd_dev(i, k) = 0.
551 CALL gw_oro_d(i, pcols, pver, pgwv, u_dev, u_devd, v_dev, v_devd, &
552 & t_dev, sgh_dev, pmid_dev, pint_dev, pdel_dev, zm_dev, nm, &
553 & kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, taud, ubi, ubid, &
554 & ubm, ubmd, xv, xvd, yv, yvd, kbotoro, rlat_dev)
556 CALL gw_drag_prof_d(i, pcols, pver, pgwv, 0, kbotoro, ktoporo, c, &
557 & u_dev, v_dev, t_dev, pint_dev, pdel_dev, rpdel_dev, &
558 & lnpint_dev, rlat_dev, rhoi, ni, ti, nm, dt, alpha, &
559 & dback, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, taud&
560 & , ubi, ubid, ubm, xv, xvd, yv, yvd, utgw, utgwd, &
561 & vtgw, vtgwd, ttgw, tauox_dev, tauoy_dev, feo_dev, &
562 & fepo_dev, utosrc, vtosrc, ttosrc, tau0x, tau0y, &
567 dudt_gwd_devd(i, k) = dudt_gwd_devd(i, k) + utgwd(k)
568 dudt_gwd_dev(i, k) = dudt_gwd_dev(i, k) + utgw(k)
569 dvdt_gwd_devd(i, k) = dvdt_gwd_devd(i, k) + vtgwd(k)
570 dvdt_gwd_dev(i, k) = dvdt_gwd_dev(i, k) + vtgw(k)
575 u_devd(i, k) = u_devd(i, k) + dt*dudt_gwd_devd(i, k)
576 u_dev(i, k) = u_dev(i, k) + dudt_gwd_dev(i, k)*dt
577 v_devd(i, k) = v_devd(i, k) + dt*dvdt_gwd_devd(i, k)
578 v_dev(i, k) = v_dev(i, k) + dvdt_gwd_dev(i, k)*dt
583 SUBROUTINE gw_intr(i, pcols, pver, dt, pgwv, effgworo_dev, &
584 & effgwbkg_dev, pint_dev, t_dev, u_dev, v_dev, sgh_dev, pref_dev, &
585 & pmid_dev, pdel_dev, rpdel_dev, lnpint_dev, zm_dev, rlat_dev, &
586 & dudt_gwd_dev, dvdt_gwd_dev, dtdt_gwd_dev, dudt_org_dev, dvdt_org_dev&
587 & , dtdt_org_dev, taugwdx_dev, taugwdy_dev, tauox_dev, tauoy_dev, &
588 & feo_dev, taubkgx_dev, taubkgy_dev, taubx_dev, tauby_dev, feb_dev, &
589 & fepo_dev, fepb_dev, utbsrc_dev, vtbsrc_dev, ttbsrc_dev)
596 INTEGER,
INTENT(IN) :: pcols
598 INTEGER,
INTENT(IN) :: pver
600 REAL,
INTENT(IN) :: dt
602 INTEGER,
INTENT(IN) :: pgwv
604 REAL :: effgwbkg_dev(pcols)
606 REAL :: effgworo_dev(pcols)
608 REAL :: pint_dev(pcols, pver+1)
610 REAL :: t_dev(pcols, pver)
612 REAL :: u_dev(pcols, pver)
614 REAL :: v_dev(pcols, pver)
616 REAL :: sgh_dev(pcols)
618 REAL :: pref_dev(pver+1)
620 REAL :: pmid_dev(pcols, pver)
622 REAL :: pdel_dev(pcols, pver)
624 REAL :: rpdel_dev(pcols, pver)
626 REAL :: lnpint_dev(pcols, pver+1)
628 REAL :: zm_dev(pcols, pver)
630 REAL :: rlat_dev(pcols)
632 REAL :: dudt_gwd_dev(pcols, pver)
634 REAL :: dvdt_gwd_dev(pcols, pver)
636 REAL :: dtdt_gwd_dev(pcols, pver)
638 REAL :: dudt_org_dev(pcols, pver)
640 REAL :: dvdt_org_dev(pcols, pver)
642 REAL :: dtdt_org_dev(pcols, pver)
644 REAL :: taugwdx_dev(pcols)
646 REAL :: taugwdy_dev(pcols)
648 REAL :: tauox_dev(pcols, pver+1)
650 REAL :: tauoy_dev(pcols, pver+1)
652 REAL :: feo_dev(pcols, pver+1)
654 REAL :: fepo_dev(pcols, pver+1)
656 REAL :: taubkgx_dev(pcols)
658 REAL :: taubkgy_dev(pcols)
660 REAL :: taubx_dev(pcols, pver+1)
662 REAL :: tauby_dev(pcols, pver+1)
664 REAL :: feb_dev(pcols, pver+1)
666 REAL :: fepb_dev(pcols, pver+1)
668 REAL :: utbsrc_dev(pcols, pver)
670 REAL :: vtbsrc_dev(pcols, pver)
672 REAL :: ttbsrc_dev(pcols, pver)
675 INTEGER :: i, ii, k, kc
681 INTEGER :: ktopbg, ktoporo
722 REAL :: alpha(0:pver)
724 REAL :: dback(0:pver)
726 REAL :: c(-pgwv:pgwv)
728 REAL :: tau(-pgwv:pgwv, 0:pver)
746 IF (pref_dev(k+1) .LT.
p_src) kbotbg = k
751 CALL gw_prof(i, k, pcols, pver, u_dev, v_dev, t_dev, pmid_dev, &
752 & pint_dev, rhoi, ni, ti, nm)
757 IF (pgwv .GT. 0 .AND.
do_bgnd)
THEN 759 CALL gw_bgnd(i, pcols, pver, c, u_dev, v_dev, t_dev, pmid_dev, &
760 & pint_dev, pdel_dev, rpdel_dev, lnpint_dev, rlat_dev, kldv, &
761 & kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, pgwv, &
765 & , c, u_dev, v_dev, t_dev, pint_dev, pdel_dev, &
766 & rpdel_dev, lnpint_dev, rlat_dev, rhoi, ni, ti, nm&
767 & , dt, alpha, dback, kldv, kldvmn, ksrc, ksrcmn, &
768 & rdpldv, tau, ubi, ubm, xv, yv, utgw, vtgw, ttgw, &
769 & taubx_dev, tauby_dev, feb_dev, fepb_dev, utosrc, &
770 & vtosrc, ttosrc, tau0x, tau0y, effgwbkg_dev)
773 dudt_gwd_dev(i, k) = utgw(k) + utosrc(k)
774 dvdt_gwd_dev(i, k) = vtgw(k) + vtosrc(k)
782 dudt_gwd_dev(i, k) = 0.
783 dvdt_gwd_dev(i, k) = 0.
792 CALL gw_oro(i, pcols, pver, pgwv, u_dev, v_dev, t_dev, sgh_dev, &
793 & pmid_dev, pint_dev, pdel_dev, zm_dev, nm, kldv, kldvmn, ksrc&
794 & , ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, kbotoro, rlat_dev)
796 CALL gw_drag_prof(i, pcols, pver, pgwv, 0, kbotoro, ktoporo, c, &
797 & u_dev, v_dev, t_dev, pint_dev, pdel_dev, rpdel_dev, &
798 & lnpint_dev, rlat_dev, rhoi, ni, ti, nm, dt, alpha, &
799 & dback, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, &
800 & ubm, xv, yv, utgw, vtgw, ttgw, tauox_dev, tauoy_dev, &
801 & feo_dev, fepo_dev, utosrc, vtosrc, ttosrc, tau0x, &
802 & tau0y, effgworo_dev)
806 dudt_gwd_dev(i, k) = dudt_gwd_dev(i, k) + utgw(k)
807 dvdt_gwd_dev(i, k) = dvdt_gwd_dev(i, k) + vtgw(k)
812 u_dev(i, k) = u_dev(i, k) + dudt_gwd_dev(i, k)*dt
813 v_dev(i, k) = v_dev(i, k) + dvdt_gwd_dev(i, k)*dt
819 SUBROUTINE gw_prof(i, k, pcols, pver, u, v, t, pm, pi, rhoi, ni, ti, &
831 INTEGER,
INTENT(IN) :: i
833 INTEGER,
INTENT(IN) :: k
835 INTEGER,
INTENT(IN) :: pcols
837 INTEGER,
INTENT(IN) :: pver
839 REAL :: u(pcols, pver)
841 REAL :: v(pcols, pver)
843 REAL :: t(pcols, pver)
845 REAL :: pm(pcols, pver)
847 REAL :: pi(pcols, 0:pver)
861 REAL :: t_new, t_new_
878 ELSE IF (k .GT. 0 .AND. k .LT. pver)
THEN 879 ti(k) = 0.5*(t(i, k)+t(i, k+1))
882 dtdp = (t(i, k+1)-t(i, k))/(pm(i, k+1)-pm(i, k))
885 IF (
n2min .LT. n2)
THEN 893 ELSE IF (k .EQ. pver)
THEN 902 IF (k .GT. 0) nm(k) = 0.5*(ni(k-1)+ni(k))
909 SUBROUTINE gw_oro_d(i, pcols, pver, pgwv, u, ud, v, vd, t, sgh, pm, pi&
910 & , dpm, zm, nm, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, taud, ubi, &
911 & ubid, ubm, ubmd, xv, xvd, yv, yvd, kbot, rlat)
921 INTEGER,
INTENT(IN) :: i
923 INTEGER,
INTENT(IN) :: pcols
925 INTEGER,
INTENT(IN) :: pver
927 INTEGER,
INTENT(IN) :: pgwv
929 REAL :: u(pcols, pver)
930 REAL :: ud(pcols, pver)
932 REAL :: v(pcols, pver)
933 REAL :: vd(pcols, pver)
935 REAL :: t(pcols, pver)
939 REAL :: pm(pcols, pver)
941 REAL :: pi(pcols, 0:pver)
943 REAL :: dpm(pcols, pver)
945 REAL :: zm(pcols, pver)
959 REAL :: tau(-pgwv:pgwv, 0:pver)
960 REAL :: taud(-pgwv:pgwv, 0:pver)
1002 REAL :: u_new, v_new, t_new
1003 REAL :: u_newd, v_newd
1026 psrc = pi(i, pver-1)
1027 CALL get_ti(t_new, t(i, pver))
1028 rsrc = pm(i, pver)/(
mapl_rgas*t_new)*dpm(i, pver)
1029 CALL get_uv_d(u_new, u_newd, u(i, pver), ud(i, pver))
1030 CALL get_uv_d(v_new, v_newd, v(i, pver), vd(i, pver))
1031 usrcd = dpm(i, pver)*u_newd
1032 usrc = u_new*dpm(i, pver)
1033 vsrcd = dpm(i, pver)*v_newd
1034 vsrc = v_new*dpm(i, pver)
1035 nsrc = nm(pver)*dpm(i, pver)
1037 DO k=pver-1,pver/2,-1
1038 arg1 = zm(i, k)*zm(i, k+1)
1039 result1 = sqrt(arg1)
1040 IF (hdsp .GT. result1)
THEN 1044 CALL get_ti(t_new, t(i, k))
1045 rsrc = rsrc + pm(i, k)/(
mapl_rgas*t_new)*dpm(i, k)
1046 CALL get_uv_d(u_new, u_newd, u(i, k), ud(i, k))
1047 CALL get_uv_d(v_new, v_newd, v(i, k), vd(i, k))
1048 usrcd = usrcd + dpm(i, k)*u_newd
1049 usrc = usrc + u_new*dpm(i, k)
1050 vsrcd = vsrcd + dpm(i, k)*v_newd
1051 vsrc = vsrc + v_new*dpm(i, k)
1052 nsrc = nsrc + nm(k)*dpm(i, k)
1055 rsrc = rsrc/(pi(i, pver)-psrc)
1056 usrcd = usrcd/(pi(i, pver)-psrc)
1057 usrc = usrc/(pi(i, pver)-psrc)
1058 vsrcd = vsrcd/(pi(i, pver)-psrc)
1059 vsrc = vsrc/(pi(i, pver)-psrc)
1060 nsrc = nsrc/(pi(i, pver)-psrc)
1061 IF (usrc .EQ. 0. .AND. vsrc .EQ. 0.)
THEN 1069 arg1d = 2*usrc*usrcd + 2*vsrc*vsrcd
1070 arg1 = usrc**2 + vsrc**2
1071 IF (arg1 .EQ. 0.0)
THEN 1074 ubsrcd = arg1d/(2.0*sqrt(arg1))
1077 xvd = (usrcd*ubsrc-usrc*ubsrcd)/ubsrc**2
1079 yvd = (vsrcd*ubsrc-vsrc*ubsrcd)/ubsrc**2
1084 ubmd(k) = ud(i, k)*xv + u(i, k)*xvd + vd(i, k)*yv + v(i, k)*yvd
1085 ubm(k) = u(i, k)*xv + v(i, k)*yv
1098 sghmaxd =
fcrit2*2*ubsrc*ubsrcd/nsrc**2
1099 sghmax =
fcrit2*(ubsrc/nsrc)**2
1100 IF (hdsp**2 .GT. sghmax)
THEN 1107 tauorod =
oroko2*rsrc*nsrc*(min1d*ubsrc+min1*ubsrcd)
1108 tauoro =
oroko2*min1*rsrc*nsrc*ubsrc
1125 IF (ubi(kbot) .LT. 0. .OR. ubm(kbot) .LT. 0.)
THEN 1136 taud(0, kbot) = tauorod
1137 tau(0, kbot) = tauoro
1143 IF (ksrcmn .GT. ksrc)
THEN 1148 IF (kldvmn .GT. kldv)
THEN 1153 IF (kldv .NE. pver) rdpldv = 1./(pi(i, kldv)-pi(i, pver))
1155 IF (
fracldv .LE. 0.) kldvmn = pver
1159 SUBROUTINE gw_oro(i, pcols, pver, pgwv, u, v, t, sgh, pm, pi, dpm, zm&
1160 & , nm, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, &
1171 INTEGER,
INTENT(IN) :: i
1173 INTEGER,
INTENT(IN) :: pcols
1175 INTEGER,
INTENT(IN) :: pver
1177 INTEGER,
INTENT(IN) :: pgwv
1179 REAL :: u(pcols, pver)
1181 REAL :: v(pcols, pver)
1183 REAL :: t(pcols, pver)
1187 REAL :: pm(pcols, pver)
1189 REAL :: pi(pcols, 0:pver)
1191 REAL :: dpm(pcols, pver)
1193 REAL :: zm(pcols, pver)
1207 REAL :: tau(-pgwv:pgwv, 0:pver)
1240 REAL :: u_new, v_new, t_new
1261 psrc = pi(i, pver-1)
1262 CALL get_ti(t_new, t(i, pver))
1263 rsrc = pm(i, pver)/(
mapl_rgas*t_new)*dpm(i, pver)
1264 CALL get_uv(u_new, u(i, pver))
1265 CALL get_uv(v_new, v(i, pver))
1266 usrc = u_new*dpm(i, pver)
1267 vsrc = v_new*dpm(i, pver)
1268 nsrc = nm(pver)*dpm(i, pver)
1270 DO k=pver-1,pver/2,-1
1271 arg1 = zm(i, k)*zm(i, k+1)
1272 result1 = sqrt(arg1)
1273 IF (hdsp .GT. result1)
THEN 1277 CALL get_ti(t_new, t(i, k))
1278 rsrc = rsrc + pm(i, k)/(
mapl_rgas*t_new)*dpm(i, k)
1279 CALL get_uv(u_new, u(i, k))
1280 CALL get_uv(v_new, v(i, k))
1281 usrc = usrc + u_new*dpm(i, k)
1282 vsrc = vsrc + v_new*dpm(i, k)
1283 nsrc = nsrc + nm(k)*dpm(i, k)
1286 rsrc = rsrc/(pi(i, pver)-psrc)
1287 usrc = usrc/(pi(i, pver)-psrc)
1288 vsrc = vsrc/(pi(i, pver)-psrc)
1289 nsrc = nsrc/(pi(i, pver)-psrc)
1290 IF (usrc .EQ. 0. .AND. vsrc .EQ. 0.)
THEN 1295 arg1 = usrc**2 + vsrc**2
1302 ubm(k) = u(i, k)*xv + v(i, k)*yv
1313 sghmax =
fcrit2*(ubsrc/nsrc)**2
1314 IF (hdsp**2 .GT. sghmax)
THEN 1319 tauoro =
oroko2*min1*rsrc*nsrc*ubsrc
1335 IF (ubi(kbot) .LT. 0. .OR. ubm(kbot) .LT. 0.)
THEN 1345 tau(0, kbot) = tauoro
1351 IF (ksrcmn .GT. ksrc)
THEN 1356 IF (kldvmn .GT. kldv)
THEN 1361 IF (kldv .NE. pver) rdpldv = 1./(pi(i, kldv)-pi(i, pver))
1363 IF (
fracldv .LE. 0.) kldvmn = pver
1370 SUBROUTINE gw_bgnd_d(i, pcols, pver, c, u, ud, v, vd, t, pm, pi, dpm, &
1371 & rdpm, piln, rlat, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubid&
1372 & , ubm, ubmd, xv, xvd, yv, yvd, ngwv, kbot)
1392 REAL :: c(-ngwv:ngwv)
1394 REAL :: u(pcols, pver)
1395 REAL :: ud(pcols, pver)
1397 REAL :: v(pcols, pver)
1398 REAL :: vd(pcols, pver)
1400 REAL :: t(pcols, pver)
1402 REAL :: pm(pcols, pver)
1404 REAL :: pi(pcols, 0:pver)
1406 REAL :: dpm(pcols, pver)
1408 REAL :: rdpm(pcols, pver)
1410 REAL :: piln(pcols, 0:pver)
1424 REAL :: tau(-ngwv:ngwv, 0:pver)
1427 REAL :: ubid(0:pver)
1457 REAL :: u_new, v_new, tau_new
1487 usrcd = 0.5*(ud(i, kbot+1)+ud(i, kbot))
1488 usrc = 0.5*(u(i, kbot+1)+u(i, kbot))
1489 vsrcd = 0.5*(vd(i, kbot+1)+vd(i, kbot))
1490 vsrc = 0.5*(v(i, kbot+1)+v(i, kbot))
1491 arg1d = 2*usrc*usrcd + 2*vsrc*vsrcd
1492 arg1 = usrc**2 + vsrc**2
1493 IF (arg1 .EQ. 0.0)
THEN 1496 x1d = arg1d/(2.0*sqrt(arg1))
1500 IF (x1 .LT. y1)
THEN 1507 IF (usrc .EQ. 0. .AND. vsrc .EQ. 0.)
THEN 1514 xvd = (usrcd*ubsrc-usrc*ubsrcd)/ubsrc**2
1516 yvd = (vsrcd*ubsrc-vsrc*ubsrcd)/ubsrc**2
1522 ubmd(k) = ud(i, k)*xv + u(i, k)*xvd + vd(i, k)*yv + v(i, k)*yvd
1523 ubm(k) = u(i, k)*xv + v(i, k)*yv
1538 latdeg = rlat(i)*180./
pi_gwd 1540 IF (-15.3 .LT. latdeg .AND. latdeg .LT. 15.3)
THEN 1541 IF (latdeg .GE. 0.)
THEN 1546 arg1 = -(dble((abs1-3.)/8.0)**2)
1547 flat_gw = 1.2*exp(arg1)
1548 IF (latdeg .GE. 0.)
THEN 1553 IF (flat_gw .LT. 1.2 .AND. abs2 .LE. 3.) flat_gw = 1.2
1554 ELSE IF (latdeg .GT. -31. .AND. latdeg .LE. -15.3)
THEN 1556 ELSE IF (latdeg .LT. 31. .AND. latdeg .GE. 15.3)
THEN 1558 ELSE IF (latdeg .GT. -60. .AND. latdeg .LE. -31.)
THEN 1559 IF (latdeg .GE. 0.)
THEN 1564 arg1 = -(dble((abs3-60.)/23.)**2)
1565 flat_gw = 0.50*exp(arg1)
1566 ELSE IF (latdeg .LT. 60. .AND. latdeg .GE. 31.)
THEN 1567 IF (latdeg .GE. 0.)
THEN 1572 arg1 = -(dble((abs4-60.)/23.)**2)
1573 flat_gw = 0.50*exp(arg1)
1574 ELSE IF (latdeg .LE. -60.)
THEN 1575 IF (latdeg .GE. 0.)
THEN 1580 arg1 = -(dble((abs5-60.)/70.)**2)
1581 flat_gw = 0.50*exp(arg1)
1582 ELSE IF (latdeg .GE. 60.)
THEN 1583 IF (latdeg .GE. 0.)
THEN 1588 arg1 = -(dble((abs6-60.)/70.)**2)
1589 flat_gw = 0.50*exp(arg1)
1591 tauback = tauback*flat_gw
1596 arg1 = -((c(l)/30.)**2)
1597 tau(l, kbot) = tauback*exp(arg1)
1598 tau(-l, kbot) = tau(l, kbot)
1600 tau(0, kbot) = tauback
1609 SUBROUTINE gw_bgnd(i, pcols, pver, c, u, v, t, pm, pi, dpm, rdpm, piln&
1610 & , rlat, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, &
1631 REAL :: c(-ngwv:ngwv)
1633 REAL :: u(pcols, pver)
1635 REAL :: v(pcols, pver)
1637 REAL :: t(pcols, pver)
1639 REAL :: pm(pcols, pver)
1641 REAL :: pi(pcols, 0:pver)
1643 REAL :: dpm(pcols, pver)
1645 REAL :: rdpm(pcols, pver)
1647 REAL :: piln(pcols, 0:pver)
1661 REAL :: tau(-ngwv:ngwv, 0:pver)
1687 REAL :: u_new, v_new, tau_new
1714 usrc = 0.5*(u(i, kbot+1)+u(i, kbot))
1715 vsrc = 0.5*(v(i, kbot+1)+v(i, kbot))
1716 arg1 = usrc**2 + vsrc**2
1719 IF (x1 .LT. y1)
THEN 1724 IF (usrc .EQ. 0. .AND. vsrc .EQ. 0.)
THEN 1733 ubm(k) = u(i, k)*xv + v(i, k)*yv
1746 latdeg = rlat(i)*180./
pi_gwd 1748 IF (-15.3 .LT. latdeg .AND. latdeg .LT. 15.3)
THEN 1749 IF (latdeg .GE. 0.)
THEN 1754 arg1 = -(dble((abs1-3.)/8.0)**2)
1755 flat_gw = 1.2*exp(arg1)
1756 IF (latdeg .GE. 0.)
THEN 1761 IF (flat_gw .LT. 1.2 .AND. abs2 .LE. 3.) flat_gw = 1.2
1762 ELSE IF (latdeg .GT. -31. .AND. latdeg .LE. -15.3)
THEN 1764 ELSE IF (latdeg .LT. 31. .AND. latdeg .GE. 15.3)
THEN 1766 ELSE IF (latdeg .GT. -60. .AND. latdeg .LE. -31.)
THEN 1767 IF (latdeg .GE. 0.)
THEN 1772 arg1 = -(dble((abs3-60.)/23.)**2)
1773 flat_gw = 0.50*exp(arg1)
1774 ELSE IF (latdeg .LT. 60. .AND. latdeg .GE. 31.)
THEN 1775 IF (latdeg .GE. 0.)
THEN 1780 arg1 = -(dble((abs4-60.)/23.)**2)
1781 flat_gw = 0.50*exp(arg1)
1782 ELSE IF (latdeg .LE. -60.)
THEN 1783 IF (latdeg .GE. 0.)
THEN 1788 arg1 = -(dble((abs5-60.)/70.)**2)
1789 flat_gw = 0.50*exp(arg1)
1790 ELSE IF (latdeg .GE. 60.)
THEN 1791 IF (latdeg .GE. 0.)
THEN 1796 arg1 = -(dble((abs6-60.)/70.)**2)
1797 flat_gw = 0.50*exp(arg1)
1799 tauback = tauback*flat_gw
1804 arg1 = -((c(l)/30.)**2)
1805 tau(l, kbot) = tauback*exp(arg1)
1806 tau(-l, kbot) = tau(l, kbot)
1808 tau(0, kbot) = tauback
1820 SUBROUTINE gw_drag_prof_d(i, pcols, pver, pgwv, ngwv, kbot, ktop, c, u&
1821 & , v, t, pi, dpm, rdpm, piln, rlat, rhoi, ni, ti, nm, dt, alpha, &
1822 & dback, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, taud, ubi, ubid, ubm&
1823 & , xv, xvd, yv, yvd, ut, utd, vt, vtd, tt, taugwx, taugwy, fegw, &
1824 & fepgw, dusrc, dvsrc, dtsrc, tau0x, tau0y, effgw)
1838 INTEGER,
INTENT(IN) :: i
1840 INTEGER,
INTENT(IN) :: pcols
1842 INTEGER,
INTENT(IN) :: pver
1844 INTEGER,
INTENT(IN) :: kbot
1846 INTEGER,
INTENT(IN) :: ktop
1848 INTEGER,
INTENT(IN) :: pgwv
1850 INTEGER,
INTENT(IN) :: ngwv
1852 INTEGER,
INTENT(IN) :: kldv
1854 INTEGER,
INTENT(IN) :: kldvmn
1856 INTEGER,
INTENT(IN) :: ksrc
1858 INTEGER,
INTENT(IN) :: ksrcmn
1860 REAL :: c(-pgwv:pgwv)
1862 REAL :: u(pcols, pver)
1864 REAL :: v(pcols, pver)
1866 REAL :: t(pcols, pver)
1868 REAL :: pi(pcols, 0:pver)
1870 REAL :: dpm(pcols, pver)
1872 REAL :: rdpm(pcols, pver)
1874 REAL :: piln(pcols, 0:pver)
1877 REAL :: rhoi(0:pver)
1887 REAL :: alpha(0:pver)
1889 REAL :: dback(0:pver)
1894 REAL :: ubid(0:pver)
1904 REAL :: effgw(pcols)
1906 REAL :: tau(-pgwv:pgwv, 0:pver)
1907 REAL :: taud(-pgwv:pgwv, 0:pver)
1917 REAL :: taugwx(pcols, 0:pver)
1919 REAL :: taugwy(pcols, 0:pver)
1921 REAL :: fegw(pcols, 0:pver)
1923 REAL :: fepgw(pcols, 0:pver)
1970 REAL :: dzm, hscal, tautmp
1996 REAL :: tau_min, cmu_, t_new
2011 IF (k .LE. kbot - 1)
THEN 2046 IF (k .LE. kbot - 1)
THEN 2049 ubmc = ubi(k) - c(l)
2050 IF (ngwv .GT. 0)
THEN 2052 IF (-15.0 .LT. rlat(i)*180./
pi_gwd .AND. rlat(i)*180./
pi_gwd&
2055 IF (pi(i, k) .LT. 1000.0)
THEN 2056 zfac = (pi(i, k)/1000.0)**3
2060 IF (rlat(i)*180./
pi_gwd .LT. -20.0)
THEN 2066 x1d = effkwvmap*rhoi(k)*3*ubmc**2*ubmcd/(2.*ni(k))
2067 x1 = effkwvmap*rhoi(k)*ubmc**3/(2.*ni(k))
2068 IF (x1 .GE. 0.)
THEN 2075 IF (tausat .LE.
taumin)
THEN 2079 IF (ubmc*(ubi(k+1)-c(l)) .LE. 0.0)
THEN 2083 IF (k .EQ. ktop)
THEN 2088 IF (k .EQ. ktop + 1)
THEN 2089 tausatd = 0.02*tausatd
2090 tausat = tausat*0.02
2092 IF (k .EQ. ktop + 2)
THEN 2093 tausatd = 0.05*tausatd
2094 tausat = tausat*0.05
2096 IF (k .EQ. ktop + 3)
THEN 2097 tausatd = 0.10*tausatd
2098 tausat = tausat*0.10
2100 IF (k .EQ. ktop + 4)
THEN 2101 tausatd = 0.20*tausatd
2102 tausat = tausat*0.20
2104 IF (k .EQ. ktop + 5)
THEN 2105 tausatd = 0.50*tausatd
2106 tausat = tausat*0.50
2111 IF (tau_min .GT. tau(l, k+1))
THEN 2112 tau_mind = taud(l, k+1)
2113 tau_min = tau(l, k+1)
2115 taud(l, k) = tau_mind
2130 IF (k .LE. kbot)
THEN 2132 ubtld =
mapl_grav*rdpm(i, k)*(taud(l, k)-taud(l, k-1))
2133 ubtl =
mapl_grav*(tau(l, k)-tau(l, k-1))*rdpm(i, k)
2135 utld = ubtld*sign(1.d0, ubtl*(c(l)-ubi(k)))
2136 utl = sign(ubtl, c(l) - ubi(k))
2141 ttl = (c(l)-ubm(k))*utl/
mapl_cp 2147 IF (k .LE. kbot)
THEN 2148 utd(k) = effgw(i)*(ubtd*xv+ubt*xvd)
2149 ut(k) = ubt*xv*effgw(i)
2150 vtd(k) = effgw(i)*(ubtd*yv+ubt*yvd)
2151 vt(k) = ubt*yv*effgw(i)
2152 tt(k) = tbt*effgw(i)
2163 IF (k .GE. kbot + 1)
THEN 2165 pm = (pi(i, k-1)+pi(i, k))*0.5
2166 CALL get_ti(t_new, t(i, k))
2176 IF (k .LE. kbot)
THEN 2179 fpmx = cmu_*tau(l, k)*xv*effgw(i)
2180 fpmy = cmu_*tau(l, k)*yv*effgw(i)
2181 fe = cmu*cmu_*tau(l, k)*effgw(i)
2182 fpe = c(l)*cmu_*tau(l, k)*effgw(i)
2183 IF (k .EQ. kbot)
THEN 2184 fpml = fpmx*xv + fpmy*yv
2187 IF (k .EQ. ktop)
THEN 2188 fpmt = fpmx*xv + fpmy*yv
2192 taugwx(i, k) = taugwx(i, k) + fpmx
2193 taugwy(i, k) = taugwy(i, k) + fpmy
2194 fegw(i, k) = fegw(i, k) + fe
2195 fepgw(i, k) = fepgw(i, k) + fpe
2199 IF (k .GE. kbot + 1)
THEN 2201 pm = (pi(i, k-1)+pi(i, k))*0.5
2202 CALL get_ti(t_new, t(i, k))
2204 dusrcl = -((fpml-fpmt)/(rhom*zlb)*xv)
2205 dvsrcl = -((fpml-fpmt)/(rhom*zlb)*yv)
2206 dtsrcl = -((fpel-fpet-ubm(k)*(fpml-fpmt))/(rhom*zlb*
mapl_cp))
2208 dusrc(k) = dusrc(k) + dusrcl
2209 dvsrc(k) = dvsrc(k) + dvsrcl
2210 dtsrc(k) = dtsrc(k) + dtsrcl
2216 IF (ngwv .EQ. 0)
THEN 2229 arg1d = 2*ut(k)*utd(k) + 2*vt(k)*vtd(k)
2230 arg1 = ut(k)**2 + vt(k)**2
2231 IF (arg1 .EQ. 0.0)
THEN 2234 x2d = arg1d/(2.0*sqrt(arg1))
2237 IF (x2 .LT. uhtmax)
THEN 2244 IF (uhtmax .GT.
tndmax)
THEN 2245 utfacd = -(
tndmax*uhtmaxd/uhtmax**2)
2252 utd(k) = utd(k)*utfac + ut(k)*utfacd
2254 vtd(k) = vtd(k)*utfac + vt(k)*utfacd
2257 dusrc(k) = dusrc(k)*utfac
2258 dvsrc(k) = dvsrc(k)*utfac
2259 dtsrc(k) = dtsrc(k)*utfac
2265 tau0x = tau(0, kbot)*xv*effgw(i)*utfac
2266 tau0y = tau(0, kbot)*yv*effgw(i)*utfac
2270 SUBROUTINE gw_drag_prof(i, pcols, pver, pgwv, ngwv, kbot, ktop, c, u, &
2271 & v, t, pi, dpm, rdpm, piln, rlat, rhoi, ni, ti, nm, dt, alpha, dback&
2272 & , kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, ut, vt&
2273 & , tt, taugwx, taugwy, fegw, fepgw, dusrc, dvsrc, dtsrc, tau0x, tau0y&
2288 INTEGER,
INTENT(IN) :: i
2290 INTEGER,
INTENT(IN) :: pcols
2292 INTEGER,
INTENT(IN) :: pver
2294 INTEGER,
INTENT(IN) :: kbot
2296 INTEGER,
INTENT(IN) :: ktop
2298 INTEGER,
INTENT(IN) :: pgwv
2300 INTEGER,
INTENT(IN) :: ngwv
2302 INTEGER,
INTENT(IN) :: kldv
2304 INTEGER,
INTENT(IN) :: kldvmn
2306 INTEGER,
INTENT(IN) :: ksrc
2308 INTEGER,
INTENT(IN) :: ksrcmn
2310 REAL :: c(-pgwv:pgwv)
2312 REAL :: u(pcols, pver)
2314 REAL :: v(pcols, pver)
2316 REAL :: t(pcols, pver)
2318 REAL :: pi(pcols, 0:pver)
2320 REAL :: dpm(pcols, pver)
2322 REAL :: rdpm(pcols, pver)
2324 REAL :: piln(pcols, 0:pver)
2327 REAL :: rhoi(0:pver)
2337 REAL :: alpha(0:pver)
2339 REAL :: dback(0:pver)
2351 REAL :: effgw(pcols)
2353 REAL :: tau(-pgwv:pgwv, 0:pver)
2361 REAL :: taugwx(pcols, 0:pver)
2363 REAL :: taugwy(pcols, 0:pver)
2365 REAL :: fegw(pcols, 0:pver)
2367 REAL :: fepgw(pcols, 0:pver)
2410 REAL :: dzm, hscal, tautmp
2433 REAL :: tau_min, cmu_, t_new
2444 IF (k .LE. kbot - 1) tau(l, k) = 0.
2474 IF (k .LE. kbot - 1)
THEN 2476 ubmc = ubi(k) - c(l)
2477 IF (ngwv .GT. 0)
THEN 2479 IF (-15.0 .LT. rlat(i)*180./
pi_gwd .AND. rlat(i)*180./
pi_gwd&
2482 IF (pi(i, k) .LT. 1000.0)
THEN 2483 zfac = (pi(i, k)/1000.0)**3
2487 IF (rlat(i)*180./
pi_gwd .LT. -20.0)
THEN 2493 x1 = effkwvmap*rhoi(k)*ubmc**3/(2.*ni(k))
2494 IF (x1 .GE. 0.)
THEN 2499 IF (tausat .LE.
taumin) tausat = 0.0
2500 IF (ubmc*(ubi(k+1)-c(l)) .LE. 0.0) tausat = 0.0
2501 IF (k .EQ. ktop) tausat = 0.
2503 IF (k .EQ. ktop + 1) tausat = tausat*0.02
2504 IF (k .EQ. ktop + 2) tausat = tausat*0.05
2505 IF (k .EQ. ktop + 3) tausat = tausat*0.10
2506 IF (k .EQ. ktop + 4) tausat = tausat*0.20
2507 IF (k .EQ. ktop + 5) tausat = tausat*0.50
2510 IF (tau_min .GT. tau(l, k+1)) tau_min = tau(l, k+1)
2524 IF (k .LE. kbot)
THEN 2526 ubtl =
mapl_grav*(tau(l, k)-tau(l, k-1))*rdpm(i, k)
2528 utl = sign(ubtl, c(l) - ubi(k))
2532 ttl = (c(l)-ubm(k))*utl/
mapl_cp 2538 IF (k .LE. kbot)
THEN 2539 ut(k) = ubt*xv*effgw(i)
2540 vt(k) = ubt*yv*effgw(i)
2541 tt(k) = tbt*effgw(i)
2552 IF (k .GE. kbot + 1)
THEN 2554 pm = (pi(i, k-1)+pi(i, k))*0.5
2555 CALL get_ti(t_new, t(i, k))
2565 IF (k .LE. kbot)
THEN 2568 fpmx = cmu_*tau(l, k)*xv*effgw(i)
2569 fpmy = cmu_*tau(l, k)*yv*effgw(i)
2570 fe = cmu*cmu_*tau(l, k)*effgw(i)
2571 fpe = c(l)*cmu_*tau(l, k)*effgw(i)
2572 IF (k .EQ. kbot)
THEN 2573 fpml = fpmx*xv + fpmy*yv
2576 IF (k .EQ. ktop)
THEN 2577 fpmt = fpmx*xv + fpmy*yv
2581 taugwx(i, k) = taugwx(i, k) + fpmx
2582 taugwy(i, k) = taugwy(i, k) + fpmy
2583 fegw(i, k) = fegw(i, k) + fe
2584 fepgw(i, k) = fepgw(i, k) + fpe
2588 IF (k .GE. kbot + 1)
THEN 2590 pm = (pi(i, k-1)+pi(i, k))*0.5
2591 CALL get_ti(t_new, t(i, k))
2593 dusrcl = -((fpml-fpmt)/(rhom*zlb)*xv)
2594 dvsrcl = -((fpml-fpmt)/(rhom*zlb)*yv)
2595 dtsrcl = -((fpel-fpet-ubm(k)*(fpml-fpmt))/(rhom*zlb*
mapl_cp))
2597 dusrc(k) = dusrc(k) + dusrcl
2598 dvsrc(k) = dvsrc(k) + dvsrcl
2599 dtsrc(k) = dtsrc(k) + dtsrcl
2605 IF (ngwv .EQ. 0)
THEN 2617 arg1 = ut(k)**2 + vt(k)**2
2619 IF (x2 .LT. uhtmax)
THEN 2631 dusrc(k) = dusrc(k)*utfac
2632 dvsrc(k) = dvsrc(k)*utfac
2633 dtsrc(k) = dtsrc(k)*utfac
2639 tau0x = tau(0, kbot)*xv*effgw(i)*utfac
2640 tau0y = tau(0, kbot)*yv*effgw(i)*utfac
2647 & , c, u, v, t, pi, dpm, rdpm, piln, rlat, rhoi, ni, ti, nm, dt, alpha&
2648 & , dback, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, taud, ubi, ubid, &
2649 & ubm, xv, xvd, yv, yvd, ut, utd, vt, vtd, tt, taugwx, taugwy, fegw, &
2650 & fepgw, dusrc, dusrcd, dvsrc, dvsrcd, dtsrc, tau0x, tau0y, effgw)
2664 INTEGER,
INTENT(IN) :: i
2666 INTEGER,
INTENT(IN) :: pcols
2668 INTEGER,
INTENT(IN) :: pver
2670 INTEGER,
INTENT(IN) :: kbot
2672 INTEGER,
INTENT(IN) :: ktop
2674 INTEGER,
INTENT(IN) :: pgwv
2676 INTEGER,
INTENT(IN) :: ngwv
2678 INTEGER,
INTENT(IN) :: kldv
2680 INTEGER,
INTENT(IN) :: kldvmn
2682 INTEGER,
INTENT(IN) :: ksrc
2684 INTEGER,
INTENT(IN) :: ksrcmn
2686 REAL :: c(-pgwv:pgwv)
2688 REAL :: u(pcols, pver)
2690 REAL :: v(pcols, pver)
2692 REAL :: t(pcols, pver)
2694 REAL :: pi(pcols, 0:pver)
2696 REAL :: dpm(pcols, pver)
2698 REAL :: rdpm(pcols, pver)
2700 REAL :: piln(pcols, 0:pver)
2703 REAL :: rhoi(0:pver)
2713 REAL :: alpha(0:pver)
2715 REAL :: dback(0:pver)
2720 REAL :: ubid(0:pver)
2730 REAL :: effgw(pcols)
2732 REAL :: tau(-pgwv:pgwv, 0:pver)
2733 REAL :: taud(-pgwv:pgwv, 0:pver)
2743 REAL :: taugwx(pcols, 0:pver)
2745 REAL :: taugwy(pcols, 0:pver)
2747 REAL :: fegw(pcols, 0:pver)
2749 REAL :: fepgw(pcols, 0:pver)
2752 REAL :: dusrcd(pver)
2755 REAL :: dvsrcd(pver)
2798 REAL :: dzm, hscal, tautmp
2830 REAL :: tau_min, cmu_, t_new
2845 IF (k .LE. kbot - 1)
THEN 2883 IF (k .LE. kbot - 1)
THEN 2886 ubmc = ubi(k) - c(l)
2887 IF (ngwv .GT. 0)
THEN 2889 IF (-15.0 .LT. rlat(i)*180./
pi_gwd .AND. rlat(i)*180./
pi_gwd&
2892 IF (pi(i, k) .LT. 1000.0)
THEN 2893 zfac = (pi(i, k)/1000.0)**3
2897 IF (rlat(i)*180./
pi_gwd .LT. -20.0)
THEN 2903 x1d = effkwvmap*rhoi(k)*3*ubmc**2*ubmcd/(2.*ni(k))
2904 x1 = effkwvmap*rhoi(k)*ubmc**3/(2.*ni(k))
2905 IF (x1 .GE. 0.)
THEN 2912 IF (tausat .LE.
taumin)
THEN 2916 IF (ubmc*(ubi(k+1)-c(l)) .LE. 0.0)
THEN 2920 IF (k .EQ. ktop)
THEN 2925 IF (k .EQ. ktop + 1)
THEN 2926 tausatd = 0.02*tausatd
2927 tausat = tausat*0.02
2929 IF (k .EQ. ktop + 2)
THEN 2930 tausatd = 0.05*tausatd
2931 tausat = tausat*0.05
2933 IF (k .EQ. ktop + 3)
THEN 2934 tausatd = 0.10*tausatd
2935 tausat = tausat*0.10
2937 IF (k .EQ. ktop + 4)
THEN 2938 tausatd = 0.20*tausatd
2939 tausat = tausat*0.20
2941 IF (k .EQ. ktop + 5)
THEN 2942 tausatd = 0.50*tausatd
2943 tausat = tausat*0.50
2948 IF (tau_min .GT. tau(l, k+1))
THEN 2949 tau_mind = taud(l, k+1)
2950 tau_min = tau(l, k+1)
2952 taud(l, k) = tau_mind
2969 IF (k .LE. kbot)
THEN 2971 ubtld =
mapl_grav*rdpm(i, k)*(taud(l, k)-taud(l, k-1))
2972 ubtl =
mapl_grav*(tau(l, k)-tau(l, k-1))*rdpm(i, k)
2974 utld = ubtld*sign(1.d0, ubtl*(c(l)-ubi(k)))
2975 utl = sign(ubtl, c(l) - ubi(k))
2980 ttl = (c(l)-ubm(k))*utl/
mapl_cp 2986 IF (k .LE. kbot)
THEN 2987 utd(k) = effgw(i)*(ubtd*xv+ubt*xvd)
2988 ut(k) = ubt*xv*effgw(i)
2989 vtd(k) = effgw(i)*(ubtd*yv+ubt*yvd)
2990 vt(k) = ubt*yv*effgw(i)
2991 tt(k) = tbt*effgw(i)
3002 IF (k .GE. kbot + 1)
THEN 3004 pm = (pi(i, k-1)+pi(i, k))*0.5
3005 CALL get_ti(t_new, t(i, k))
3019 IF (k .LE. kbot)
THEN 3022 fpmxd = cmu_*effgw(i)*(taud(l, k)*xv+tau(l, k)*xvd)
3023 fpmx = cmu_*tau(l, k)*xv*effgw(i)
3024 fpmyd = cmu_*effgw(i)*(taud(l, k)*yv+tau(l, k)*yvd)
3025 fpmy = cmu_*tau(l, k)*yv*effgw(i)
3026 fe = cmu*cmu_*tau(l, k)*effgw(i)
3027 fpe = c(l)*cmu_*tau(l, k)*effgw(i)
3028 IF (k .EQ. kbot)
THEN 3029 fpmld = fpmxd*xv + fpmx*xvd + fpmyd*yv + fpmy*yvd
3030 fpml = fpmx*xv + fpmy*yv
3033 IF (k .EQ. ktop)
THEN 3034 fpmtd = fpmxd*xv + fpmx*xvd + fpmyd*yv + fpmy*yvd
3035 fpmt = fpmx*xv + fpmy*yv
3039 taugwx(i, k) = taugwx(i, k) + fpmx
3040 taugwy(i, k) = taugwy(i, k) + fpmy
3041 fegw(i, k) = fegw(i, k) + fe
3042 fepgw(i, k) = fepgw(i, k) + fpe
3046 IF (k .GE. kbot + 1)
THEN 3048 pm = (pi(i, k-1)+pi(i, k))*0.5
3049 CALL get_ti(t_new, t(i, k))
3051 dusrcld = -((fpmld-fpmtd)*xv/(rhom*zlb)+(fpml-fpmt)*xvd/(rhom*&
3053 dusrcl = -((fpml-fpmt)/(rhom*zlb)*xv)
3054 dvsrcld = -((fpmld-fpmtd)*yv/(rhom*zlb)+(fpml-fpmt)*yvd/(rhom*&
3056 dvsrcl = -((fpml-fpmt)/(rhom*zlb)*yv)
3057 dtsrcl = -((fpel-fpet-ubm(k)*(fpml-fpmt))/(rhom*zlb*
mapl_cp))
3059 dusrcd(k) = dusrcd(k) + dusrcld
3060 dusrc(k) = dusrc(k) + dusrcl
3061 dvsrcd(k) = dvsrcd(k) + dvsrcld
3062 dvsrc(k) = dvsrc(k) + dvsrcl
3063 dtsrc(k) = dtsrc(k) + dtsrcl
3069 IF (ngwv .EQ. 0)
THEN 3084 arg1d = 2*ut(k)*utd(k) + 2*vt(k)*vtd(k)
3085 arg1 = ut(k)**2 + vt(k)**2
3086 IF (arg1 .EQ. 0.0)
THEN 3089 x2d = arg1d/(2.0*sqrt(arg1))
3092 IF (x2 .LT. uhtmax)
THEN 3099 IF (uhtmax .GT.
tndmax)
THEN 3100 utfacd = -(
tndmax*uhtmaxd/uhtmax**2)
3107 utd(k) = utd(k)*utfac + ut(k)*utfacd
3109 vtd(k) = vtd(k)*utfac + vt(k)*utfacd
3112 dusrcd(k) = dusrcd(k)*utfac + dusrc(k)*utfacd
3113 dusrc(k) = dusrc(k)*utfac
3114 dvsrcd(k) = dvsrcd(k)*utfac + dvsrc(k)*utfacd
3115 dvsrc(k) = dvsrc(k)*utfac
3116 dtsrc(k) = dtsrc(k)*utfac
3122 tau0x = tau(0, kbot)*xv*effgw(i)*utfac
3123 tau0y = tau(0, kbot)*yv*effgw(i)*utfac
3127 & , u, v, t, pi, dpm, rdpm, piln, rlat, rhoi, ni, ti, nm, dt, alpha, &
3128 & dback, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, ut&
3129 & , vt, tt, taugwx, taugwy, fegw, fepgw, dusrc, dvsrc, dtsrc, tau0x, &
3144 INTEGER,
INTENT(IN) :: i
3146 INTEGER,
INTENT(IN) :: pcols
3148 INTEGER,
INTENT(IN) :: pver
3150 INTEGER,
INTENT(IN) :: kbot
3152 INTEGER,
INTENT(IN) :: ktop
3154 INTEGER,
INTENT(IN) :: pgwv
3156 INTEGER,
INTENT(IN) :: ngwv
3158 INTEGER,
INTENT(IN) :: kldv
3160 INTEGER,
INTENT(IN) :: kldvmn
3162 INTEGER,
INTENT(IN) :: ksrc
3164 INTEGER,
INTENT(IN) :: ksrcmn
3166 REAL :: c(-pgwv:pgwv)
3168 REAL :: u(pcols, pver)
3170 REAL :: v(pcols, pver)
3172 REAL :: t(pcols, pver)
3174 REAL :: pi(pcols, 0:pver)
3176 REAL :: dpm(pcols, pver)
3178 REAL :: rdpm(pcols, pver)
3180 REAL :: piln(pcols, 0:pver)
3183 REAL :: rhoi(0:pver)
3193 REAL :: alpha(0:pver)
3195 REAL :: dback(0:pver)
3207 REAL :: effgw(pcols)
3209 REAL :: tau(-pgwv:pgwv, 0:pver)
3217 REAL :: taugwx(pcols, 0:pver)
3219 REAL :: taugwy(pcols, 0:pver)
3221 REAL :: fegw(pcols, 0:pver)
3223 REAL :: fepgw(pcols, 0:pver)
3266 REAL :: dzm, hscal, tautmp
3289 REAL :: tau_min, cmu_, t_new
3300 IF (k .LE. kbot - 1) tau(l, k) = 0.
3330 IF (k .LE. kbot - 1)
THEN 3332 ubmc = ubi(k) - c(l)
3333 IF (ngwv .GT. 0)
THEN 3335 IF (-15.0 .LT. rlat(i)*180./
pi_gwd .AND. rlat(i)*180./
pi_gwd&
3338 IF (pi(i, k) .LT. 1000.0)
THEN 3339 zfac = (pi(i, k)/1000.0)**3
3343 IF (rlat(i)*180./
pi_gwd .LT. -20.0)
THEN 3349 x1 = effkwvmap*rhoi(k)*ubmc**3/(2.*ni(k))
3350 IF (x1 .GE. 0.)
THEN 3355 IF (tausat .LE.
taumin) tausat = 0.0
3356 IF (ubmc*(ubi(k+1)-c(l)) .LE. 0.0) tausat = 0.0
3357 IF (k .EQ. ktop) tausat = 0.
3359 IF (k .EQ. ktop + 1) tausat = tausat*0.02
3360 IF (k .EQ. ktop + 2) tausat = tausat*0.05
3361 IF (k .EQ. ktop + 3) tausat = tausat*0.10
3362 IF (k .EQ. ktop + 4) tausat = tausat*0.20
3363 IF (k .EQ. ktop + 5) tausat = tausat*0.50
3366 IF (tau_min .GT. tau(l, k+1)) tau_min = tau(l, k+1)
3380 IF (k .LE. kbot)
THEN 3382 ubtl =
mapl_grav*(tau(l, k)-tau(l, k-1))*rdpm(i, k)
3384 utl = sign(ubtl, c(l) - ubi(k))
3388 ttl = (c(l)-ubm(k))*utl/
mapl_cp 3394 IF (k .LE. kbot)
THEN 3395 ut(k) = ubt*xv*effgw(i)
3396 vt(k) = ubt*yv*effgw(i)
3397 tt(k) = tbt*effgw(i)
3408 IF (k .GE. kbot + 1)
THEN 3410 pm = (pi(i, k-1)+pi(i, k))*0.5
3411 CALL get_ti(t_new, t(i, k))
3421 IF (k .LE. kbot)
THEN 3424 fpmx = cmu_*tau(l, k)*xv*effgw(i)
3425 fpmy = cmu_*tau(l, k)*yv*effgw(i)
3426 fe = cmu*cmu_*tau(l, k)*effgw(i)
3427 fpe = c(l)*cmu_*tau(l, k)*effgw(i)
3428 IF (k .EQ. kbot)
THEN 3429 fpml = fpmx*xv + fpmy*yv
3432 IF (k .EQ. ktop)
THEN 3433 fpmt = fpmx*xv + fpmy*yv
3437 taugwx(i, k) = taugwx(i, k) + fpmx
3438 taugwy(i, k) = taugwy(i, k) + fpmy
3439 fegw(i, k) = fegw(i, k) + fe
3440 fepgw(i, k) = fepgw(i, k) + fpe
3444 IF (k .GE. kbot + 1)
THEN 3446 pm = (pi(i, k-1)+pi(i, k))*0.5
3447 CALL get_ti(t_new, t(i, k))
3449 dusrcl = -((fpml-fpmt)/(rhom*zlb)*xv)
3450 dvsrcl = -((fpml-fpmt)/(rhom*zlb)*yv)
3451 dtsrcl = -((fpel-fpet-ubm(k)*(fpml-fpmt))/(rhom*zlb*
mapl_cp))
3453 dusrc(k) = dusrc(k) + dusrcl
3454 dvsrc(k) = dvsrc(k) + dvsrcl
3455 dtsrc(k) = dtsrc(k) + dtsrcl
3461 IF (ngwv .EQ. 0)
THEN 3473 arg1 = ut(k)**2 + vt(k)**2
3475 IF (x2 .LT. uhtmax)
THEN 3487 dusrc(k) = dusrc(k)*utfac
3488 dvsrc(k) = dvsrc(k)*utfac
3489 dtsrc(k) = dtsrc(k)*utfac
3495 tau0x = tau(0, kbot)*xv*effgw(i)*utfac
3496 tau0y = tau(0, kbot)*yv*effgw(i)*utfac
3502 SUBROUTINE get_uv_d(uv_out, uv_outd, uv_in, uv_ind)
3504 REAL :: uv_out, uv_in
3505 REAL :: uv_outd, uv_ind
3506 LOGICAL :: src_bypass
3507 IF (src_bypass)
THEN 3515 SUBROUTINE get_uv(uv_out, uv_in)
3517 REAL :: uv_out, uv_in
3518 LOGICAL :: src_bypass
3519 IF (src_bypass)
THEN 3527 REAL :: tanh1, tanh2, effkwvmap_, rlat_
3529 tanh1 = (rlat_*180./
pi_gwd-20.0)/6.0
3530 tanh2 = -((rlat_*180./
pi_gwd+20.0)/6.0)
3533 effkwvmap_ =
fcrit2*
kwvb*(0.5*(1.0+tanh1)+0.5*(1.0+tanh2))
3537 REAL :: effkwvmap_, rlat_, zfac
3541 IF (rlat_*180./
pi_gwd + 20. .GE. 0.)
THEN 3542 abs1 = rlat_*180./
pi_gwd + 20.
3544 abs1 = -(rlat_*180./
pi_gwd+20.)
3546 effkwvmap_ =
fcrit2*
kwvo*zfac*(2.0-0.65*exp(-(abs1/5.)))
3550 REAL :: effkwvmap_, rlat_, zfac
3554 IF (rlat_*180./
pi_gwd + 20. .GE. 0.)
THEN 3555 abs1 = rlat_*180./
pi_gwd + 20.
3557 abs1 = -(rlat_*180./
pi_gwd+20.)
3559 effkwvmap_ =
fcrit2*
kwvo*zfac*(0.7+0.65*exp(-(abs1/5.)))
3565 cmu_ = sign(1.0, cmu)
3567 SUBROUTINE get_ti(t_out, t_in)
3570 LOGICAL :: src_bypass
subroutine get_effkwvmap_1(effkwvmap_, rlat_)
subroutine gw_intr(i, pcols, pver, dt, pgwv, effgworo_dev, effgwbkg_dev, pint_dev, t_dev, u_dev, v_dev, sgh_dev, pref_dev, pmid_dev, pdel_dev, rpdel_dev, lnpint_dev, zm_dev, rlat_dev, dudt_gwd_dev, dvdt_gwd_dev, dtdt_gwd_dev, dudt_org_dev, dvdt_org_dev, dtdt_org_dev, taugwdx_dev, taugwdy_dev, tauox_dev, tauoy_dev, feo_dev, taubkgx_dev, taubkgy_dev, taubx_dev, tauby_dev, feb_dev, fepo_dev, fepb_dev, utbsrc_dev, vtbsrc_dev, ttbsrc_dev)
integer, public isize_s1_tau
real, parameter, public fracldv
subroutine gw_bgnd_d(i, pcols, pver, c, u, ud, v, vd, t, pm, pi, dpm, rdpm, piln, rlat, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubid, ubm, ubmd, xv, xvd, yv, yvd, ngwv, kbot)
subroutine gw_drag_prof_bgnd_d(i, pcols, pver, pgwv, ngwv, kbot, ktop, c, u, v, t, pi, dpm, rdpm, piln, rlat, rhoi, ni, ti, nm, dt, alpha, dback, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, taud, ubi, ubid, ubm, xv, xvd, yv, yvd, ut, utd, vt, vtd, tt, taugwx, taugwy, fegw, fepgw, dusrc, dusrcd, dvsrc, dvsrcd, dtsrc, tau0x, tau0y, effgw)
subroutine gw_drag_prof_bgnd(i, pcols, pver, pgwv, ngwv, kbot, ktop, c, u, v, t, pi, dpm, rdpm, piln, rlat, rhoi, ni, ti, nm, dt, alpha, dback, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, ut, vt, tt, taugwx, taugwy, fegw, fepgw, dusrc, dvsrc, dtsrc, tau0x, tau0y, effgw)
real *8, parameter, public p_src
real, parameter, public mxrange
subroutine gw_drag_prof(i, pcols, pver, pgwv, ngwv, kbot, ktop, c, u, v, t, pi, dpm, rdpm, piln, rlat, rhoi, ni, ti, nm, dt, alpha, dback, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, ut, vt, tt, taugwx, taugwy, fegw, fepgw, dusrc, dvsrc, dtsrc, tau0x, tau0y, effgw)
real, parameter, public taubgnd
subroutine gw_prof(i, k, pcols, pver, u, v, t, pm, pi, rhoi, ni, ti, nm)
real, parameter, public umcfac
real, parameter, public mapl_cp
real, parameter, public mapl_vireps
subroutine get_cmu(cmu_, cmu)
subroutine get_uv_d(uv_out, uv_outd, uv_in, uv_ind)
integer, public isize_e1_tau
real, parameter, public taumin
real, parameter, public kwvbeq
subroutine gw_bgnd(i, pcols, pver, c, u, v, t, pm, pi, dpm, rdpm, piln, rlat, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, ngwv, kbot)
real, parameter, public kwvb
real, parameter, public mapl_kappa
subroutine gw_oro(i, pcols, pver, pgwv, u, v, t, sgh, pm, pi, dpm, zm, nm, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, ubi, ubm, xv, yv, kbot, rlat)
real, parameter, public pi_gwd
real, parameter, public mapl_p00
integer, public isize_s2_tau
real, parameter, public tauscal
real, parameter, public oroko2
subroutine gw_oro_d(i, pcols, pver, pgwv, u, ud, v, vd, t, sgh, pm, pi, dpm, zm, nm, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, taud, ubi, ubid, ubm, ubmd, xv, xvd, yv, yvd, kbot, rlat)
subroutine get_uv(uv_out, uv_in)
real, parameter, public rog
subroutine, public gw_main_d(pcols, pver, dt, pgwv, effgworo_dev, effgwbkg_dev, pint_dev, t_dev, u_dev, u_devd, v_dev, v_devd, sgh_dev, pref_dev, pmid_dev, pdel_dev, rpdel_dev, lnpint_dev, zm_dev, qvt_dev, rog, mapl_vireps_, rlat_dev)
real, parameter, public mxasym
subroutine get_ti(t_out, t_in)
real, parameter, public n2min
integer, public isize_e2_tau
real, parameter, public kwvo
real, parameter, public fcrit2
real, parameter, public orovmin
real, parameter, public mapl_rgas
logical, parameter, public bypass_bgnd
real, parameter, public mapl_grav
real, parameter, public zldvcon
subroutine gw_drag_prof_d(i, pcols, pver, pgwv, ngwv, kbot, ktop, c, u, v, t, pi, dpm, rdpm, piln, rlat, rhoi, ni, ti, nm, dt, alpha, dback, kldv, kldvmn, ksrc, ksrcmn, rdpldv, tau, taud, ubi, ubid, ubm, xv, xvd, yv, yvd, ut, utd, vt, vtd, tt, taugwx, taugwy, fegw, fepgw, dusrc, dvsrc, dtsrc, tau0x, tau0y, effgw)
logical, parameter, public bypass_oro
subroutine get_effkwvmap_2(effkwvmap_, rlat_, zfac)
real, parameter, public tndmax
real, parameter, public orohmin
subroutine gw_intr_d(i, pcols, pver, dt, pgwv, effgworo_dev, effgwbkg_dev, pint_dev, t_dev, u_dev, u_devd, v_dev, v_devd, sgh_dev, pref_dev, pmid_dev, pdel_dev, rpdel_dev, lnpint_dev, zm_dev, rlat_dev, dudt_gwd_dev, dudt_gwd_devd, dvdt_gwd_dev, dvdt_gwd_devd, dtdt_gwd_dev, dudt_org_dev, dvdt_org_dev, dtdt_org_dev, taugwdx_dev, taugwdy_dev, tauox_dev, tauoy_dev, feo_dev, taubkgx_dev, taubkgy_dev, taubx_dev, tauby_dev, feb_dev, fepo_dev, fepb_dev, utbsrc_dev, vtbsrc_dev, ttbsrc_dev)
real, parameter, public ubmc2mn
subroutine get_effkwvmap_3(effkwvmap_, rlat_, zfac)