Skip to content

Commit

Permalink
Use G%Rad_Earth_L in mct and NUOPC cap code
Browse files Browse the repository at this point in the history
  Modified the two lines where the mct and NUOPC caps were using G%Rad_Earth to
instead use G%Rad_Earth_L, and cancelled out the dimensional rescaling factors
on these lines that are no longer appropriate.  All answers should be bitwise
identical, but because this change is to code that is not routinely exercised by
testing with MOM6-examples, extra care should be taken in assessing these
changes.
  • Loading branch information
Hallberg-NOAA authored and marshallward committed Dec 14, 2021
1 parent 170fffd commit 6feadd0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion config_src/drivers/mct_cap/ocn_comp_mct.F90
Original file line number Diff line number Diff line change
Expand Up @@ -722,7 +722,7 @@ subroutine ocn_domain_mct( lsize, gsMap_ocn, dom_ocn)
call mct_gGrid_importRattr(dom_ocn,"lat",data,lsize)

k = 0
L2_to_rad2 = grid%US%L_to_m**2 / grid%Rad_Earth**2
L2_to_rad2 = 1.0 / grid%Rad_Earth_L**2
do j = grid%jsc, grid%jec
do i = grid%isc, grid%iec
k = k + 1 ! Increment position within gindex
Expand Down
2 changes: 1 addition & 1 deletion config_src/drivers/nuopc_cap/mom_cap.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1111,7 +1111,7 @@ subroutine InitializeRealize(gcomp, importState, exportState, clock, rc)
k = k + 1 ! Increment position within gindex
if (mask(k) /= 0) then
mesh_areas(k) = dataPtr_mesh_areas(k)
model_areas(k) = ocean_grid%US%L_to_m**2 * ocean_grid%AreaT(i,j) / ocean_grid%Rad_Earth**2
model_areas(k) = ocean_grid%AreaT(i,j) / ocean_grid%Rad_Earth_L**2
mod2med_areacor(k) = model_areas(k) / mesh_areas(k)
med2mod_areacor(k) = mesh_areas(k) / model_areas(k)
end if
Expand Down

0 comments on commit 6feadd0

Please sign in to comment.