176 SUBROUTINE ctrmm(SIDE,UPLO,TRANSA,DIAG,M,N,ALPHA,A,LDA,B,LDB)
185 CHARACTER DIAG,SIDE,TRANSA,UPLO
188 COMPLEX A(LDA,*),B(LDB,*)
205 INTEGER I,INFO,J,K,NROWA
206 LOGICAL LSIDE,NOCONJ,NOUNIT,UPPER
210 parameter(one= (1.0e+0,0.0e+0))
212 parameter(zero= (0.0e+0,0.0e+0))
217 lside = lsame(side,
'L')
223 noconj = lsame(transa,
'T')
224 nounit = lsame(diag,
'N')
225 upper = lsame(uplo,
'U')
228 IF ((.NOT.lside) .AND. (.NOT.lsame(side,
'R')))
THEN
230 ELSE IF ((.NOT.upper) .AND. (.NOT.lsame(uplo,
'L')))
THEN
232 ELSE IF ((.NOT.lsame(transa,
'N')) .AND.
233 + (.NOT.lsame(transa,
'T')) .AND.
234 + (.NOT.lsame(transa,
'C')))
THEN
236 ELSE IF ((.NOT.lsame(diag,
'U')) .AND.
237 + (.NOT.lsame(diag,
'N')))
THEN
239 ELSE IF (m.LT.0)
THEN
241 ELSE IF (n.LT.0)
THEN
243 ELSE IF (lda.LT.max(1,nrowa))
THEN
245 ELSE IF (ldb.LT.max(1,m))
THEN
249 CALL xerbla(
'CTRMM ',info)
255 IF (m.EQ.0 .OR. n.EQ.0)
RETURN
259 IF (alpha.EQ.zero)
THEN
271 IF (lsame(transa,
'N'))
THEN
278 IF (b(k,j).NE.zero)
THEN
281 b(i,j) = b(i,j) + temp*a(i,k)
283 IF (nounit) temp = temp*a(k,k)
291 IF (b(k,j).NE.zero)
THEN
294 IF (nounit) b(k,j) = b(k,j)*a(k,k)
296 b(i,j) = b(i,j) + temp*a(i,k)
311 IF (nounit) temp = temp*a(i,i)
313 temp = temp + a(k,i)*b(k,j)
316 IF (nounit) temp = temp*conjg(a(i,i))
318 temp = temp + conjg(a(k,i))*b(k,j)
329 IF (nounit) temp = temp*a(i,i)
331 temp = temp + a(k,i)*b(k,j)
334 IF (nounit) temp = temp*conjg(a(i,i))
336 temp = temp + conjg(a(k,i))*b(k,j)
345 IF (lsame(transa,
'N'))
THEN
352 IF (nounit) temp = temp*a(j,j)
357 IF (a(k,j).NE.zero)
THEN
360 b(i,j) = b(i,j) + temp*b(i,k)
368 IF (nounit) temp = temp*a(j,j)
373 IF (a(k,j).NE.zero)
THEN
376 b(i,j) = b(i,j) + temp*b(i,k)
389 IF (a(j,k).NE.zero)
THEN
393 temp = alpha*conjg(a(j,k))
396 b(i,j) = b(i,j) + temp*b(i,k)
405 temp = temp*conjg(a(k,k))
408 IF (temp.NE.one)
THEN
417 IF (a(j,k).NE.zero)
THEN
421 temp = alpha*conjg(a(j,k))
424 b(i,j) = b(i,j) + temp*b(i,k)
433 temp = temp*conjg(a(k,k))
436 IF (temp.NE.one)
THEN
subroutine xerbla(srname, info)
subroutine ctrmm(side, uplo, transa, diag, m, n, alpha, a, lda, b, ldb)
CTRMM