Skip to content

Commit

Permalink
Add error message for geolat and eqn_of_state
Browse files Browse the repository at this point in the history
  • Loading branch information
yichengt900 authored Apr 5, 2024
1 parent d4e20e4 commit 73cda08
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion generic_tracers/generic_COBALT.F90
Original file line number Diff line number Diff line change
Expand Up @@ -8315,7 +8315,8 @@ subroutine generic_COBALT_update_from_source(tracer_list,Temp,Salt,rho_dzt,dzt,h
! write(outunit,*) 'kmld_ref = ',kmld_ref
!endif


if (.not. PRESENT(eqn_of_state)) call mpp_error(FATAL,"eqn_of_state is missing! Unable to compute &
density in COBALT!")
! calculate the mld for the photoacclimation calculations
call calculate_density(Temp(i,j,kmld_ref),Salt(i,j,kmld_ref),101325.0,rho_mld_ref,eqn_of_state)
!if ((i.eq.isc).and.(j.eq.jsc)) then
Expand Down Expand Up @@ -8380,6 +8381,8 @@ subroutine generic_COBALT_update_from_source(tracer_list,Temp,Salt,rho_dzt,dzt,h
endif !}
enddo !}

if (.not. PRESENT(geolat)) call mpp_error(FATAL,"geolat is missing! Unable to compute day length &
in COBALT!")
! calculate day length based on the CBM daylength model as described in:
!
! Forsythe, W.C., et al. (1995). A model comparison for daylength as a function of latitude and day of year.
Expand Down

0 comments on commit 73cda08

Please sign in to comment.