136 SUBROUTINE cher(UPLO,N,ALPHA,X,INCX,A,LDA)
149 COMPLEX a(lda,*),x(*)
156 parameter(zero= (0.0e+0,0.0e+0))
160 INTEGER i,info,ix,j,jx,kx
170 INTRINSIC conjg,max,real
176 IF (.NOT.
lsame(uplo,
'U') .AND. .NOT.
lsame(uplo,
'L'))
THEN
178 ELSE IF (n.LT.0)
THEN
180 ELSE IF (incx.EQ.0)
THEN
182 ELSE IF (lda.LT.max(1,n))
THEN
192 IF ((n.EQ.0) .OR. (alpha.EQ.
REAL(zero))) return
198 ELSE IF (incx.NE.1)
THEN
206 IF (
lsame(uplo,
'U'))
THEN
212 IF (x(j).NE.zero)
THEN
213 temp = alpha*conjg(x(j))
215 a(i,j) = a(i,j) + x(i)*temp
217 a(j,j) =
REAL(A(J,J)) +
REAL(x(j)*temp)
219 a(j,j) =
REAL(a(j,j))
225 IF (x(jx).NE.zero)
THEN
226 temp = alpha*conjg(x(jx))
229 a(i,j) = a(i,j) + x(ix)*temp
232 a(j,j) =
REAL(A(J,J)) +
REAL(x(jx)*temp)
234 a(j,j) =
REAL(a(j,j))
245 IF (x(j).NE.zero)
THEN
246 temp = alpha*conjg(x(j))
247 a(j,j) =
REAL(A(J,J)) +
REAL(temp*x(j))
249 a(i,j) = a(i,j) + x(i)*temp
252 a(j,j) =
REAL(a(j,j))
258 IF (x(jx).NE.zero)
THEN
259 temp = alpha*conjg(x(jx))
260 a(j,j) =
REAL(A(J,J)) +
REAL(temp*x(jx))
264 a(i,j) = a(i,j) + x(ix)*temp
267 a(j,j) =
REAL(a(j,j))