Contents

# ?gbsv

Computes the solution to the system of linear equations with a band coefficient matrix A and multiple right-hand sides.

## Syntax

Include Files
• mkl.h
Description
The routine solves for
X
the real or complex system of linear equations
A*X
=
B
, where
A
is an
n
-by-
n
band matrix with
kl
subdiagonals and
ku
superdiagonals, the columns of matrix
B
are individual right-hand sides, and the columns of
X
are the corresponding solutions.
The
LU
decomposition with partial pivoting and row interchanges is used to factor
A
as
A
=
L*U
, where
L
is a product of permutation and unit lower triangular matrices with
kl
subdiagonals, and
U
is upper triangular with
kl
+
ku
superdiagonals. The factored form of
A
is then used to solve the system of equations
A*X
=
B
.
Input Parameters
matrix_layout
Specifies whether matrix storage layout is row major (
LAPACK_ROW_MAJOR
) or column major (
LAPACK_COL_MAJOR
).
n
The order of
A
. The number of rows in
B
;
n
0.
kl
The number of subdiagonals within the band of
A
;
kl
0.
ku
The number of superdiagonals within the band of
A
;
ku
0.
nrhs
The number of right-hand sides. The number of columns in
B
;
nrhs
0.
ab
,
b
Arrays:
ab
(size max(1,
ldab
*
n
))
,
b
of size max(1,
ldb
*
nrhs
) for column major layout and max(1,
ldb
*
n
) for row major layout
.
The array
ab
contains the matrix
A
in band storage (see Matrix Storage Schemes).
The array
b
contains the matrix
B
whose columns are the right-hand sides for the systems of equations.
ldab
The leading dimension of the array
ab
. (
ldab
2
kl
+
ku
+1)
ldb
b
;
ldb
max(1,
n
) for column major layout and
ldb
nrhs
for row major layout
.
Output Parameters
ab
Overwritten by
L
and
U
.
U
is stored as an upper triangular band matrix with
kl
+
ku
superdiagonals and
L
is stored as a lower triangular band matrix with
kl
subdiagonals. See Matrix Storage Schemes.
b
Overwritten by the solution matrix
X
.
ipiv
Array, size at least
max(1,
n
)
. The pivot indices: row
i
was interchanged with row
ipiv
[
i
-1]
.
Return Values
This function returns a value
info
.
If
info
= 0
, the execution is successful.
If
info
=
-i
, parameter
i
If
info
=
i
,
U
i
,
i
is exactly zero. The factorization has been completed, but the factor
U
is exactly singular, so the solution could not be computed.

#### Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.