Skip to content

Commit

Permalink
Remove unused code, improve assert() messages. mom-ocean#62
Browse files Browse the repository at this point in the history
  • Loading branch information
nichannah committed Jul 15, 2015
1 parent 0549766 commit 3554d6e
Showing 1 changed file with 3 additions and 12 deletions.
15 changes: 3 additions & 12 deletions src/framework/MOM_diag_mediator.F90
Original file line number Diff line number Diff line change
Expand Up @@ -741,6 +741,7 @@ subroutine remap_diag_to_z(field, diag, diag_cs, remapped_field)
nz_dest = diag_cs%nz_remap

if (is_u_axes(diag%remap_axes, diag_cs)) then
call assert(allocated(diag_cs%zi_u), 'remap_diag_to_z: Z grid on u points not built.')
do j=diag_cs%G%jsc, diag_cs%G%jec
do i=diag_cs%G%iscB, diag_cs%G%iecB
if (associated(diag%mask3d)) then
Expand All @@ -765,6 +766,7 @@ subroutine remap_diag_to_z(field, diag, diag_cs, remapped_field)
enddo

elseif (is_v_axes(diag%remap_axes, diag_cs)) then
call assert(allocated(diag_cs%zi_v), 'remap_diag_to_z: Z grid on v points not built.')
do j=diag_cs%G%jscB, diag_cs%G%jecB
do i=diag_cs%G%isc, diag_cs%G%iec
if (associated(diag%mask3d)) then
Expand All @@ -783,19 +785,8 @@ subroutine remap_diag_to_z(field, diag, diag_cs, remapped_field)
enddo
enddo
enddo
!elseif (is_B_axes(diag%remap_axes, diag_cs)) then
! do j=diag_cs%G%jscB, diag_cs%G%jecB
! do i=diag_cs%G%iscB, diag_cs%G%iecB
! if (associated(diag%mask3d)) then
! if (diag%mask3d(i,j, 1) == 0.) cycle
! endif
! h_dest(:) = diag_cs%zi_B(i, j, 2:) - diag_cs%zi_B(i, j, :size(diag_cs%zi_B, 3)-1)
! call dzFromH1H2(nz_src, diag_cs%h(i, j, :), nz_dest, h_dest(:), dz)
! call remapping_core(diag_cs%remap_cs, nz_src, diag_cs%h(i, j, :), field(i, j, :), nz_dest, dz, &
! remapped_field(i, j, :))
! enddo
! enddo
else
call assert(allocated(diag_cs%zi_v), 'remap_diag_to_z: Z grid on T points not built.')
do j=diag_cs%G%jsc, diag_cs%G%jec
do i=diag_cs%G%isc, diag_cs%G%iec
if (associated(diag%mask3d)) then
Expand Down

0 comments on commit 3554d6e

Please sign in to comment.