Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion extern/stim
26 changes: 6 additions & 20 deletions src/airsea/airsea.F90
Original file line number Diff line number Diff line change
Expand Up @@ -356,6 +356,8 @@ subroutine init_airsea_nml(namlst, fn)
stop 'init_airsea'
91 FATAL 'I could not read airsea namelist'
stop 'init_airsea'
93 FATAL 'I could not open ',trim(meteo_file)
stop 'init_airsea'

end subroutine init_airsea_nml
!EOC
Expand Down Expand Up @@ -492,20 +494,11 @@ subroutine init_airsea_yaml()
call branch%get(calc_evaporation, 'calc_evaporation', 'calculate evaporation from meteorological conditions', &
default=.false.)

!jpnote: before cherry pick
call branch%get(I_0, 'swr', 'shortwave radiation', 'W/m^2', &
minimum=0._rk,default=0._rk, extra_options=(/option(3, 'from time, location and cloud cover', 'calculate')/))
!call branch%get(ql, 'longwave_radiation', 'net longwave radiation', 'W/m^2', &
! default=0._rk, method_file=0, method_constant=method_unsupported, &
!extra_options=(/option(CLARK, 'Clark et al. (1974)', 'Clark'), option(HASTENRATH_LAMB, 'Hastenrath and Lamb (1978)', 'Hastenrath_Lamb'), option(BIGNAMI, 'Bignami et al. (1995)', 'Bignami'), option(BERLIAND_BERLIAND, 'Berliand and Berliand (1952)', 'Berliand_Berliand'), option(JOSEY1, 'Josey et al. (2003) - 1', 'Josey1'), option(JOSEY2, 'Josey et al. (2003) - 2', 'Josey2')/), default_method=CLARK)
!jpnote: after cherry pick 1
!call branch%get(ql, 'longwave_radiation', 'longwave radiation', 'W/m^2', &
!call twig%get(ssuv_method, 'ssuv_method', 'wind treatment', &
!options=(/option(0, 'use absolute wind speed'), option(1, 'use wind speed relative to current velocity')/), default=1, display=display_advanced)
!jpnote: after cherry pick 2
call branch%get(ql_, 'longwave_radiation', 'longwave radiation', 'W/m^2', &
default=0._rk, method_file=0, method_constant=method_unsupported, &
extra_options=(/option(1, 'Clark'), option(2, 'Hastenrath'), option(3, 'Bignami'), option(4, 'Berliand'), option(5, 'Josey-1'), option(6, 'Josey-2')/), default_method=1, pchild=leaf)
extra_options=(/option(CLARK, 'Clark et al. (1974)', 'Clark'), option(HASTENRATH_LAMB, 'Hastenrath and Lamb (1978)', 'Hastenrath_Lamb'), option(BIGNAMI, 'Bignami et al. (1995)', 'Bignami'), option(BERLIAND_BERLIAND, 'Berliand and Berliand (1952)', 'Berliand_Berliand'), option(JOSEY1, 'Josey et al. (2003) - 1', 'Josey1'), option(JOSEY2, 'Josey et al. (2003) - 2', 'Josey2')/), default_method=CLARK, pchild=leaf)
call leaf%get(longwave_type, 'type', 'longwave type from file', &
options=(/option(1, 'net longwave radiation'), option(2, 'incoming longwave radiation')/), default=1)

Expand Down Expand Up @@ -703,8 +696,8 @@ subroutine post_init_airsea(lat,lon)
LEVEL3 'longwave radiation:'
select case (ql_%method)
case(0) ! Read from file instead of calculating
call register_input(ql_) !jpnote commmit 2 change
case(1)
call register_input(ql_)
case(CLARK)
LEVEL4 'using Clark formulation'
case(HASTENRATH_LAMB)
LEVEL4 'using Hastenrath formulation'
Expand Down Expand Up @@ -772,16 +765,9 @@ subroutine surface_fluxes_uvic(surface_temp,sensible,latent,longwave_radiation_v
tw_k= surface_temp
ta_k = airt%value + KELVIN

! call humidity(hum_method,rh,airp,TTss-kelvin,airt)
call humidity(hum_method,hum%value,airp%value,tw,airt%value)
! call longwave_radiation(longwave_radiation_method, &
! lat,TTss,airt+kelvin,cloud,qb)
call longwave_radiation(ql_%method,longwave_type, &
dlat,tw_k,ta_k,cloud%value,ql_%value,longwave_radiation_value)
!call longwave_radiation(ql%method, &
! dlat,tw_k,ta_k,cloud%value,longwave_radiation_value)
!call airsea_fluxes(fluxes_method, &
!TTss-kelvin,airt,u10,v10,precip,evap,tx,ty,qe,qh)
call airsea_fluxes(fluxes_method, &
tw,airt%value,u10%value,v10%value,precip%value,evap,tx_%value,ty_%value,latent,sensible)

Expand Down Expand Up @@ -1034,7 +1020,7 @@ subroutine flux_from_meteo(jul,secs)
call humidity(hum_method,hum,airp,tw,ta)
call longwave_radiation(ql_%method,longwave_type, &
dlat,tw_k,ta_k,cloud,ql_%value,ql)
end if
! end if
#if 0
call airsea_fluxes(fluxes_method,rain_impact,calc_evaporation, &
tw,ta,u10%value-ssu,v10%value-ssv,precip%value,evap,tx2,ty2,qe,qh)
Expand Down
12 changes: 0 additions & 12 deletions src/airsea/longwave_radiation.F90
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,6 @@ subroutine longwave_radiation(method,type,dlat,tw,ta,cloud,qlobs,ql)
! Original author(s): Adolf Stips, Hans Burchard & Karsten Bolding
!
! !LOCAL VARIABLES:
!cherry pick -- > jpnote to get rid of and add to airseavariables
!integer, parameter :: from_file=0
!integer, parameter :: clark=1 ! Clark et al, 1974
!integer, parameter :: hastenrath=2 ! Hastenrath and Lamb, 1978
!integer, parameter :: bignami=3 ! Bignami et al., 1995 - Medsea
!integer, parameter :: berliand=4 ! Berliand and Berliand, 1952 - ROMS
!integer, parameter :: josey1=5 ! Josey 2003, (J1,9)
!integer, parameter :: josey2=6 ! Josey 2003, (J2,14)

REALTYPE, parameter, dimension(91) :: cloud_correction_factor = (/ &
0.497202, 0.501885, 0.506568, 0.511250, 0.515933, &
0.520616, 0.525299, 0.529982, 0.534665, 0.539348, &
Expand Down Expand Up @@ -77,9 +68,6 @@ subroutine longwave_radiation(method,type,dlat,tw,ta,cloud,qlobs,ql)
ccf= cloud_correction_factor(nint(abs(dlat))+1)

select case(method)
!before
!case(CLARK)
!after
case(FILE)
select case(type)
case(1)
Expand Down