Uses extra precise iterative refinement to improve the solution to the system of linear equations with a banded coefficient matrix A and provides error bounds and backward error estimates.
The routine improves the computed solution to a system of linear equations and provides error bounds and backward error estimates for the solution. In addition to a normwise error bound, the code provides a maximum componentwise error bound, if possible. See comments for
err_bnds_compfor details of the error bounds.
The original system of linear equations may have been equilibrated before calling this routine, as described by the parameters
cbelow. In this case, the solution and error bounds returned are for the original unequilibrated system.
- Specifies whether two-dimensional array storage is row major (LAPACK_ROW_MAJOR) or column major (LAPACK_COL_MAJOR).
- Must be'N','T', or'C'.Specifies the form of the system of equations:If, the system has the formtrans='N'(No transpose).A*X=BIf, the system has the formtrans='T'(Transpose).AT*X=BIf, the system has the formtrans='C'(Conjugate transpose for complex flavors, Transpose for real flavors).AH*X=B
- Must be'N','R','C', or'B'.Specifies the form of equilibration that was done toAbefore calling this routine.If, no equilibration was done.equed='N'If, row equilibration was done, that is,equed='R'Ahas been premultiplied bydiag(r).If, column equilibration was done, that is,equed='C'Ahas been postmultiplied bydiag(c).If, both row and column equilibration was done, that is,equed='B'Ahas been replaced by. The right-hand sidediag(r)*A*diag(c)Bhas been changed accordingly.
- The number of linear equations; the order of the matrixA;n≥0.
- The number of subdiagonals within the band ofA;kl≥0.
- The number of superdiagonals within the band ofA;ku≥0.
- The number of right-hand sides; the number of columns of the matricesBandX;nrhs≥0.
- The arrayabof size max(1,contains the original matrixldab*n)Ain band storage, in rows from 1 tokl+ku+ 1 for column major layout, and in columns from 1 tokl+ku+ 1 for row major layout.The arrayafbof size max(1,contains details of the LU factorization of the banded matrixldafb*n)Aas computed by?gbtrf.The arraybof size max(1,contains the matrixldb*nrhs) for column major layout and max(1,ldb*n) for row major layoutBwhose columns are the right-hand sides for the systems of equations.
- The leading dimension of the arrayab;.ldab≥kl+ku+1
- The leading dimension of the arrayafb;.ldafb≥2*kl+ku+1
- Arrays:,r(n). The arrayc(n)rcontains the row scale factors forA, and the arrayccontains the column scale factors forA.Iforequed='R''B',Ais multiplied on the left bydiag(r); iforequed='N''C',ris not accessed.Iforequed='R''B', each element ofrmust be positive.Iforequed='C''B',Ais multiplied on the right bydiag(c); iforequed='N''R',cis not accessed.Iforequed='C''B', each element ofcmust be positive.Each element ofrorcshould be a power of the radix to ensure a reliable solution and error estimates. Scaling by powers of the radix does not cause rounding errors unless the result underflows or overflows. Rounding errors during scaling lead to refining with a matrix that is not equivalent to the input matrix, producing error estimates that may not be reliable.
- The leading dimension of the arrayb;.ldb≥max(1,n) for column major layout andldb≥nrhsfor row major layout
- The leading dimension of the output arrayx;.ldx≥max(1,n) for column major layout andldx≥nrhsfor row major layout
- Number of error bounds to return for each right-hand side and each type (normwise or componentwise). Seeerr_bnds_normanderr_bnds_compdescriptions inOutput Argumentssection below.
- Specifies the number of parameters set inparams. If≤0, theparamsarray is never referenced and default values are used.
- Array, sizenparams. Specifies algorithm parameters. If an entry is less than 0.0, that entry will be filled with the default value used for that parameter. Only positions up tonparamsare accessed; defaults are used for higher-numbered parameters. If defaults are acceptable, you can passnparams= 0, which prevents the source code from accessing theparamsargument.: Whether to perform iterative refinement or not. Default: 1.0 (for single precision flavors), 1.0D+0 (for double precision flavors).params
(Other values are reserved for future use.): Maximum number of residual computations allowed for refinement.params
- No refinement is performed and no error bounds are computed.
- Use the double-precision refinement algorithm, possibly with doubled-single computations if the compilation environment does not support double precision.
: Flag determining if the code will attempt to find a solution with a small componentwise relative error in the double-precision algorithm. Positive is true, 0.0 is false. Default: 1.0 (attempt componentwise convergence).params
- Set to 100.0 to permit convergence using approximate factorizations or factorizations other thanLU. If the factorization uses a technique other than Gaussian elimination, the guarantees inerr_bnds_normanderr_bnds_compmay no longer be trustworthy.
- The improved solution matrixX.
- Reciprocal scaled condition number. An estimate of the reciprocal Skeel condition number of the matrixAafter equilibration (if done). Ifrcondis less than the machine precision, in particular, ifrcond= 0, the matrix is singular to working precision. Note that the error may still be small even if this number is very small and the matrix appears ill-conditioned.
- Array, size at leastmax(1,. Contains the componentwise relative backward error for each solution vectornrhs), that is, the smallest relative change in any element ofxjAorBthat makesan exact solution.xj
- Array of size. For each right-hand side, contains information about various error bounds and condition numbers corresponding to the normwise relative errornrhs*n_err_bnds, which is defined as follows:Normwise relative error in thei-th solution vectorThe array is indexed by the type of error information as described below. There are currently up to three pieces of information returned.
- "Trust/don't trust" boolean. Trust the answer if the reciprocal condition number is less than the thresholdfor single precision flavors andsqrt(n)*slamch(ε)sqrt(n)*