HBSMC is a dataset directory which is the Harwell Boeing Sparse Matrix Collection, a representative collection of large sparse matrices gathered from a large variety of application areas.
The matrices in HBSMC can be used to test, verify, and compare algorithms for solving sparse systems of linear equations. There are also some least squares problems and eigenvalue calculations.
The original collection contained just 36 matrices, and those are directly accessible here. For the more recent and much larger collection, you need to refer to the web site.
The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.
DLAP, a FORTRAN90 library which carries out the iterative solution of sparse linear systems, by Anne Greenbaum and Mark Seager.
HB_IO, a C++ library which reads and writes sparse linear systems stored in the Harwell Boeing (HB) format for sparse matrices.
HB_READ, a FORTRAN90 library which reads files in the Harwell Boeing (HB) sparse matrix format; This is a simplified interface intended to handle only the most common format, complex unsymmetric assembled (CUA) or real unsymmetric assembled (RUA).
HB_TO_MM, a MATLAB program which converts a sparse matrix from Harwell Boeing (HB) to Matrix Market (MM) format.
HB_TO_MSM, a MATLAB program which converts a sparse matrix stored in a Harwell Boeing (HB) format to MATLAB sparse matrix format;
HB_TO_ST, a FORTRAN77 program which converts a sparse matrix from Harwell Boeing (HB) format to Sparse Triplet (ST) format.
SUPERLU, a C program which applies a fast direct solution method to sparse linear systems, and can read a matrix that is stored in the Harwell Boeing sparse matrix format.
Code | Pattern | Max Order | Max Nonzeroes | Note |
---|---|---|---|---|
abb313_pra.txt | pattern rectangular assembled | 313x176 | 1557 | Sudan survey |
add20_rua.txt | real unsymmetric assembled | 2395x2395 | 17319 | Steve Hamm 20 bit adder |
arc130_rua.txt | real unsymmetric assembled | 85x85 | 304 | Laser problem |
ash85_psa.txt | pattern symmetric assembled | 85x85 | 304 | Holland survey |
ash219_pra.txt | pattern rectangular assembled | 219x85 | 438 | Survey of Holland |
ash292_psa.txt | pattern symmetric assembled | 292x292 | 1250 | UK survey |
ash331_pra.txt | pattern rectangular assembled | 331x104 | 662 | Scotland survey |
ash608_pra.txt | pattern rectangular assembled | 608x188 | 1216 | England survey |
ash958_pra.txt | pattern rectangular assembled | 958x292 | 1916 | UK survey |
bp_0000_rua.txt | real unsymmetric assembled | 822x822 | 3276 | Simplex method basis |
bp_0200_rua.txt | real unsymmetric assembled | 822x822 | 3802 | Simplex method basis |
bp_0400_rua.txt | real unsymmetric assembled | 822x822 | 4028 | Simplex method basis |
bp_0600_rua.txt | real unsymmetric assembled | 822x822 | 4172 | Simplex method basis |
bp_0800.txt | real unsymmetric assembled | 822x822 | 4534 | Simplex method basis |
bp_1000.txt | real unsymmetric assembled | 822x822 | 4661 | Simplex method basis |
bp_1200.txt | real unsymmetric assembled | 822x822 | 4726 | Simplex method basis |
bp_1400.txt | real unsymmetric assembled | 822x822 | 4790 | Simplex method basis |
bp_1600.txt | real unsymmetric assembled | 822x822 | 4841 | Simplex method basis |
cannes24_psa.txt | pattern symmetric assembled | 24x24 | 92 | Lucien Marro symmetric pattern |
cg05_cua.txt | complex unsymmetric assembled | 25x25 | 105 | Complex test matrix for SUPERLU |
cg10_cua.txt | complex unsymmetric assembled | 100x100 | 460 | Complex test matrix for SUPERLU |
cg20_cua.txt | complex unsymmetric assembled | 400x400 | 1920 | Complex test matrix for SUPERLU |
cmat_cua.txt | complex unsymmetric assembled | 1280x1280 | 22778 | Complex test matrix for SuperLU |
curtis54_pua.txt | pattern unsymmetric assembled | 54x54 | 291 | Stiff biochemical ODE's |
dwg961a_cua.txt | complex unsymmetric assembled | 961x961 | 3405 | Dispersive waveguide structures |
eris1176_psa.txt | pattern symmetric assembled | 1176x1176 | 9864 | Electrical network |
fs_541_1_rua.txt | real unsymmetric assembled | 541x541 | 4285 | Stage 1 of stiff atmospheric ODE |
fs_541_2_rua.txt | real unsymmetric assembled | 541x541 | 4285 | Stage 2 of stiff atmospheric ODE |
fs_541_3_rua.txt | real unsymmetric assembled | 541x541 | 4285 | Stage 3 of stiff atmospheric ODE |
fs_541_4_rua.txt | real unsymmetric assembled | 541x541 | 4285 | Stage 4 of stiff atmospheric ODE |
g05_rua.txt | real unsymmetric assembled | 25x25 | 105 | Real test matrix for SUPERLU |
g10_rua.txt | real unsymmetric assembled | 100x100 | 460 | Real test matrix for SUPERLU |
g20_rua.txt | real unsymmetric assembled | 400x400 | 1920 | Real test matrix for SUPERLU |
gent113_pua.txt | pattern unsymmetric assembled | 113x113 | 655 | Statistical application |
ibm32_pua.txt | pattern unsymmetric assembled | 147x147 | 1298 | IBM conference ad |
illc1033.txt | real rectangular assembled | 1033x320 | 4732 | Unsymmetric least squares problem |
jagmesh1_psa.txt | pattern symmetric assembled | 936x936 | 3600 | George: small hole square |
jagmesh2_psa.txt | pattern symmetric assembled | 1009x1009 | 3937 | George: graded L |
jagmesh3_psa.txt | pattern symmetric assembled | 1089x1089 | 4225 | George: plain square |
jagmesh4_psa.txt | pattern symmetric assembled | 1440x1440 | 5472 | George: large hole square |
jagmesh5_psa.txt | pattern symmetric assembled | 1180x1180 | 4465 | George: plus-shaped region |
jagmesh6_psa.txt | pattern symmetric assembled | 1377x1377 | 5185 | George: H-shaped domain |
jagmesh7_psa.txt | pattern symmetric assembled | 1138x1138 | 4294 | George: 3 hole problem |
jagmesh8_psa.txt | pattern symmetric assembled | 1141x1141 | 4303 | George: 6 hole problem |
jagmesh9_psa.txt | pattern symmetric assembled | 1349x1349 | 5225 | George: pinched hole problem |
lund_a_rsa.txt | real symmetric assembled | 147x147 | 1298 | stiffness and mass |
lund_b_rsa.txt | real symmetric assembled | 147x147 | 1294 | stiffness and mass |
mahindas_rua.txt | real unsymmetric assembled | 1258x1258 | 7682 | Unsymmetric matrix |
mhd1280b_cua.txt | complex unsymmetric assembled | 1280x1280 | 22778 | Alfven sprectra in magnetohydrodynamics |
shl_000_rua.txt | real unsymmetric assembled | 663x663 | 1687 | Simplex method basis |
shl_200_rua.txt | real unsymmetric assembled | 663x663 | 1726 | Simplex method basis |
shl_400_rua.txt | real unsymmetric assembled | 663x663 | 1712 | Simplex method basis |
str_000_rua.txt | real unsymmetric assembled | 363x363 | 2454 | Simplex method basis |
str_200_rua.txt | real unsymmetric assembled | 363x363 | 3068 | Simplex method basis |
str_400_rua.txt | real unsymmetric assembled | 363x363 | 3157 | Simplex method basis |
str_600_rua.txt | real unsymmetric assembled | 363x363 | 3279 | Simplex method basis |
utm300_rua.txt | real unsymmetric assembled | 300x300 | 3155 | UTM |
will57_pua.txt | pattern unsymmetric assembled | 57x57 | 281 | Jacobian of a switch circuit |
will199_pua.txt | pattern unsymmetric assembled | 199x199 | 701 | Stress analysis |
young1c_csa.txt | complex unsymmetric assembled | 841x841 | 4089 | David Young aero research matrix |
The following table lists the contents of the current version of the collection.
Code | Discipline | Matrices | Max Order | Max Nonzeroes |
---|---|---|---|---|
ACOUST | Acoustic scattering | 4 | 841 | 4089 |
AIRTFC | Air traffic control | 1 | 2873 | 15032 |
ASTROPH | Astrophysics | 2 | 765 | 24382 |
BCSPWR | Power network matrices | 14 | 5300 | 13571 |
BCSSTRUC1 | Dynamic analysis in structural engineering | 26 | 2003 | 42943 |
BCSSTRUC2 | Static analysis in structural engineering | 5 | 11948 | 80519 |
BCSSTRUC3 | Structures, eigenproblems | 22 | 15439 | 133840 |
BCSSTRUC4 | Dynamic analysis in structural engineering | 5 | 4410 | 111717 |
BCSSTRUC5 | Structures, linear equations | 36 | 44609 | 1029655 |
BCSSTRUC6 | Structural engineering | 2 | 3345 | 13047 |
CANNES | Finite elements in aircraft design | 18 | 838 | 5424 |
CEGB | Finite elements in structural engineering | 4 | 3306 | 9378 |
CHEMINP | Chemical engineering plant models | 5 | 425 | 1339 |
CHEMWEST | Chemical engineering | 16 | 2021 | 7353 |
CIRPHYS | Circuit physics | 1 | 991 | 6027 |
COUNTERX | Counter examples, small matrices | 3 | 11 | 76 |
DWT | Everstine test set, ship structures | 30 | 2680 | 23853 |
ECONAUS | Australian economic models | 11 | 2529 | 90158 |
ECONIEA | Economic models | 9 | 497x507 | 53403 |
FACSIMILE | Chemical kinetics problems | 10 | 760 | 5976 |
GEMAT | Optimal power flow problems | 3 | 4929 | 47369 |
GRENOBLE | Simulation of Computer Systems | 7 | 1107 | 5664 |
JAGMESH | Finite element model problem | 9 | 1440 | 5472 |
LANPRO | Linear equations in structural engineering | 7 | 960 | 8402 |
LAPLACE | Model PDE problems | 3 | 900 | 4322 |
LAPU | Unassembled Laplace finite element matrices | 1 | 25 | 64 |
LNS | Fluid flow modeling | 7 | 3937 | 25407 |
LOCKHEED | Unassembled structural engineering matrices | 4 | 3491 | 13507 |
LSHAPE | Graded L-shape patterns | 21 | 3466 | 13681 |
LSQ | Least squares surveying problems | 4 | 1850 | 10608 |
MANTEUFFEL | Unassembled finite element matrices | 10 | 5976 | 15680 |
NNCENG | Flow in networks | 1 | 434 | 4710 |
NUCL | Nuclear reactor core modelling | 3 | 1374 | 8606 |
OILGEN | Oil reservoir modelling | 19 | 5005 | 20033 |
PLATZ | Oceanography | 4 | 1919 | 17159 |
PORES | Reservoir modeling | 3 | 1224 | 9613 |
PSADMIT | Power system networks | 4 | 1138 | 2596 |
PSMIGR | Demography | 3 | 3140 | 543162 |
SAYLOR | Oil reservoir modeling | 3 | 3564 | 22316 |
SHERMAN | Oil reservoir modeling | 5 | 5005 | 20033 |
SMTAPE | Original Harwell test set | 36 | 822 | 4841 |
STEAM | Oil recovery | 3 | 600 | 13760 |
WATT | Petroleum Engineering | 2 | 1865 | 11550 |
The Harwell Boeing Sparse Matrix Collection uses a special kind of sparse matrix storage for most of the matrices in the collection.
The standard sparse matrix format is column oriented. That is, the matrix is represented by a sequence of columns. Each column is held as a sparse vector, represented by a list of row indices of the entries in an integer array and a list of the corresponding values in a separate real array. A single integer array and a single real array are used to store the row indices and the values, respectively, for all the columns.
Data for each column are stored in consecutive locations. The columns are stored in order, and there is no space between columns. A separate integer array holds the location of the first entry of each column, and the first free location. For symmetric and Hermitian matrices, only the entries of the lower triangle are stored, including the diagonal. For antisymmetric matrices, only the strict lower triangle is stored.
Here is a simple example of a 5 by 5 matrix:
1.0 -3.0 0.0 -1.0 0.0 0.0 0.0 -2.0 0.0 3.0 2.0 0.0 0.0 0.0 0.0 0.0 4.0 0.0 -4.0 0.0 5.0 0.0 -5.0 0.0 6.0
The Harwell Boeing format essentially thinks of this matrix as a collection of 5 column vectors:
1.0 -3.0 -2.0 -1.0 3.0 2.0 4.0 -5.0 -4.0 6.0 5.0All the entries in a column share the same column index, of course, but to completely identify an entry, we will also need to remember what row it belonged to.
This matrix would be stored in the arrays
Subscripts: 1 2 3 4 5 6 7 8 9 10 11 COLPTR 1 4 6 8 10 12 ROWIND 1 3 5 1 4 2 5 1 4 2 5 VALUES 1.0 2.0 5.0 -3.0 4.0 -2.0 -5.0 -1.0 -4.0 3.0 6.0We can recover column 5 of the original matrix, say, by observing that its first entry is in position COLPTR(5)=10 of arrays ROWIND and VALUES. This entry is in row ROWIND(10)=2 and has value VALUES(10)=3.0. Other entries in column 5 are found by scanning ROWIND and VALUES to position COLPTR(6)-1, that is, position 11. Thus, the only other entry in column 5 is in row ROWIND(11)=5 with value VALUES(11)=6.
The Harwell Boeing finite element storage format is used for those matrices derived from finite element problems.
Matrices arising in finite element applications are usually assembled from numerous small elemental matrices. The collection includes a few sparse matrices in original unassembled form. The storage of the individual unassembled matrices is based on the general sparse format, which stores a matrix as a list of matrix columns. The elemental representation stores the matrix as a list of elemental matrices. Each elemental matrix is represented by a list of the row/column indices (variables) associated with the element and by a small dense matrix giving the numerical values by columns, or in the symmetric case, only the lower triangular part. The lists of indices are held contiguously, just as for the lists of row indices in the standard format. The dense matrices are held contiguously in a separate array, with each matrix held by columns. Although there is not a one to one correspondence between the arrays of integer and numerical values, the representation does not hold the pointers to the beginning of the real values for each element. These pointers can be created from the index start pointers (ELTPTR) after noting that an element with NU variables has NU*NU real values, or (NU*(NU+1))/2 in the symmetric case.
The unassembled finite element storage scheme can be illustrated with a small, 5 by 5 symmetric example matrix:
5.0 0.0 0.0 1.0 2.0 0.0 4.0 3.0 0.0 6.0 0.0 3.0 7.0 8.0 1.0 1.0 0.0 8.0 9.0 0.0 2.0 6.0 1.0 0.0 10.0which is to be assembled from four symmetric elemental matrices:
1 4 1 5 2 3 5 3 4 1 (2.0 1.0) 1 (3.0 2.0) 2 (4.0 3.0 6.0) 3 (2.0 8.0) 4 (1.0 7.0) 5 (2.0 8.0) 3 (3.0 5.0 1.0) 4 (8.0 2.0) 5 (6.0 1.0 2.0)The variable indices are indicated by the integers marking the rows and columns. Because this matrix is symmetric, only the diagonal and lower triangular elements are to be stored. Using the arrays:
Subscripts: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 ELTPTR: 1 3 5 8 10 VARIND: 1 4 1 5 2 3 5 3 4 VALUES: 2. 1. 7. 3. 2. 8. 4. 3. 6. 5. 1. 2. 2. 8. 2.
You can go up one level to the DATASETS directory.