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
5 changes: 3 additions & 2 deletions src/gotm/gotm.F90
Original file line number Diff line number Diff line change
Expand Up @@ -784,12 +784,13 @@ subroutine integrate_gotm()
#ifdef _ICE_
I_0%value = transmissivity*I_0%value
swf=melt_rate
shf=ocean_ice_heat_flux
ssf=ocean_ice_salt_flux
shf=ocean_ice_heat_flux + rho0*cp*T(nlev)*swf
ssf=ocean_ice_salt_flux + S(nlev)*swf
#endif
else
swf=precip_input%value+evap
shf=-heat_input%value ! temperature() changed to positive heat flux upwards (v7)
ssf= S(nlev)*swf
tx = tx/rho0
ty = ty/rho0
end if
Expand Down
2 changes: 1 addition & 1 deletion src/meanflow/salinity.F90
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ subroutine salinity(nlev,dt,cnpar,wflux,sflux,nus,gams)
! set boundary conditions
DiffBcup = Neumann
DiffBcdw = Neumann
DiffSup = -S(nlev)*wflux-sflux
DiffSup = -sflux
DiffSdw = _ZERO_

AdvBcup = oneSided
Expand Down
8 changes: 4 additions & 4 deletions src/meanflow/temperature.F90
Original file line number Diff line number Diff line change
Expand Up @@ -137,10 +137,10 @@ subroutine temperature(nlev,dt,cnpar,I_0,wflux,hflux,nuh,gamh,rad)
DiffBcup = Neumann
DiffBcdw = Neumann

! HB:
! Note that this is the surface temperature flux for rigid-lid models like GOTM.
! For a free surface model the surface temperature flux must be - -hflux/(rho0*cp)
DiffTup = -T(nlev)*wflux-hflux/(rho0*cp)
! For the open ocean the surface temperature flux is only the diffusive
! component. In case of ice cover, hflux is defined as the sum of a diffusive
! and advective component.
DiffTup = -hflux/(rho0*cp)
#ifndef _ICE_
! simple sea ice model: surface heat flux switched off for sst < freezing temp
if (T(nlev) .le. -0.0575*S(nlev)) then
Expand Down
6 changes: 3 additions & 3 deletions src/util/convert_fluxes.F90
Original file line number Diff line number Diff line change
Expand Up @@ -66,11 +66,11 @@ subroutine convert_fluxes(nlev,gravity,swf,shf,ssf,rad,Tsrf,Ssrf,tFlux,sFlux,bt
beta0 = get_beta(Ssrf,Tsrf,_ZERO_)

! temperature flux and associated buoyancy flux
tFlux = -Tsrf*swf - shf/(rho0*cp)
btFlux = gravity*alpha0*tFlux
tFlux = - shf/(rho0*cp)
btFlux = gravity*alpha0*tFlux

! salinity flux and associated buoyancy flux
sFlux = -Ssrf*swf - ssf
sFlux = - ssf
bsFlux = -gravity*beta0*sFlux

! radiative temperature and buoyancy flux profiles
Expand Down