LAPACK  3.6.1
LAPACK: Linear Algebra PACKage
subroutine zlarcm ( integer  M,
integer  N,
double precision, dimension( lda, * )  A,
integer  LDA,
complex*16, dimension( ldb, * )  B,
integer  LDB,
complex*16, dimension( ldc, * )  C,
integer  LDC,
double precision, dimension( * )  RWORK 
)

ZLARCM copies all or part of a real two-dimensional array to a complex array.

Download ZLARCM + dependencies [TGZ] [ZIP] [TXT]

Purpose:
 ZLARCM performs a very simple matrix-matrix multiplication:
          C := A * B,
 where A is M by M and real; B is M by N and complex;
 C is M by N and complex.
Parameters
[in]M
          M is INTEGER
          The number of rows of the matrix A and of the matrix C.
          M >= 0.
[in]N
          N is INTEGER
          The number of columns and rows of the matrix B and
          the number of columns of the matrix C.
          N >= 0.
[in]A
          A is DOUBLE PRECISION array, dimension (LDA, M)
          A contains the M by M matrix A.
[in]LDA
          LDA is INTEGER
          The leading dimension of the array A. LDA >=max(1,M).
[in]B
          B is COMPLEX*16 array, dimension (LDB, N)
          B contains the M by N matrix B.
[in]LDB
          LDB is INTEGER
          The leading dimension of the array B. LDB >=max(1,M).
[in]C
          C is COMPLEX*16 array, dimension (LDC, N)
          C contains the M by N matrix C.
[in]LDC
          LDC is INTEGER
          The leading dimension of the array C. LDC >=max(1,M).
[out]RWORK
          RWORK is DOUBLE PRECISION array, dimension (2*M*N)
Author
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.
Date
June 2016

Definition at line 116 of file zlarcm.f.

116 *
117 * -- LAPACK auxiliary routine (version 3.6.1) --
118 * -- LAPACK is a software package provided by Univ. of Tennessee, --
119 * -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
120 * June 2016
121 *
122 * .. Scalar Arguments ..
123  INTEGER lda, ldb, ldc, m, n
124 * ..
125 * .. Array Arguments ..
126  DOUBLE PRECISION a( lda, * ), rwork( * )
127  COMPLEX*16 b( ldb, * ), c( ldc, * )
128 * ..
129 *
130 * =====================================================================
131 *
132 * .. Parameters ..
133  DOUBLE PRECISION one, zero
134  parameter ( one = 1.0d0, zero = 0.0d0 )
135 * ..
136 * .. Local Scalars ..
137  INTEGER i, j, l
138 * ..
139 * .. Intrinsic Functions ..
140  INTRINSIC dble, dcmplx, dimag
141 * ..
142 * .. External Subroutines ..
143  EXTERNAL dgemm
144 * ..
145 * .. Executable Statements ..
146 *
147 * Quick return if possible.
148 *
149  IF( ( m.EQ.0 ) .OR. ( n.EQ.0 ) )
150  $ RETURN
151 *
152  DO 20 j = 1, n
153  DO 10 i = 1, m
154  rwork( ( j-1 )*m+i ) = dble( b( i, j ) )
155  10 CONTINUE
156  20 CONTINUE
157 *
158  l = m*n + 1
159  CALL dgemm( 'N', 'N', m, n, m, one, a, lda, rwork, m, zero,
160  $ rwork( l ), m )
161  DO 40 j = 1, n
162  DO 30 i = 1, m
163  c( i, j ) = rwork( l+( j-1 )*m+i-1 )
164  30 CONTINUE
165  40 CONTINUE
166 *
167  DO 60 j = 1, n
168  DO 50 i = 1, m
169  rwork( ( j-1 )*m+i ) = dimag( b( i, j ) )
170  50 CONTINUE
171  60 CONTINUE
172  CALL dgemm( 'N', 'N', m, n, m, one, a, lda, rwork, m, zero,
173  $ rwork( l ), m )
174  DO 80 j = 1, n
175  DO 70 i = 1, m
176  c( i, j ) = dcmplx( dble( c( i, j ) ),
177  $ rwork( l+( j-1 )*m+i-1 ) )
178  70 CONTINUE
179  80 CONTINUE
180 *
181  RETURN
182 *
183 * End of ZLARCM
184 *
subroutine dgemm(TRANSA, TRANSB, M, N, K, ALPHA, A, LDA, B, LDB, BETA, C, LDC)
DGEMM
Definition: dgemm.f:189

Here is the call graph for this function:

Here is the caller graph for this function: