1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194
|
---
:name: dlaed2
:md5sum: d8f308f281405229efe4f87a4a67b923
:category: :subroutine
:arguments:
- k:
:type: integer
:intent: output
- n:
:type: integer
:intent: input
- n1:
:type: integer
:intent: input
- d:
:type: doublereal
:intent: input/output
:dims:
- n
- q:
:type: doublereal
:intent: input/output
:dims:
- ldq
- n
- ldq:
:type: integer
:intent: input
- indxq:
:type: integer
:intent: input/output
:dims:
- n
- rho:
:type: doublereal
:intent: input/output
- z:
:type: doublereal
:intent: input
:dims:
- n
- dlamda:
:type: doublereal
:intent: output
:dims:
- n
- w:
:type: doublereal
:intent: output
:dims:
- n
- q2:
:type: doublereal
:intent: output
:dims:
- pow(n1,2)+pow(n-n1,2)
- indx:
:type: integer
:intent: workspace
:dims:
- n
- indxc:
:type: integer
:intent: output
:dims:
- n
- indxp:
:type: integer
:intent: workspace
:dims:
- n
- coltyp:
:type: integer
:intent: output
:dims:
- n
- info:
:type: integer
:intent: output
:substitutions: {}
:fortran_help: " SUBROUTINE DLAED2( K, N, N1, D, Q, LDQ, INDXQ, RHO, Z, DLAMDA, W, Q2, INDX, INDXC, INDXP, COLTYP, INFO )\n\n\
* Purpose\n\
* =======\n\
*\n\
* DLAED2 merges the two sets of eigenvalues together into a single\n\
* sorted set. Then it tries to deflate the size of the problem.\n\
* There are two ways in which deflation can occur: when two or more\n\
* eigenvalues are close together or if there is a tiny entry in the\n\
* Z vector. For each such occurrence the order of the related secular\n\
* equation problem is reduced by one.\n\
*\n\n\
* Arguments\n\
* =========\n\
*\n\
* K (output) INTEGER\n\
* The number of non-deflated eigenvalues, and the order of the\n\
* related secular equation. 0 <= K <=N.\n\
*\n\
* N (input) INTEGER\n\
* The dimension of the symmetric tridiagonal matrix. N >= 0.\n\
*\n\
* N1 (input) INTEGER\n\
* The location of the last eigenvalue in the leading sub-matrix.\n\
* min(1,N) <= N1 <= N/2.\n\
*\n\
* D (input/output) DOUBLE PRECISION array, dimension (N)\n\
* On entry, D contains the eigenvalues of the two submatrices to\n\
* be combined.\n\
* On exit, D contains the trailing (N-K) updated eigenvalues\n\
* (those which were deflated) sorted into increasing order.\n\
*\n\
* Q (input/output) DOUBLE PRECISION array, dimension (LDQ, N)\n\
* On entry, Q contains the eigenvectors of two submatrices in\n\
* the two square blocks with corners at (1,1), (N1,N1)\n\
* and (N1+1, N1+1), (N,N).\n\
* On exit, Q contains the trailing (N-K) updated eigenvectors\n\
* (those which were deflated) in its last N-K columns.\n\
*\n\
* LDQ (input) INTEGER\n\
* The leading dimension of the array Q. LDQ >= max(1,N).\n\
*\n\
* INDXQ (input/output) INTEGER array, dimension (N)\n\
* The permutation which separately sorts the two sub-problems\n\
* in D into ascending order. Note that elements in the second\n\
* half of this permutation must first have N1 added to their\n\
* values. Destroyed on exit.\n\
*\n\
* RHO (input/output) DOUBLE PRECISION\n\
* On entry, the off-diagonal element associated with the rank-1\n\
* cut which originally split the two submatrices which are now\n\
* being recombined.\n\
* On exit, RHO has been modified to the value required by\n\
* DLAED3.\n\
*\n\
* Z (input) DOUBLE PRECISION array, dimension (N)\n\
* On entry, Z contains the updating vector (the last\n\
* row of the first sub-eigenvector matrix and the first row of\n\
* the second sub-eigenvector matrix).\n\
* On exit, the contents of Z have been destroyed by the updating\n\
* process.\n\
*\n\
* DLAMDA (output) DOUBLE PRECISION array, dimension (N)\n\
* A copy of the first K eigenvalues which will be used by\n\
* DLAED3 to form the secular equation.\n\
*\n\
* W (output) DOUBLE PRECISION array, dimension (N)\n\
* The first k values of the final deflation-altered z-vector\n\
* which will be passed to DLAED3.\n\
*\n\
* Q2 (output) DOUBLE PRECISION array, dimension (N1**2+(N-N1)**2)\n\
* A copy of the first K eigenvectors which will be used by\n\
* DLAED3 in a matrix multiply (DGEMM) to solve for the new\n\
* eigenvectors.\n\
*\n\
* INDX (workspace) INTEGER array, dimension (N)\n\
* The permutation used to sort the contents of DLAMDA into\n\
* ascending order.\n\
*\n\
* INDXC (output) INTEGER array, dimension (N)\n\
* The permutation used to arrange the columns of the deflated\n\
* Q matrix into three groups: the first group contains non-zero\n\
* elements only at and above N1, the second contains\n\
* non-zero elements only below N1, and the third is dense.\n\
*\n\
* INDXP (workspace) INTEGER array, dimension (N)\n\
* The permutation used to place deflated values of D at the end\n\
* of the array. INDXP(1:K) points to the nondeflated D-values\n\
* and INDXP(K+1:N) points to the deflated eigenvalues.\n\
*\n\
* COLTYP (workspace/output) INTEGER array, dimension (N)\n\
* During execution, a label which will indicate which of the\n\
* following types a column in the Q2 matrix is:\n\
* 1 : non-zero in the upper half only;\n\
* 2 : dense;\n\
* 3 : non-zero in the lower half only;\n\
* 4 : deflated.\n\
* On exit, COLTYP(i) is the number of columns of type i,\n\
* for i=1 to 4 only.\n\
*\n\
* INFO (output) INTEGER\n\
* = 0: successful exit.\n\
* < 0: if INFO = -i, the i-th argument had an illegal value.\n\
*\n\n\
* Further Details\n\
* ===============\n\
*\n\
* Based on contributions by\n\
* Jeff Rutter, Computer Science Division, University of California\n\
* at Berkeley, USA\n\
* Modified by Francoise Tisseur, University of Tennessee.\n\
*\n\
* =====================================================================\n\
*\n"
|