HP MLIB User's Guide Vol. 1 7th Ed.
90 HP MLIB User’s Guide
SDOTI/DDOTI/CDOTCI/CDOTUI/ZDOTCI/ZDOTUI Sparse dot product
Output s The resulting value of the dot product. If , then
. Otherwise,
unless the subprogram name is CDOTCI or ZDOTCI,
in which case
Fortran
Equivalent
REAL*4 FUNCTION SDOTI (M, X,INDX, Y)
REAL*4 X(*),Y(*)
INTEGER*4 INDX(*)
SDOTI = 0.0
IF ( M .LE. 0 ) RETURN
DO 10 I = 1, M
SDOTI = SDOTI + X(I) * Y(INDX(I))
10 CONTINUE
RETURN
END
m 0≤
s 0=
s x i() y indx i()()×
i 1=
m
∑
=
s CONJG x i()()yindxi()()×
i 1=
m
∑
=