dlaln2.c
Go to the documentation of this file.
00001 /* dlaln2.f -- translated by f2c (version 20061008).
00002    You must link the resulting object file with libf2c:
00003         on Microsoft Windows system, link with libf2c.lib;
00004         on Linux or Unix systems, link with .../path/to/libf2c.a -lm
00005         or, if you install libf2c.a in a standard place, with -lf2c -lm
00006         -- in that order, at the end of the command line, as in
00007                 cc *.o -lf2c -lm
00008         Source for libf2c is in /netlib/f2c/libf2c.zip, e.g.,
00009 
00010                 http://www.netlib.org/f2c/libf2c.zip
00011 */
00012 
00013 #include "f2c.h"
00014 #include "blaswrap.h"
00015 
00016 /* Subroutine */ int dlaln2_(logical *ltrans, integer *na, integer *nw, 
00017         doublereal *smin, doublereal *ca, doublereal *a, integer *lda, 
00018         doublereal *d1, doublereal *d2, doublereal *b, integer *ldb, 
00019         doublereal *wr, doublereal *wi, doublereal *x, integer *ldx, 
00020         doublereal *scale, doublereal *xnorm, integer *info)
00021 {
00022     /* Initialized data */
00023 
00024     static logical zswap[4] = { FALSE_,FALSE_,TRUE_,TRUE_ };
00025     static logical rswap[4] = { FALSE_,TRUE_,FALSE_,TRUE_ };
00026     static integer ipivot[16]   /* was [4][4] */ = { 1,2,3,4,2,1,4,3,3,4,1,2,
00027             4,3,2,1 };
00028 
00029     /* System generated locals */
00030     integer a_dim1, a_offset, b_dim1, b_offset, x_dim1, x_offset;
00031     doublereal d__1, d__2, d__3, d__4, d__5, d__6;
00032     static doublereal equiv_0[4], equiv_1[4];
00033 
00034     /* Local variables */
00035     integer j;
00036 #define ci (equiv_0)
00037 #define cr (equiv_1)
00038     doublereal bi1, bi2, br1, br2, xi1, xi2, xr1, xr2, ci21, ci22, cr21, cr22,
00039              li21, csi, ui11, lr21, ui12, ui22;
00040 #define civ (equiv_0)
00041     doublereal csr, ur11, ur12, ur22;
00042 #define crv (equiv_1)
00043     doublereal bbnd, cmax, ui11r, ui12s, temp, ur11r, ur12s, u22abs;
00044     integer icmax;
00045     doublereal bnorm, cnorm, smini;
00046     extern doublereal dlamch_(char *);
00047     extern /* Subroutine */ int dladiv_(doublereal *, doublereal *, 
00048             doublereal *, doublereal *, doublereal *, doublereal *);
00049     doublereal bignum, smlnum;
00050 
00051 
00052 /*  -- LAPACK auxiliary routine (version 3.2) -- */
00053 /*     Univ. of Tennessee, Univ. of California Berkeley and NAG Ltd.. */
00054 /*     November 2006 */
00055 
00056 /*     .. Scalar Arguments .. */
00057 /*     .. */
00058 /*     .. Array Arguments .. */
00059 /*     .. */
00060 
00061 /*  Purpose */
00062 /*  ======= */
00063 
00064 /*  DLALN2 solves a system of the form  (ca A - w D ) X = s B */
00065 /*  or (ca A' - w D) X = s B   with possible scaling ("s") and */
00066 /*  perturbation of A.  (A' means A-transpose.) */
00067 
00068 /*  A is an NA x NA real matrix, ca is a real scalar, D is an NA x NA */
00069 /*  real diagonal matrix, w is a real or complex value, and X and B are */
00070 /*  NA x 1 matrices -- real if w is real, complex if w is complex.  NA */
00071 /*  may be 1 or 2. */
00072 
00073 /*  If w is complex, X and B are represented as NA x 2 matrices, */
00074 /*  the first column of each being the real part and the second */
00075 /*  being the imaginary part. */
00076 
00077 /*  "s" is a scaling factor (.LE. 1), computed by DLALN2, which is */
00078 /*  so chosen that X can be computed without overflow.  X is further */
00079 /*  scaled if necessary to assure that norm(ca A - w D)*norm(X) is less */
00080 /*  than overflow. */
00081 
00082 /*  If both singular values of (ca A - w D) are less than SMIN, */
00083 /*  SMIN*identity will be used instead of (ca A - w D).  If only one */
00084 /*  singular value is less than SMIN, one element of (ca A - w D) will be */
00085 /*  perturbed enough to make the smallest singular value roughly SMIN. */
00086 /*  If both singular values are at least SMIN, (ca A - w D) will not be */
00087 /*  perturbed.  In any case, the perturbation will be at most some small */
00088 /*  multiple of max( SMIN, ulp*norm(ca A - w D) ).  The singular values */
00089 /*  are computed by infinity-norm approximations, and thus will only be */
00090 /*  correct to a factor of 2 or so. */
00091 
00092 /*  Note: all input quantities are assumed to be smaller than overflow */
00093 /*  by a reasonable factor.  (See BIGNUM.) */
00094 
00095 /*  Arguments */
00096 /*  ========== */
00097 
00098 /*  LTRANS  (input) LOGICAL */
00099 /*          =.TRUE.:  A-transpose will be used. */
00100 /*          =.FALSE.: A will be used (not transposed.) */
00101 
00102 /*  NA      (input) INTEGER */
00103 /*          The size of the matrix A.  It may (only) be 1 or 2. */
00104 
00105 /*  NW      (input) INTEGER */
00106 /*          1 if "w" is real, 2 if "w" is complex.  It may only be 1 */
00107 /*          or 2. */
00108 
00109 /*  SMIN    (input) DOUBLE PRECISION */
00110 /*          The desired lower bound on the singular values of A.  This */
00111 /*          should be a safe distance away from underflow or overflow, */
00112 /*          say, between (underflow/machine precision) and  (machine */
00113 /*          precision * overflow ).  (See BIGNUM and ULP.) */
00114 
00115 /*  CA      (input) DOUBLE PRECISION */
00116 /*          The coefficient c, which A is multiplied by. */
00117 
00118 /*  A       (input) DOUBLE PRECISION array, dimension (LDA,NA) */
00119 /*          The NA x NA matrix A. */
00120 
00121 /*  LDA     (input) INTEGER */
00122 /*          The leading dimension of A.  It must be at least NA. */
00123 
00124 /*  D1      (input) DOUBLE PRECISION */
00125 /*          The 1,1 element in the diagonal matrix D. */
00126 
00127 /*  D2      (input) DOUBLE PRECISION */
00128 /*          The 2,2 element in the diagonal matrix D.  Not used if NW=1. */
00129 
00130 /*  B       (input) DOUBLE PRECISION array, dimension (LDB,NW) */
00131 /*          The NA x NW matrix B (right-hand side).  If NW=2 ("w" is */
00132 /*          complex), column 1 contains the real part of B and column 2 */
00133 /*          contains the imaginary part. */
00134 
00135 /*  LDB     (input) INTEGER */
00136 /*          The leading dimension of B.  It must be at least NA. */
00137 
00138 /*  WR      (input) DOUBLE PRECISION */
00139 /*          The real part of the scalar "w". */
00140 
00141 /*  WI      (input) DOUBLE PRECISION */
00142 /*          The imaginary part of the scalar "w".  Not used if NW=1. */
00143 
00144 /*  X       (output) DOUBLE PRECISION array, dimension (LDX,NW) */
00145 /*          The NA x NW matrix X (unknowns), as computed by DLALN2. */
00146 /*          If NW=2 ("w" is complex), on exit, column 1 will contain */
00147 /*          the real part of X and column 2 will contain the imaginary */
00148 /*          part. */
00149 
00150 /*  LDX     (input) INTEGER */
00151 /*          The leading dimension of X.  It must be at least NA. */
00152 
00153 /*  SCALE   (output) DOUBLE PRECISION */
00154 /*          The scale factor that B must be multiplied by to insure */
00155 /*          that overflow does not occur when computing X.  Thus, */
00156 /*          (ca A - w D) X  will be SCALE*B, not B (ignoring */
00157 /*          perturbations of A.)  It will be at most 1. */
00158 
00159 /*  XNORM   (output) DOUBLE PRECISION */
00160 /*          The infinity-norm of X, when X is regarded as an NA x NW */
00161 /*          real matrix. */
00162 
00163 /*  INFO    (output) INTEGER */
00164 /*          An error flag.  It will be set to zero if no error occurs, */
00165 /*          a negative number if an argument is in error, or a positive */
00166 /*          number if  ca A - w D  had to be perturbed. */
00167 /*          The possible values are: */
00168 /*          = 0: No error occurred, and (ca A - w D) did not have to be */
00169 /*                 perturbed. */
00170 /*          = 1: (ca A - w D) had to be perturbed to make its smallest */
00171 /*               (or only) singular value greater than SMIN. */
00172 /*          NOTE: In the interests of speed, this routine does not */
00173 /*                check the inputs for errors. */
00174 
00175 /* ===================================================================== */
00176 
00177 /*     .. Parameters .. */
00178 /*     .. */
00179 /*     .. Local Scalars .. */
00180 /*     .. */
00181 /*     .. Local Arrays .. */
00182 /*     .. */
00183 /*     .. External Functions .. */
00184 /*     .. */
00185 /*     .. External Subroutines .. */
00186 /*     .. */
00187 /*     .. Intrinsic Functions .. */
00188 /*     .. */
00189 /*     .. Equivalences .. */
00190 /*     .. */
00191 /*     .. Data statements .. */
00192     /* Parameter adjustments */
00193     a_dim1 = *lda;
00194     a_offset = 1 + a_dim1;
00195     a -= a_offset;
00196     b_dim1 = *ldb;
00197     b_offset = 1 + b_dim1;
00198     b -= b_offset;
00199     x_dim1 = *ldx;
00200     x_offset = 1 + x_dim1;
00201     x -= x_offset;
00202 
00203     /* Function Body */
00204 /*     .. */
00205 /*     .. Executable Statements .. */
00206 
00207 /*     Compute BIGNUM */
00208 
00209     smlnum = 2. * dlamch_("Safe minimum");
00210     bignum = 1. / smlnum;
00211     smini = max(*smin,smlnum);
00212 
00213 /*     Don't check for input errors */
00214 
00215     *info = 0;
00216 
00217 /*     Standard Initializations */
00218 
00219     *scale = 1.;
00220 
00221     if (*na == 1) {
00222 
00223 /*        1 x 1  (i.e., scalar) system   C X = B */
00224 
00225         if (*nw == 1) {
00226 
00227 /*           Real 1x1 system. */
00228 
00229 /*           C = ca A - w D */
00230 
00231             csr = *ca * a[a_dim1 + 1] - *wr * *d1;
00232             cnorm = abs(csr);
00233 
00234 /*           If | C | < SMINI, use C = SMINI */
00235 
00236             if (cnorm < smini) {
00237                 csr = smini;
00238                 cnorm = smini;
00239                 *info = 1;
00240             }
00241 
00242 /*           Check scaling for  X = B / C */
00243 
00244             bnorm = (d__1 = b[b_dim1 + 1], abs(d__1));
00245             if (cnorm < 1. && bnorm > 1.) {
00246                 if (bnorm > bignum * cnorm) {
00247                     *scale = 1. / bnorm;
00248                 }
00249             }
00250 
00251 /*           Compute X */
00252 
00253             x[x_dim1 + 1] = b[b_dim1 + 1] * *scale / csr;
00254             *xnorm = (d__1 = x[x_dim1 + 1], abs(d__1));
00255         } else {
00256 
00257 /*           Complex 1x1 system (w is complex) */
00258 
00259 /*           C = ca A - w D */
00260 
00261             csr = *ca * a[a_dim1 + 1] - *wr * *d1;
00262             csi = -(*wi) * *d1;
00263             cnorm = abs(csr) + abs(csi);
00264 
00265 /*           If | C | < SMINI, use C = SMINI */
00266 
00267             if (cnorm < smini) {
00268                 csr = smini;
00269                 csi = 0.;
00270                 cnorm = smini;
00271                 *info = 1;
00272             }
00273 
00274 /*           Check scaling for  X = B / C */
00275 
00276             bnorm = (d__1 = b[b_dim1 + 1], abs(d__1)) + (d__2 = b[(b_dim1 << 
00277                     1) + 1], abs(d__2));
00278             if (cnorm < 1. && bnorm > 1.) {
00279                 if (bnorm > bignum * cnorm) {
00280                     *scale = 1. / bnorm;
00281                 }
00282             }
00283 
00284 /*           Compute X */
00285 
00286             d__1 = *scale * b[b_dim1 + 1];
00287             d__2 = *scale * b[(b_dim1 << 1) + 1];
00288             dladiv_(&d__1, &d__2, &csr, &csi, &x[x_dim1 + 1], &x[(x_dim1 << 1)
00289                      + 1]);
00290             *xnorm = (d__1 = x[x_dim1 + 1], abs(d__1)) + (d__2 = x[(x_dim1 << 
00291                     1) + 1], abs(d__2));
00292         }
00293 
00294     } else {
00295 
00296 /*        2x2 System */
00297 
00298 /*        Compute the real part of  C = ca A - w D  (or  ca A' - w D ) */
00299 
00300         cr[0] = *ca * a[a_dim1 + 1] - *wr * *d1;
00301         cr[3] = *ca * a[(a_dim1 << 1) + 2] - *wr * *d2;
00302         if (*ltrans) {
00303             cr[2] = *ca * a[a_dim1 + 2];
00304             cr[1] = *ca * a[(a_dim1 << 1) + 1];
00305         } else {
00306             cr[1] = *ca * a[a_dim1 + 2];
00307             cr[2] = *ca * a[(a_dim1 << 1) + 1];
00308         }
00309 
00310         if (*nw == 1) {
00311 
00312 /*           Real 2x2 system  (w is real) */
00313 
00314 /*           Find the largest element in C */
00315 
00316             cmax = 0.;
00317             icmax = 0;
00318 
00319             for (j = 1; j <= 4; ++j) {
00320                 if ((d__1 = crv[j - 1], abs(d__1)) > cmax) {
00321                     cmax = (d__1 = crv[j - 1], abs(d__1));
00322                     icmax = j;
00323                 }
00324 /* L10: */
00325             }
00326 
00327 /*           If norm(C) < SMINI, use SMINI*identity. */
00328 
00329             if (cmax < smini) {
00330 /* Computing MAX */
00331                 d__3 = (d__1 = b[b_dim1 + 1], abs(d__1)), d__4 = (d__2 = b[
00332                         b_dim1 + 2], abs(d__2));
00333                 bnorm = max(d__3,d__4);
00334                 if (smini < 1. && bnorm > 1.) {
00335                     if (bnorm > bignum * smini) {
00336                         *scale = 1. / bnorm;
00337                     }
00338                 }
00339                 temp = *scale / smini;
00340                 x[x_dim1 + 1] = temp * b[b_dim1 + 1];
00341                 x[x_dim1 + 2] = temp * b[b_dim1 + 2];
00342                 *xnorm = temp * bnorm;
00343                 *info = 1;
00344                 return 0;
00345             }
00346 
00347 /*           Gaussian elimination with complete pivoting. */
00348 
00349             ur11 = crv[icmax - 1];
00350             cr21 = crv[ipivot[(icmax << 2) - 3] - 1];
00351             ur12 = crv[ipivot[(icmax << 2) - 2] - 1];
00352             cr22 = crv[ipivot[(icmax << 2) - 1] - 1];
00353             ur11r = 1. / ur11;
00354             lr21 = ur11r * cr21;
00355             ur22 = cr22 - ur12 * lr21;
00356 
00357 /*           If smaller pivot < SMINI, use SMINI */
00358 
00359             if (abs(ur22) < smini) {
00360                 ur22 = smini;
00361                 *info = 1;
00362             }
00363             if (rswap[icmax - 1]) {
00364                 br1 = b[b_dim1 + 2];
00365                 br2 = b[b_dim1 + 1];
00366             } else {
00367                 br1 = b[b_dim1 + 1];
00368                 br2 = b[b_dim1 + 2];
00369             }
00370             br2 -= lr21 * br1;
00371 /* Computing MAX */
00372             d__2 = (d__1 = br1 * (ur22 * ur11r), abs(d__1)), d__3 = abs(br2);
00373             bbnd = max(d__2,d__3);
00374             if (bbnd > 1. && abs(ur22) < 1.) {
00375                 if (bbnd >= bignum * abs(ur22)) {
00376                     *scale = 1. / bbnd;
00377                 }
00378             }
00379 
00380             xr2 = br2 * *scale / ur22;
00381             xr1 = *scale * br1 * ur11r - xr2 * (ur11r * ur12);
00382             if (zswap[icmax - 1]) {
00383                 x[x_dim1 + 1] = xr2;
00384                 x[x_dim1 + 2] = xr1;
00385             } else {
00386                 x[x_dim1 + 1] = xr1;
00387                 x[x_dim1 + 2] = xr2;
00388             }
00389 /* Computing MAX */
00390             d__1 = abs(xr1), d__2 = abs(xr2);
00391             *xnorm = max(d__1,d__2);
00392 
00393 /*           Further scaling if  norm(A) norm(X) > overflow */
00394 
00395             if (*xnorm > 1. && cmax > 1.) {
00396                 if (*xnorm > bignum / cmax) {
00397                     temp = cmax / bignum;
00398                     x[x_dim1 + 1] = temp * x[x_dim1 + 1];
00399                     x[x_dim1 + 2] = temp * x[x_dim1 + 2];
00400                     *xnorm = temp * *xnorm;
00401                     *scale = temp * *scale;
00402                 }
00403             }
00404         } else {
00405 
00406 /*           Complex 2x2 system  (w is complex) */
00407 
00408 /*           Find the largest element in C */
00409 
00410             ci[0] = -(*wi) * *d1;
00411             ci[1] = 0.;
00412             ci[2] = 0.;
00413             ci[3] = -(*wi) * *d2;
00414             cmax = 0.;
00415             icmax = 0;
00416 
00417             for (j = 1; j <= 4; ++j) {
00418                 if ((d__1 = crv[j - 1], abs(d__1)) + (d__2 = civ[j - 1], abs(
00419                         d__2)) > cmax) {
00420                     cmax = (d__1 = crv[j - 1], abs(d__1)) + (d__2 = civ[j - 1]
00421                             , abs(d__2));
00422                     icmax = j;
00423                 }
00424 /* L20: */
00425             }
00426 
00427 /*           If norm(C) < SMINI, use SMINI*identity. */
00428 
00429             if (cmax < smini) {
00430 /* Computing MAX */
00431                 d__5 = (d__1 = b[b_dim1 + 1], abs(d__1)) + (d__2 = b[(b_dim1 
00432                         << 1) + 1], abs(d__2)), d__6 = (d__3 = b[b_dim1 + 2], 
00433                         abs(d__3)) + (d__4 = b[(b_dim1 << 1) + 2], abs(d__4));
00434                 bnorm = max(d__5,d__6);
00435                 if (smini < 1. && bnorm > 1.) {
00436                     if (bnorm > bignum * smini) {
00437                         *scale = 1. / bnorm;
00438                     }
00439                 }
00440                 temp = *scale / smini;
00441                 x[x_dim1 + 1] = temp * b[b_dim1 + 1];
00442                 x[x_dim1 + 2] = temp * b[b_dim1 + 2];
00443                 x[(x_dim1 << 1) + 1] = temp * b[(b_dim1 << 1) + 1];
00444                 x[(x_dim1 << 1) + 2] = temp * b[(b_dim1 << 1) + 2];
00445                 *xnorm = temp * bnorm;
00446                 *info = 1;
00447                 return 0;
00448             }
00449 
00450 /*           Gaussian elimination with complete pivoting. */
00451 
00452             ur11 = crv[icmax - 1];
00453             ui11 = civ[icmax - 1];
00454             cr21 = crv[ipivot[(icmax << 2) - 3] - 1];
00455             ci21 = civ[ipivot[(icmax << 2) - 3] - 1];
00456             ur12 = crv[ipivot[(icmax << 2) - 2] - 1];
00457             ui12 = civ[ipivot[(icmax << 2) - 2] - 1];
00458             cr22 = crv[ipivot[(icmax << 2) - 1] - 1];
00459             ci22 = civ[ipivot[(icmax << 2) - 1] - 1];
00460             if (icmax == 1 || icmax == 4) {
00461 
00462 /*              Code when off-diagonals of pivoted C are real */
00463 
00464                 if (abs(ur11) > abs(ui11)) {
00465                     temp = ui11 / ur11;
00466 /* Computing 2nd power */
00467                     d__1 = temp;
00468                     ur11r = 1. / (ur11 * (d__1 * d__1 + 1.));
00469                     ui11r = -temp * ur11r;
00470                 } else {
00471                     temp = ur11 / ui11;
00472 /* Computing 2nd power */
00473                     d__1 = temp;
00474                     ui11r = -1. / (ui11 * (d__1 * d__1 + 1.));
00475                     ur11r = -temp * ui11r;
00476                 }
00477                 lr21 = cr21 * ur11r;
00478                 li21 = cr21 * ui11r;
00479                 ur12s = ur12 * ur11r;
00480                 ui12s = ur12 * ui11r;
00481                 ur22 = cr22 - ur12 * lr21;
00482                 ui22 = ci22 - ur12 * li21;
00483             } else {
00484 
00485 /*              Code when diagonals of pivoted C are real */
00486 
00487                 ur11r = 1. / ur11;
00488                 ui11r = 0.;
00489                 lr21 = cr21 * ur11r;
00490                 li21 = ci21 * ur11r;
00491                 ur12s = ur12 * ur11r;
00492                 ui12s = ui12 * ur11r;
00493                 ur22 = cr22 - ur12 * lr21 + ui12 * li21;
00494                 ui22 = -ur12 * li21 - ui12 * lr21;
00495             }
00496             u22abs = abs(ur22) + abs(ui22);
00497 
00498 /*           If smaller pivot < SMINI, use SMINI */
00499 
00500             if (u22abs < smini) {
00501                 ur22 = smini;
00502                 ui22 = 0.;
00503                 *info = 1;
00504             }
00505             if (rswap[icmax - 1]) {
00506                 br2 = b[b_dim1 + 1];
00507                 br1 = b[b_dim1 + 2];
00508                 bi2 = b[(b_dim1 << 1) + 1];
00509                 bi1 = b[(b_dim1 << 1) + 2];
00510             } else {
00511                 br1 = b[b_dim1 + 1];
00512                 br2 = b[b_dim1 + 2];
00513                 bi1 = b[(b_dim1 << 1) + 1];
00514                 bi2 = b[(b_dim1 << 1) + 2];
00515             }
00516             br2 = br2 - lr21 * br1 + li21 * bi1;
00517             bi2 = bi2 - li21 * br1 - lr21 * bi1;
00518 /* Computing MAX */
00519             d__1 = (abs(br1) + abs(bi1)) * (u22abs * (abs(ur11r) + abs(ui11r))
00520                     ), d__2 = abs(br2) + abs(bi2);
00521             bbnd = max(d__1,d__2);
00522             if (bbnd > 1. && u22abs < 1.) {
00523                 if (bbnd >= bignum * u22abs) {
00524                     *scale = 1. / bbnd;
00525                     br1 = *scale * br1;
00526                     bi1 = *scale * bi1;
00527                     br2 = *scale * br2;
00528                     bi2 = *scale * bi2;
00529                 }
00530             }
00531 
00532             dladiv_(&br2, &bi2, &ur22, &ui22, &xr2, &xi2);
00533             xr1 = ur11r * br1 - ui11r * bi1 - ur12s * xr2 + ui12s * xi2;
00534             xi1 = ui11r * br1 + ur11r * bi1 - ui12s * xr2 - ur12s * xi2;
00535             if (zswap[icmax - 1]) {
00536                 x[x_dim1 + 1] = xr2;
00537                 x[x_dim1 + 2] = xr1;
00538                 x[(x_dim1 << 1) + 1] = xi2;
00539                 x[(x_dim1 << 1) + 2] = xi1;
00540             } else {
00541                 x[x_dim1 + 1] = xr1;
00542                 x[x_dim1 + 2] = xr2;
00543                 x[(x_dim1 << 1) + 1] = xi1;
00544                 x[(x_dim1 << 1) + 2] = xi2;
00545             }
00546 /* Computing MAX */
00547             d__1 = abs(xr1) + abs(xi1), d__2 = abs(xr2) + abs(xi2);
00548             *xnorm = max(d__1,d__2);
00549 
00550 /*           Further scaling if  norm(A) norm(X) > overflow */
00551 
00552             if (*xnorm > 1. && cmax > 1.) {
00553                 if (*xnorm > bignum / cmax) {
00554                     temp = cmax / bignum;
00555                     x[x_dim1 + 1] = temp * x[x_dim1 + 1];
00556                     x[x_dim1 + 2] = temp * x[x_dim1 + 2];
00557                     x[(x_dim1 << 1) + 1] = temp * x[(x_dim1 << 1) + 1];
00558                     x[(x_dim1 << 1) + 2] = temp * x[(x_dim1 << 1) + 2];
00559                     *xnorm = temp * *xnorm;
00560                     *scale = temp * *scale;
00561                 }
00562             }
00563         }
00564     }
00565 
00566     return 0;
00567 
00568 /*     End of DLALN2 */
00569 
00570 } /* dlaln2_ */
00571 
00572 #undef crv
00573 #undef civ
00574 #undef cr
00575 #undef ci


swiftnav
Author(s):
autogenerated on Sat Jun 8 2019 18:55:46