aboutsummaryrefslogtreecommitdiff
path: root/sys/vops/ak/adotl.x
blob: 0df6d0386521eb3006ee693323fb1e7ab98aef20 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc.

# ADOT -- Vector inner or dot product.  The function value is the sum of the
# products of each pair of elements of the input vectors.

double procedure adotl (a, b, npix)

long	a[ARB], b[ARB]

double	sum

int	npix, i

begin
	sum = 0
	do i = 1, npix
	    sum = sum + a[i] * b[i]

	return (sum)
end