Skip to content

Commit

Permalink
Merge remote-tracking branch 'cefi/dev/cefi' into esmg_work
Browse files Browse the repository at this point in the history
  • Loading branch information
kshedstrom committed Apr 12, 2024
2 parents 06ba41d + 4e4b2bb commit 8d6f67f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
6 changes: 5 additions & 1 deletion config_src/external/GFDL_ocean_BGC/generic_tracer.F90
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ module generic_tracer

use g_tracer_utils, only : g_tracer_type, g_diag_type

use MOM_EOS, only: EOS_type

implicit none ; private

public generic_tracer_register
Expand Down Expand Up @@ -68,7 +70,7 @@ end subroutine generic_tracer_coupler_accumulate
!> Calls the corresponding generic_X_update_from_source routine for each package X
subroutine generic_tracer_source(Temp,Salt,rho_dzt,dzt,hblt_depth,ilb,jlb,tau,dtts,&
grid_dat,model_time,nbands,max_wavelength_band,sw_pen_band,opacity_band,internal_heat,&
frunoff,grid_ht, current_wave_stress, sosga)
frunoff,grid_ht, current_wave_stress, sosga, geolat, eqn_of_state)
integer, intent(in) :: ilb !< Lower bounds of x extent of input arrays on data domain
integer, intent(in) :: jlb !< Lower bounds of y extent of input arrays on data domain
real, dimension(ilb:,jlb:,:), intent(in) :: Temp !< Potential temperature [deg C]
Expand All @@ -94,6 +96,8 @@ subroutine generic_tracer_source(Temp,Salt,rho_dzt,dzt,hblt_depth,ilb,jlb,tau,dt
real, dimension(ilb:,jlb:),optional, intent(in) :: grid_ht !< Unknown, and presently unused by MOM6
real, dimension(ilb:,jlb:),optional , intent(in) :: current_wave_stress !< Unknown, and presently unused by MOM6
real, optional , intent(in) :: sosga !< Global average sea surface salinity [ppt]
real, dimension(ilb:,jlb:),optional, intent(in) :: geolat !< Latitude
type(EOS_type), optional, intent(in) :: eqn_of_state !< A pointer to the equation of state
end subroutine generic_tracer_source

!> Update the tracers from bottom fluxes
Expand Down
4 changes: 2 additions & 2 deletions src/tracer/MOM_generic_tracer.F90
Original file line number Diff line number Diff line change
Expand Up @@ -582,15 +582,15 @@ subroutine MOM_generic_tracer_column_physics(h_old, h_new, ea, eb, fluxes, Hml,
call generic_tracer_source(tv%T, tv%S, rho_dzt, dzt, dz_ml, G%isd, G%jsd, 1, dt, &
G%areaT, get_diag_time_end(CS%diag), &
optics%nbands, optics%max_wavelength_band, optics%sw_pen_band, optics%opacity_band, &
internal_heat=tv%internal_heat, frunoff=fluxes%frunoff, sosga=sosga)
internal_heat=tv%internal_heat, frunoff=fluxes%frunoff, sosga=sosga, geolat=G%geolatT, eqn_of_state=tv%eqn_of_state)
else
call generic_tracer_source(US%C_to_degC*tv%T, US%S_to_ppt*tv%S, rho_dzt, dzt, dz_ml, G%isd, G%jsd, 1, dt, &
G%US%L_to_m**2*G%areaT(:,:), get_diag_time_end(CS%diag), &
optics%nbands, optics%max_wavelength_band, &
sw_pen_band=G%US%QRZ_T_to_W_m2*optics%sw_pen_band(:,:,:), &
opacity_band=G%US%m_to_Z*optics%opacity_band(:,:,:,:), &
internal_heat=G%US%RZ_to_kg_m2*US%C_to_degC*tv%internal_heat(:,:), &
frunoff=G%US%RZ_T_to_kg_m2s*fluxes%frunoff(:,:), sosga=sosga)
frunoff=G%US%RZ_T_to_kg_m2s*fluxes%frunoff(:,:), sosga=sosga, geolat=G%geolatT, eqn_of_state=tv%eqn_of_state)
endif

! This uses applyTracerBoundaryFluxesInOut to handle the change in tracer due to freshwater fluxes
Expand Down

0 comments on commit 8d6f67f

Please sign in to comment.