1 *> \brief \b CLAPMR rearranges rows of a matrix as specified by a permutation vector.
3 * =========== DOCUMENTATION ===========
5 * Online html documentation available at
6 * http://www.netlib.org/lapack/explore-html/
9 *> Download CLAPMR + dependencies
10 *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.tgz?format=tgz&filename=/lapack/lapack_routine/clapmr.f">
12 *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.zip?format=zip&filename=/lapack/lapack_routine/clapmr.f">
14 *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.txt?format=txt&filename=/lapack/lapack_routine/clapmr.f">
21 * SUBROUTINE CLAPMR( FORWRD, M, N, X, LDX, K )
23 * .. Scalar Arguments ..
27 * .. Array Arguments ..
38 *> CLAPMR rearranges the rows of the M by N matrix X as specified
39 *> by the permutation K(1),K(2),...,K(M) of the integers 1,...,M.
40 *> If FORWRD = .TRUE., forward permutation:
42 *> X(K(I),*) is moved X(I,*) for I = 1,2,...,M.
44 *> If FORWRD = .FALSE., backward permutation:
46 *> X(I,*) is moved to X(K(I),*) for I = 1,2,...,M.
55 *> = .TRUE., forward permutation
56 *> = .FALSE., backward permutation
62 *> The number of rows of the matrix X. M >= 0.
68 *> The number of columns of the matrix X. N >= 0.
73 *> X is COMPLEX array, dimension (LDX,N)
74 *> On entry, the M by N matrix X.
75 *> On exit, X contains the permuted matrix X.
81 *> The leading dimension of the array X, LDX >= MAX(1,M).
86 *> K is INTEGER array, dimension (M)
87 *> On entry, K contains the permutation vector. K is used as
88 *> internal workspace, but reset to its original value on
95 *> \author Univ. of Tennessee
96 *> \author Univ. of California Berkeley
97 *> \author Univ. of Colorado Denver
100 *> \date September 2012
102 *> \ingroup complexOTHERauxiliary
104 * =====================================================================
105 SUBROUTINE CLAPMR( FORWRD, M, N, X, LDX, K )
107 * -- LAPACK auxiliary routine (version 3.4.2) --
108 * -- LAPACK is a software package provided by Univ. of Tennessee, --
109 * -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
112 * .. Scalar Arguments ..
116 * .. Array Arguments ..
121 * =====================================================================
123 * .. Local Scalars ..
127 * .. Executable Statements ..
138 * Forward permutation
155 X( J, JJ ) = X( IN, JJ )
170 * Backward permutation
185 X( I, JJ ) = X( J, JJ )