Developer Reference for Intel® oneAPI Math Kernel Library for Fortran

ID 766686
Date 10/31/2024
Public
Document Table of Contents

?orm2r/?unm2r

Multiplies a general matrix by the orthogonal/unitary matrix from a QR factorization determined by ?geqrf (unblocked algorithm).

Syntax

call sorm2r( side, trans, m, n, k, a, lda, tau, c, ldc, work, info )

call dorm2r( side, trans, m, n, k, a, lda, tau, c, ldc, work, info )

call cunm2r( side, trans, m, n, k, a, lda, tau, c, ldc, work, info )

call zunm2r( side, trans, m, n, k, a, lda, tau, c, ldc, work, info )

Include Files

  • mkl.fi

Description

The routine ?orm2r/?unm2r overwrites the general real/complex m-by-n matrix C with

Q*C if side = 'L' and trans = 'N', or

QT*C / QH*C if side = 'L' and trans = 'T' (for real flavors) or trans = 'C' (for complex flavors), or

C*Q if side = 'R' and trans = 'N', or

C*QT / C*QH if side = 'R' and trans = 'T' (for real flavors) or trans = 'C' (for complex flavors).

Here Q is a real orthogonal or complex unitary matrix defined as the product of k elementary reflectors

Q = H(1)*H(2)*...*H(k) as returned by ?geqrf.

Q is of order m if side = 'L' and of order n if side = 'R'.

Input Parameters

side

CHARACTER*1.

= 'L': apply Q or QT / QH from the left

= 'R': apply Q or QT / QH from the right

trans

CHARACTER*1.

= 'N': apply Q (no transpose)

= 'T': apply QT (transpose, for real flavors)

= 'C': apply QH (conjugate transpose, for complex flavors)

m

INTEGER. The number of rows of the matrix C. m 0.

n

INTEGER. The number of columns of the matrix C. n 0.

k

INTEGER. The number of elementary reflectors whose product defines the matrix Q.

If side = 'L', mk 0;

if side = 'R', nk 0.

a

REAL for sorm2r

DOUBLE PRECISION for dorm2r

COMPLEX for cunm2r

DOUBLE COMPLEX for zunm2r.

Array, DIMENSION (lda,k).

The i-th column must contain the vector which defines the elementary reflector H(i), for i = 1,2,..., k, as returned by ?geqrf in the first k columns of its array argument a. The array a is modified by the routine but restored on exit.

lda

INTEGER. The leading dimension of the array a.

If side = 'L', lda max(1, m);

if side = 'R', lda max(1, n).

tau

REAL for sorm2r

DOUBLE PRECISION for dorm2r

COMPLEX for cunm2r

DOUBLE COMPLEX for zunm2r.

Array, DIMENSION (k).

tau(i) must contain the scalar factor of the elementary reflector H(i), as returned by ?geqrf.

c

REAL for sorm2r

DOUBLE PRECISION for dorm2r

COMPLEX for cunm2r

DOUBLE COMPLEX for zunm2r.

Array, DIMENSION (ldc, n).

On entry, the m-by-n matrix C.

ldc

INTEGER. The leading dimension of the array c. ldc max(1,m).

work

REAL for sorm2r

DOUBLE PRECISION for dorm2r

COMPLEX for cunm2r

DOUBLE COMPLEX for zunm2r.

Workspace array, DIMENSION

(n) if side = 'L',

(m) if side = 'R'.

Output Parameters

c

On exit, c is overwritten by Q*C or QT*C / QH*C, or C*Q, or C*QT / C*QH.

info

INTEGER.

= 0: successful exit

< 0: if info = -i, the i-th argument had an illegal value