Matrix addition correctness tests results

Sample 5x5 matrices:
Matrix 1:
           1000             4              6                8               10
            4            1100             16              18              20
            6               16          1200              28              30
            8               18              28          1300              40
           10              20              30              40          1400
Matrix 2:
           1000             4              6                8               10
            4            1100             16              18              20
            6               16          1200              28              30
            8               18              28          1300              40
           10              20              30              40          1400
 

1. Matrix + Matrix, 1 time

LinearAlgebra

Matrix1 + Matrix2 =
       2e+03               8                  12                   16                  20
          8         2.2e+03                  32                   36                  40
        12                  32         2.4e+03                   56                  60
        16                  36                   56         2.6e+03                  80
        20                  40                   60                  80         2.8e+03

LinearAlgebra (Symmetric Matrices)

Matrix1 + Matrix2 =
       2e+03               8                  12                   16                  20
          8         2.2e+03                  32                   36                  40
        12                  32         2.4e+03                   56                  60
        16                  36                   56         2.6e+03                  80
        20                  40                   60                  80         2.8e+03

CLHEP

Matrix1 + Matrix2 =
       2000                8              12              16               20
             8          2200              32              36               40
           12               32          2400              56              60
           16               36              56          2600              80
           20               40              60              80          2800

CLHEP (Symmetric matrices)

Matrix1 + Matrix2 =
       2000                8              12              16               20
             8          2200              32              36               40
           12               32          2400              56              60
           16               36              56          2600              80
           20               40              60              80          2800

CovMatrices (inherently symmetric)

Matrix1 + Matrix2 =
  +2.0000000000e+03
  +8.0000000000e+00   +2.2000000000e+03
  +1.2000000000e+01   +3.2000000000e+01   +2.4000000000e+03
  +1.6000000000e+01   +3.6000000000e+01   +5.6000000000e+01   +2.6000000000e+03
  +2.0000000000e+01   +4.0000000000e+01   +6.0000000000e+01   +8.0000000000e+01   +2.8000000000e+03
 

2. Matrix + Matrix, 1,000,000 times (the sum of the two matrices is stored on the first matrix)

LinearAlgebra

Matrix1 + Matrix2 =
     1e+09            4e+06            6e+06            8e+06            1e+07
     4e+06         1.1e+09         1.6e+07         1.8e+07            2e+07
     6e+06         1.6e+07         1.2e+09         2.8e+07            3e+07
     8e+06         1.8e+07         2.8e+07         1.3e+09            4e+07
     1e+07            2e+07            3e+07            4e+07         1.4e+09

LinearAlgebra (Symmetric Matrices)

Matrix1 + Matrix2 =
     1e+09            4e+06            6e+06            8e+06            1e+07
     4e+06         1.1e+09         1.6e+07         1.8e+07            2e+07
     6e+06         1.6e+07         1.2e+09         2.8e+07            3e+07
     8e+06         1.8e+07         2.8e+07         1.3e+09            4e+07
     1e+07            2e+07            3e+07            4e+07         1.4e+09

CLHEP

Matrix1 + Matrix2 =
             1e+09          4e+06   6.00001e+06   8.00001e+06         1e+07
             4e+06       1.1e+09           1.6e+07           1.8e+07         2e+07
  6.00001e+06       1.6e+07           1.2e+09           2.8e+07         3e+07
  8.00001e+06       1.8e+07           2.8e+07           1.3e+09         4e+07
             1e+07          2e+07              3e+07              4e+07      1.4e+09

CLHEP (Symmetric matrices)

Matrix1 + Matrix2 =
             1e+09          4e+06   6.00001e+06   8.00001e+06         1e+07
             4e+06       1.1e+09           1.6e+07           1.8e+07         2e+07
  6.00001e+06       1.6e+07           1.2e+09           2.8e+07         3e+07
  8.00001e+06       1.8e+07           2.8e+07           1.3e+09         4e+07
             1e+07          2e+07              3e+07              4e+07      1.4e+09

CovMatrices (inherently symmetric)

Matrix1 + Matrix2 =
  +1.0000010000e+09
  +4.0000040000e+06   +1.1000011000e+09
  +6.0000060000e+06   +1.6000016000e+07   +1.2000012000e+09
  +8.0000080000e+06   +1.8000018000e+07   +2.8000028000e+07   +1.3000013000e+09
  +1.0000010000e+07   +2.0000020000e+07   +3.0000030000e+07   +4.0000040000e+07   +1.4000014000e+09
 

Tests were compiled and build using GCC 3.0.1

Nick Macks