SCALAPACK 2.2.2
LAPACK: Linear Algebra PACKage
Loading...
Searching...
No Matches
zzdotc.f
Go to the documentation of this file.
1 SUBROUTINE zzdotc( N, DOTC, X, INCX, Y, INCY )
2*
3* -- ScaLAPACK tools routine (version 1.7) --
4* University of Tennessee, Knoxville, Oak Ridge National Laboratory,
5* and University of California, Berkeley.
6* May 1, 1997
7*
8* .. Scalar Arguments ..
9 INTEGER INCX, INCY, N
10 COMPLEX*16 DOTC
11* ..
12* .. Array Arguments ..
13 COMPLEX*16 X( * ), Y( * )
14* ..
15*
16* Purpose
17* =======
18*
19* ZZDOTC is a simple FORTRAN wrapper around the BLAS function
20* ZDOTC returning the result in the parameter list instead.
21*
22* =====================================================================
23*
24* .. Local Scalars ..
25 COMPLEX*16 ZTEMP
26 INTEGER I,IX,IY
27* ..
28* .. Intrinsic Functions ..
29 INTRINSIC dconjg
30* ..
31* .. Executable Statements ..
32*
33 ztemp = (0.0d0,0.0d0)
34 dotc = (0.0d0,0.0d0)
35 IF (n.LE.0) RETURN
36 IF (incx.EQ.1 .AND. incy.EQ.1) THEN
37*
38* code for both increments equal to 1
39*
40 DO i = 1,n
41 ztemp = ztemp + dconjg(x(i))*y(i)
42 END DO
43 ELSE
44*
45* code for unequal increments or equal increments
46* not equal to 1
47*
48 ix = 1
49 iy = 1
50 IF (incx.LT.0) ix = (-n+1)*incx + 1
51 IF (incy.LT.0) iy = (-n+1)*incy + 1
52 DO i = 1,n
53 ztemp = ztemp + dconjg(x(ix))*y(iy)
54 ix = ix + incx
55 iy = iy + incy
56 END DO
57 END IF
58 dotc = ztemp
59*
60 RETURN
61*
62* End of ZZDOTC
63*
64 END
subroutine zzdotc(n, dotc, x, incx, y, incy)
Definition zzdotc.f:2