LINPACK_BENCH_BACKSLASH
The LINPACK Benchmark
Using MATLAB's BACKSLASH


LINPACK_BENCH_BACKSLASH, a MATLAB program which carries out the LINPACK Benchmark, using MATLAB's "backslash" operator for greater efficiency.

The LINPACK benchmark is a test problem used to rate the performance of a computer on a simple linear algebra problem.

The test problem requires the user to set up a random dense matrix A of size N = 1000, and a right hand side vector B which is the product of A and a vector X of all 1's. The first task is to compute an LU factorization of A. The second task is to use the LU factorization to solve the linear system

A * X = B.

The number of floating point operations required for these two tasks is roughly

ops = 2 * N*N*N / 3 + 2 * N * N,
therefore, the "MegaFLOPS" rating, or millions of floating point operations per second, can be found as
mflops = ops / ( cpu * 1000000 ).

The following table compares the "backslash" version ("LINPACK_BENCH_BACKSLASH") against the MATLAB version ("LINPACK_BENCH") which is a straight translation of the original FORTRAN code.
LanguagePrecisionTypeMachineCommentMegaFLOPS
MATLABDoubleRealDHCP95 (Apple G5)LINPACK_BENCH_BACKSLASH1857
MATLABDoubleRealDHCP95 (Apple G95)LINPACK_BENCH20

Usage:

linpack_bench_backslash
or
linpack_bench_backslash n
to specify the matrix size (default n = 1000 ), or
linpack_bench_backslash n lda
to specify the matrix size and the leading dimension (default lda = n+1);

Licensing:

The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.

Languages:

LINPACK_BENCH_BACKSLASH is available in a MATLAB version.

Related Data and Programs:

LINPACK_D, a MATLAB library which supplies the solvers used by LINPACK_BENCH.

LINPACK_BENCH, a MATLAB program which measures the time taken by LINPACK to solve a particular linear system.

linpack_bench_backslash_test

MATMUL, a FORTRAN90 program which is an interactive matrix multiplication benchmark program.

MEMORY_TEST, a MATLAB program which declares and uses a sequence of larger and larger vectors, to see how big a vector can be used on a given machine and compiler.

TIMER, a MATLAB library which demonstrates how to measure CPU time or elapsed time.

Reference:

  1. Jack Dongarra,
    Performance of Various Computers Using Standard Linear Equations Software, Technical Report CS-89-85,
    Electrical Engineering and Computer Science Department,
    University of Tennessee, 2008.
  2. Jack Dongarra, Jim Bunch, Cleve Moler, Pete Stewart,
    LINPACK User's Guide,
    SIAM, 1979,
    ISBN13: 978-0-898711-72-1,
    LC: QA214.L56.
  3. George Fishman,
    Multiplicative congruential random number generators with modulus 2**b: an exhaustive analysis for b = 32 and a partial analysis for b = 48,
    Mathematics of Computation,
    Volume 189, 1990, pages 331-344.
  4. Charles Lawson, Richard Hanson, David Kincaid, Fred Krogh,
    Algorithm 539: Basic Linear Algebra Subprograms for Fortran Usage,
    ACM Transactions on Mathematical Software,
    Volume 5, Number 3, September 1979, pages 308-323.

Source Code:

-
Last revised on 16 February 2019.