1 subroutine da_get_2d_sum(var, name)
3 !-----------------------------------------------------------------------
5 !-----------------------------------------------------------------------
9 real, intent(in) :: var(ims:ime, jms:jme)
10 character(len=*), intent(in) :: name
12 real :: partial, total
14 if (trace_use) call da_trace_entry("da_get_2d_sum")
16 partial = sum(var(its:ite,jts:jte)*var(its:ite,jts:jte))
18 total = wrf_dm_sum_real( partial)
20 write(unit=stdout, fmt='(3a, e24.14)') 'Square sum of <', trim(name), '>=', total
22 if (trace_use) call da_trace_exit("da_get_2d_sum")
24 end subroutine da_get_2d_sum