subroutine dp(x,y,d) use prec_mod, only: rk implicit none real(rk) :: d real(rk), dimension(3) :: x, y d = sum(x*y) end subroutine dp