14 September 2021 10:27:46.054 AM R8GE_TEST FORTRAN90 version: Test the R8GE library. I4_LOG_10_TEST I4_LOG_10: whole part of log base 10, X, I4_LOG_10 0 0 1 0 2 0 3 0 9 0 10 1 11 1 99 1 101 2 -1 0 -2 0 -3 0 -9 0 I4VEC_PRINT_TEST I4VEC_PRINT prints an I4VEC The I4VEC: 1 91 2 92 3 93 4 94 R8_SIGN_TEST R8_SIGN returns the sign of an R8. R8 R8_SIGN(R8) -1.2500 -1. -0.2500 -1. 0.0000 1. 0.5000 1. 9.0000 1. R8COL_SWAP_TEST R8COL_SWAP swaps two columns of an R8COL; The array: Col: 1 2 3 4 Row --- 1 11.0000 12.0000 13.0000 14.0000 2 21.0000 22.0000 23.0000 24.0000 3 31.0000 32.0000 33.0000 34.0000 Swap columns 1 and 3 The updated matrix: Col: 1 2 3 4 Row --- 1 13.0000 12.0000 11.0000 14.0000 2 23.0000 22.0000 21.0000 24.0000 3 33.0000 32.0000 31.0000 34.0000 R8GE_CG_TEST R8GE_CG applies CG to an R8GE matrix. Number of variables N = 10 Norm of residual ||Ax-b|| = 0.154736E-14 Norm of error ||x1-x2|| = 0.209665E-14 R8GE_CO_TEST R8GE_CO estimates the condition number. Matrix order N = 4 The L1 condition number is 10.0000 The R8GE_CO estimate is 7.00000 R8GE_DET_TEST R8GE_DET computes the determinant of an R8GE matrix. R8GE_DET computes the determinant = 112.000 Exact determinant = 112.000 R8GE_DIF2_TEST R8GE_DIF2 sets up the second difference matrix. The second difference matrix: Col: 1 2 3 4 5 Row --- 1 2.00000 -1.00000 0.00000 0.00000 0.00000 2 -1.00000 2.00000 -1.00000 0.00000 0.00000 3 0.00000 -1.00000 2.00000 -1.00000 0.00000 4 0.00000 0.00000 -1.00000 2.00000 -1.00000 5 0.00000 0.00000 0.00000 -1.00000 2.00000 6 0.00000 0.00000 0.00000 0.00000 -1.00000 7 0.00000 0.00000 0.00000 0.00000 0.00000 R8GE_DILU_TEST R8GE_DILU returns the DILU factors of an R8GE matrix. Matrix rows M = 9 Matrix columns N = 9 Matrix A: Col: 1 2 3 4 5 Row --- 1 4.00000 -1.00000 0.00000 -1.00000 0.00000 2 -1.00000 4.00000 -1.00000 0.00000 -1.00000 3 0.00000 -1.00000 4.00000 -1.00000 0.00000 4 -1.00000 0.00000 -1.00000 4.00000 -1.00000 5 0.00000 -1.00000 0.00000 -1.00000 4.00000 6 0.00000 0.00000 -1.00000 0.00000 -1.00000 7 0.00000 0.00000 0.00000 -1.00000 0.00000 8 0.00000 0.00000 0.00000 0.00000 -1.00000 9 0.00000 0.00000 0.00000 0.00000 0.00000 Col: 6 7 8 9 Row --- 1 0.00000 0.00000 0.00000 0.00000 2 0.00000 0.00000 0.00000 0.00000 3 -1.00000 0.00000 0.00000 0.00000 4 0.00000 -1.00000 0.00000 0.00000 5 -1.00000 0.00000 -1.00000 0.00000 6 4.00000 -1.00000 0.00000 -1.00000 7 -1.00000 4.00000 -1.00000 0.00000 8 0.00000 -1.00000 4.00000 -1.00000 9 -1.00000 0.00000 -1.00000 4.00000 DILU factor: 1: 0.25000000 2: 0.26666667 3: 0.26785714 4: 0.28717949 5: 0.29017857 6: 0.29053178 7: 0.29220211 8: 0.29260134 9: 0.29266578 R8GE_FA_TEST R8GE_FA computes the LU factors of a matrix, so that R8GE_SL can solve the factored system. Matrix order N = 10 Solution: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 6: 6.0000000 7: 7.0000000 8: 8.0000000 9: 9.0000000 10: 10.000000 Solution: 1: 1.0000000 2: 1.0000000 3: 1.0000000 4: 1.0000000 5: 1.0000000 6: 1.0000000 7: 1.0000000 8: 1.0000000 9: 1.0000000 10: 1.0000000 Solution of transposed system: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 6: 6.0000000 7: 7.0000000 8: 8.0000000 9: 9.0000000 10: 10.000000 R8GE_FS_TEST R8GE_FS factors and solves a linear system for a general matrix. Matrix order N = 10 Solution: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 6: 6.0000000 7: 7.0000000 8: 8.0000000 9: 9.0000000 10: 10.000000 R8GE_FSS_TEST For a matrix in general storage, R8GE_FSS factors and solves multiple linear systems. Matrix order N = 10 Solutions: Col: 1 2 3 Row --- 1 1.00000 1.00000 1.00000 2 1.00000 2.00000 2.00000 3 1.00000 3.00000 3.00000 4 1.00000 4.00000 1.00000 5 1.00000 5.00000 2.00000 6 1.00000 6.00000 3.00000 7 1.00000 7.00000 1.00000 8 1.00000 8.00000 2.00000 9 1.00000 9.00000 3.00000 10 1.00000 10.0000 1.00000 R8GE_HILBERT_TEST R8GE_HILBERT sets up the Hilbert matrix. The Hilbert matrix: Col: 1 2 3 4 5 Row --- 1 1.00000 0.500000 0.333333 0.250000 0.200000 2 0.500000 0.333333 0.250000 0.200000 0.166667 3 0.333333 0.250000 0.200000 0.166667 0.142857 4 0.250000 0.200000 0.166667 0.142857 0.125000 5 0.200000 0.166667 0.142857 0.125000 0.111111 6 0.166667 0.142857 0.125000 0.111111 0.100000 7 0.142857 0.125000 0.111111 0.100000 0.909091E-01 R8GE_HILBERT_INVERSE_TEST R8GE_HILBERT_INVERSE sets up the Hilbert matrix inverse. The Hilbert matrix A: Col: 1 2 3 4 Row --- 1 1.00000 0.500000 0.333333 0.250000 2 0.500000 0.333333 0.250000 0.200000 3 0.333333 0.250000 0.200000 0.166667 4 0.250000 0.200000 0.166667 0.142857 The inverse Hilbert matrix B: Col: 1 2 3 4 Row --- 1 16.0000 -120.000 240.000 -140.000 2 -120.000 1200.00 -2700.00 1680.00 3 240.000 -2700.00 6480.00 -4200.00 4 -140.000 1680.00 -4200.00 2800.00 C = A * B: Col: 1 2 3 4 Row --- 1 1.00000 0.00000 0.00000 0.00000 2 0.00000 1.00000 0.00000 0.00000 3 0.00000 0.00000 1.00000 -0.568434E-13 4 0.00000 0.00000 0.00000 1.00000 R8GE_IDENTITY_TEST R8GE_IDENTITY sets up the identity matrix. The R8GE identity matrix: Col: 1 2 3 4 5 Row --- 1 1.00000 0.00000 0.00000 0.00000 0.00000 2 0.00000 1.00000 0.00000 0.00000 0.00000 3 0.00000 0.00000 1.00000 0.00000 0.00000 4 0.00000 0.00000 0.00000 1.00000 0.00000 5 0.00000 0.00000 0.00000 0.00000 1.00000 6 0.00000 0.00000 0.00000 0.00000 0.00000 7 0.00000 0.00000 0.00000 0.00000 0.00000 R8GE_ILU_TEST For a matrix in general storage, R8GE_ILU returns the ILU factors. Matrix rows M = 9 Matrix columns N = 9 Matrix A: Col: 1 2 3 4 5 Row --- 1 4.00000 -1.00000 0.00000 -1.00000 0.00000 2 -1.00000 4.00000 -1.00000 0.00000 -1.00000 3 0.00000 -1.00000 4.00000 -1.00000 0.00000 4 -1.00000 0.00000 -1.00000 4.00000 -1.00000 5 0.00000 -1.00000 0.00000 -1.00000 4.00000 6 0.00000 0.00000 -1.00000 0.00000 -1.00000 7 0.00000 0.00000 0.00000 -1.00000 0.00000 8 0.00000 0.00000 0.00000 0.00000 -1.00000 9 0.00000 0.00000 0.00000 0.00000 0.00000 Col: 6 7 8 9 Row --- 1 0.00000 0.00000 0.00000 0.00000 2 0.00000 0.00000 0.00000 0.00000 3 -1.00000 0.00000 0.00000 0.00000 4 0.00000 -1.00000 0.00000 0.00000 5 -1.00000 0.00000 -1.00000 0.00000 6 4.00000 -1.00000 0.00000 -1.00000 7 -1.00000 4.00000 -1.00000 0.00000 8 0.00000 -1.00000 4.00000 -1.00000 9 -1.00000 0.00000 -1.00000 4.00000 Factor L: Col: 1 2 3 4 5 Row --- 1 1.00000 0.00000 0.00000 0.00000 0.00000 2 -0.250000 1.00000 0.00000 0.00000 0.00000 3 0.00000 -0.266667 1.00000 0.00000 0.00000 4 -0.250000 0.00000 -0.267857 1.00000 0.00000 5 0.00000 -0.266667 0.00000 -0.287179 1.00000 6 0.00000 0.00000 -0.267857 0.00000 -0.290179 7 0.00000 0.00000 0.00000 -0.287179 0.00000 8 0.00000 0.00000 0.00000 0.00000 -0.290179 9 0.00000 0.00000 0.00000 0.00000 0.00000 Col: 6 7 8 9 Row --- 1 0.00000 0.00000 0.00000 0.00000 2 0.00000 0.00000 0.00000 0.00000 3 0.00000 0.00000 0.00000 0.00000 4 0.00000 0.00000 0.00000 0.00000 5 0.00000 0.00000 0.00000 0.00000 6 1.00000 0.00000 0.00000 0.00000 7 -0.290532 1.00000 0.00000 0.00000 8 0.00000 -0.292202 1.00000 0.00000 9 -0.290532 0.00000 -0.292601 1.00000 Factor U: Col: 1 2 3 4 5 Row --- 1 4.00000 -1.00000 0.00000 -1.00000 0.00000 2 0.00000 3.75000 -1.00000 0.00000 -1.00000 3 0.00000 0.00000 3.73333 -1.00000 0.00000 4 0.00000 0.00000 0.00000 3.48214 -1.00000 5 0.00000 0.00000 0.00000 0.00000 3.44615 6 0.00000 0.00000 0.00000 0.00000 0.00000 7 0.00000 0.00000 0.00000 0.00000 0.00000 8 0.00000 0.00000 0.00000 0.00000 0.00000 9 0.00000 0.00000 0.00000 0.00000 0.00000 Col: 6 7 8 9 Row --- 1 0.00000 0.00000 0.00000 0.00000 2 0.00000 0.00000 0.00000 0.00000 3 -1.00000 0.00000 0.00000 0.00000 4 0.00000 -1.00000 0.00000 0.00000 5 -1.00000 0.00000 -1.00000 0.00000 6 3.44196 -1.00000 0.00000 -1.00000 7 0.00000 3.42229 -1.00000 0.00000 8 0.00000 0.00000 3.41762 -1.00000 9 0.00000 0.00000 0.00000 3.41687 Product L*U: Col: 1 2 3 4 5 Row --- 1 4.00000 -1.00000 0.00000 -1.00000 0.00000 2 -1.00000 4.00000 -1.00000 0.250000 -1.00000 3 0.00000 -1.00000 4.00000 -1.00000 0.266667 4 -1.00000 0.250000 -1.00000 4.00000 -1.00000 5 0.00000 -1.00000 0.266667 -1.00000 4.00000 6 0.00000 0.00000 -1.00000 0.267857 -1.00000 7 0.00000 0.00000 0.00000 -1.00000 0.287179 8 0.00000 0.00000 0.00000 0.00000 -1.00000 9 0.00000 0.00000 0.00000 0.00000 0.00000 Col: 6 7 8 9 Row --- 1 0.00000 0.00000 0.00000 0.00000 2 0.00000 0.00000 0.00000 0.00000 3 -1.00000 0.00000 0.00000 0.00000 4 0.267857 -1.00000 0.00000 0.00000 5 -1.00000 0.287179 -1.00000 0.00000 6 4.00000 -1.00000 0.290179 -1.00000 7 -1.00000 4.00000 -1.00000 0.290532 8 0.290179 -1.00000 4.00000 -1.00000 9 -1.00000 0.290532 -1.00000 4.00000 R8GE_INDICATOR_TEST R8GE_INDICATOR sets up the indicator matrix. The R8GE indicator matrix: Col: 1 2 3 4 5 Row --- 1 11.0000 12.0000 13.0000 14.0000 15.0000 2 21.0000 22.0000 23.0000 24.0000 25.0000 3 31.0000 32.0000 33.0000 34.0000 35.0000 4 41.0000 42.0000 43.0000 44.0000 45.0000 5 51.0000 52.0000 53.0000 54.0000 55.0000 6 61.0000 62.0000 63.0000 64.0000 65.0000 7 71.0000 72.0000 73.0000 74.0000 75.0000 R8GE_INVERSE_TEST For a matrix in general storage, R8GE_INVERSE computes the inverse matrix. Matrix order N = 4 Matrix A: Col: 1 2 3 4 Row --- 1 5.00000 3.00000 3.00000 3.00000 2 3.00000 5.00000 3.00000 3.00000 3 3.00000 3.00000 5.00000 3.00000 4 3.00000 3.00000 3.00000 5.00000 Inverse matrix B: Col: 1 2 3 4 Row --- 1 0.392857 -0.107143 -0.107143 -0.107143 2 -0.107143 0.392857 -0.107143 -0.107143 3 -0.107143 -0.107143 0.392857 -0.107143 4 -0.107143 -0.107143 -0.107143 0.392857 Product matrix: Col: 1 2 3 4 Row --- 1 1.00000 -0.111022E-15 0.00000 0.00000 2 0.333067E-15 1.00000 0.00000 0.00000 3 0.444089E-15 -0.111022E-15 1.00000 0.111022E-15 4 0.444089E-15 -0.111022E-15 0.00000 1.00000 R8GE_ML_TEST For a matrix in general storage, R8GE_ML computes A*x or A'*X where A has been factored by R8GE_FA. Matrix order N = 10 A*x and PLU*x 1 26.4072 26.4072 2 29.8885 29.8885 3 32.3164 32.3164 4 21.7675 21.7675 5 26.5012 26.5012 6 32.2951 32.2951 7 27.3716 27.3716 8 27.4572 27.4572 9 16.8337 16.8337 10 27.8437 27.8437 A'*x and (PLU)'*x 1 28.5090 28.5090 2 21.6803 21.6803 3 34.0104 34.0104 4 28.2828 28.2828 5 29.1670 29.1670 6 28.4531 28.4531 7 24.7974 24.7974 8 27.7155 27.7155 9 34.6067 34.6067 10 29.9620 29.9620 R8GE_MM_TEST R8GE_MM computes a matrix-matrix product C = A * B. A: Col: 1 2 3 Row --- 1 1.00000 0.00000 0.00000 2 1.00000 1.00000 0.00000 3 1.00000 2.00000 1.00000 4 1.00000 3.00000 3.00000 B: Col: 1 2 3 4 Row --- 1 1.00000 1.00000 1.00000 1.00000 2 0.00000 1.00000 2.00000 3.00000 3 0.00000 0.00000 1.00000 3.00000 C = A*B: Col: 1 2 3 4 Row --- 1 1.00000 1.00000 1.00000 1.00000 2 1.00000 2.00000 3.00000 4.00000 3 1.00000 3.00000 6.00000 10.0000 4 1.00000 4.00000 10.0000 19.0000 R8GE_MTM_TEST R8GE_MTM computes a matrix-transpose-matrix product C = A' * B. A: Col: 1 2 3 Row --- 1 1.00000 0.00000 0.00000 2 1.00000 1.00000 0.00000 3 1.00000 2.00000 1.00000 4 1.00000 3.00000 3.00000 B: Col: 1 2 3 Row --- 1 1.00000 0.00000 0.00000 2 1.00000 1.00000 0.00000 3 1.00000 2.00000 1.00000 4 1.00000 3.00000 3.00000 C = A'*B: Col: 1 2 3 Row --- 1 4.00000 6.00000 4.00000 2 6.00000 14.0000 11.0000 3 4.00000 11.0000 10.0000 R8GE_MTV_TEST R8GE_MTV computes a product b=A'*x for an R8GE matrix. The R8GE matrix A: Col: 1 2 3 4 Row --- 1 11.0000 12.0000 13.0000 14.0000 2 21.0000 22.0000 23.0000 24.0000 3 31.0000 32.0000 33.0000 34.0000 4 41.0000 42.0000 43.0000 44.0000 5 51.0000 52.0000 53.0000 54.0000 Vector x: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 Vector b = A'*x: 1: 565.00000 2: 580.00000 3: 595.00000 4: 610.00000 R8GE_MU_TEST For a matrix in general storage, R8GE_MU computes A*x or A'*X where A has been factored by R8GE_TRF. Matrix rows M = 5 Matrix columns N = 3 A*x and PLU*x 1 3.30222 3.30222 2 3.28316 3.28316 3 2.90790 2.90790 4 3.47887 3.47887 5 3.52065 3.52065 A'*x and (PLU)'*x 1 8.46122 8.46122 2 6.59778 6.59778 3 6.17835 6.17835 Matrix is 3 by 5 A*x and PLU*x 1 8.23987 8.23987 2 11.4979 11.4979 3 9.62939 9.62939 A'*x and (PLU)'*x 1 4.77331 4.77331 2 3.19984 3.19984 3 3.15435 3.15435 4 3.77108 3.77108 5 2.32716 2.32716 R8GE_MV_TEST R8GE_MV computes a product b=A*x for an R8GE matrix. The R8GE matrix A: Col: 1 2 3 4 Row --- 1 11.0000 12.0000 13.0000 14.0000 2 21.0000 22.0000 23.0000 24.0000 3 31.0000 32.0000 33.0000 34.0000 4 41.0000 42.0000 43.0000 44.0000 5 51.0000 52.0000 53.0000 54.0000 Vector x: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 Vector b = A*x: 1: 130.00000 2: 230.00000 3: 330.00000 4: 430.00000 5: 530.00000 R8GE_PLU_TEST R8GE_PLU returns the PLU factors of a matrix. Matrix rows M = 5 Matrix columns N = 4 Matrix A: Col: 1 2 3 4 Row --- 1 0.723280 0.550746 0.440890 0.539273 2 0.763650 0.686395 0.868753 0.546743 3 0.219835 0.766736 0.339620 0.297855 4 0.553724 0.352386 0.206947 0.902447 5 0.899484 0.123932 0.522579 0.378724E-01 Factor P: Col: 1 2 3 4 5 Row --- 1 0.00000 0.00000 0.00000 0.00000 1.00000 2 0.00000 0.00000 1.00000 0.00000 0.00000 3 0.00000 1.00000 0.00000 0.00000 0.00000 4 0.00000 0.00000 0.00000 1.00000 0.00000 5 1.00000 0.00000 0.00000 0.00000 0.00000 Factor L: Col: 1 2 3 4 5 Row --- 1 1.00000 0.00000 0.00000 0.00000 0.00000 2 0.244401 1.00000 0.00000 0.00000 0.00000 3 0.848987 0.789165 1.00000 0.00000 0.00000 4 0.615602 0.374899 -0.753086 1.00000 0.00000 5 0.804105 0.612525 -0.423142 0.459413 1.00000 Factor U: Col: 1 2 3 4 Row --- 1 0.899484 0.123932 0.522579 0.378724E-01 2 0.00000 0.736447 0.211901 0.288599 3 0.00000 0.00000 0.257865 0.286838 4 0.00000 0.00000 0.00000 0.986951 5 0.00000 0.00000 0.00000 0.00000 Product P*L*U: Col: 1 2 3 4 Row --- 1 0.723280 0.550746 0.440890 0.539273 2 0.763650 0.686395 0.868753 0.546743 3 0.219835 0.766736 0.339620 0.297855 4 0.553724 0.352386 0.206947 0.902447 5 0.899484 0.123932 0.522579 0.378724E-01 R8GE_POLY_TEST R8GE_POLY computes the characteristic polynomial. Matrix order N = 12 I, P(I), True P(I) 1 1.00000 1.00000 2 -23.0000 -23.0000 3 231.000 231.000 4 -1330.00 -1330.00 5 4845.00 4845.00 6 -11628.0 -11628.0 7 18564.0 18564.0 8 -19448.0 -19448.0 ...... .............. .............. 13 1.00000 1.00000 R8GE_PRINT_TEST R8GET_PRINT prints an R8GE matrix. The matrix: Col: 1 2 3 4 Row --- 1 11.0000 12.0000 13.0000 14.0000 2 21.0000 22.0000 23.0000 24.0000 3 31.0000 32.0000 33.0000 34.0000 4 41.0000 42.0000 43.0000 44.0000 5 51.0000 52.0000 53.0000 54.0000 6 61.0000 62.0000 63.0000 64.0000 R8GE_PRINT_SOME_TEST R8GE_PRINT_SOME prints some of an R8GE matrix. The matrix, rows 2:4, cols 1:2: Col: 1 2 Row --- 2 21.0000 22.0000 3 31.0000 32.0000 4 41.0000 42.0000 R8GE_RANDOM_TEST R8GE_RANDOM returns a random R8GE matrix. Random matrix: Col: 1 2 3 4 Row --- 1 0.853749 0.718475 0.510517 0.854645 2 0.126900 0.406864 0.540770 0.473844 3 0.302201 0.332243 0.817988 0.920697 4 0.850258 0.130302 0.302641 0.454759E-01 5 0.114211 0.812148 0.260540 0.891028 R8GE_RES_TEST R8GE_RES computes b-A*x, where A is an R8GE matrix. We check three cases, MN. Residual A*x-b: 1: 0.0000000 2: 0.0000000 3: 0.0000000 Residual A*x-b: 1: 0.0000000 2: 0.0000000 3: 0.0000000 4: 0.0000000 5: 0.0000000 Residual A*x-b: 1: 0.0000000 2: 0.0000000 3: 0.0000000 4: 0.0000000 5: 0.0000000 R8GE_SL_TEST R8GE_SL solves a system after it has been factored by R8GE_FA. Matrix order N = 10 Solution: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 6: 6.0000000 7: 7.0000000 8: 8.0000000 9: 9.0000000 10: 10.000000 Solution: 1: 1.0000000 2: 1.0000000 3: 1.0000000 4: 1.0000000 5: 1.0000000 6: 1.0000000 7: 1.0000000 8: 1.0000000 9: 1.0000000 10: 1.0000000 Solution of transposed system: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 6: 6.0000000 7: 7.0000000 8: 8.0000000 9: 9.0000000 10: 10.000000 R8GE_SL_IT_TEST R8GE_SL_IT applies one step of iterative refinement to an R8GE_SL solution. Matrix order N = 6 i, x, b-A*x 1 0.166667 0.912603E-13 2 0.142857 -0.211253E-11 3 0.125000 0.478328E-11 4 0.111111 -0.224567E-10 5 0.100000 0.707390E-11 6 0.909091E-01 0.808242E-13 Iterative refinement step 1 I, DX: 1: -0.355650E-11 2: -0.276354E-11 3: -0.226318E-11 4: -0.191736E-11 5: -0.166353E-11 6: -0.146912E-11 i, x, b-A*x 1 0.166667 -0.939804E-13 2 0.142857 0.829892E-12 3 0.125000 0.114712E-10 4 0.111111 -0.148592E-11 5 0.100000 0.489654E-10 6 0.909091E-01 -0.239517E-10 Iterative refinement step 2 I, DX: 1: 0.957433E-11 2: 0.753947E-11 3: 0.622381E-11 4: 0.530144E-11 5: 0.461794E-11 6: 0.409079E-11 i, x, b-A*x 1 0.166667 0.726086E-13 2 0.142857 -0.155298E-11 3 0.125000 0.541389E-11 4 0.111111 -0.473577E-11 5 0.100000 0.235176E-10 6 0.909091E-01 0.138760E-10 Iterative refinement step 3 I, DX: 1: 0.693300E-11 2: 0.582686E-11 3: 0.502360E-11 4: 0.441482E-11 5: 0.393781E-11 6: 0.355401E-11 i, x, b-A*x 1 0.166667 -0.161537E-13 2 0.142857 -0.424882E-12 3 0.125000 -0.197632E-10 4 0.111111 -0.346096E-10 5 0.100000 -0.301857E-10 6 0.909091E-01 -0.213951E-10 Iterative refinement step 4 I, DX: 1: -0.250717E-10 2: -0.200998E-10 3: -0.168192E-10 4: -0.144776E-10 5: -0.127170E-10 6: -0.113429E-10 i, x, b-A*x 1 0.166667 0.743849E-13 2 0.142857 -0.355715E-12 3 0.125000 0.134039E-10 4 0.111111 -0.664002E-11 5 0.100000 0.383205E-11 6 0.909091E-01 0.865352E-11 Iterative refinement step 5 I, DX: 1: 0.491317E-11 2: 0.381649E-11 3: 0.313911E-11 4: 0.267338E-11 5: 0.233157E-11 6: 0.206918E-11 i, x, b-A*x 1 0.166667 -0.176303E-12 2 0.142857 0.318590E-11 3 0.125000 -0.259393E-10 4 0.111111 0.691713E-10 5 0.100000 -0.559899E-10 6 0.909091E-01 0.311271E-10 R8GE_TO_R8VEC_TEST R8GE_TO_R8VEC converts an R8GE matrix to an R8VEC. Matrix rows M = 4 Matrix columns N = 6 The R8GE indicator matrix: Col: 1 2 3 4 5 Row --- 1 11.0000 12.0000 13.0000 14.0000 15.0000 2 21.0000 22.0000 23.0000 24.0000 25.0000 3 31.0000 32.0000 33.0000 34.0000 35.0000 4 41.0000 42.0000 43.0000 44.0000 45.0000 Col: 6 Row --- 1 16.0000 2 26.0000 3 36.0000 4 46.0000 1 1 1 11.0000 2 1 2 21.0000 3 1 3 31.0000 4 1 4 41.0000 1 2 5 12.0000 2 2 6 22.0000 3 2 7 32.0000 4 2 8 42.0000 1 3 9 13.0000 2 3 10 23.0000 3 3 11 33.0000 4 3 12 43.0000 1 4 13 14.0000 2 4 14 24.0000 3 4 15 34.0000 4 4 16 44.0000 1 5 17 15.0000 2 5 18 25.0000 3 5 19 35.0000 4 5 20 45.0000 1 6 21 16.0000 2 6 22 26.0000 3 6 23 36.0000 4 6 24 46.0000 R8GE_TRANSPOSE_PRINT_TEST R8GE_TRANSPOSE_PRINT prints an R8GE matrix, transposed. Matrix row order M = 7 Matrix column order N = 12 The transposed matrix A: Row 1 2 3 4 5 Col 1: 101.000 201.000 301.000 401.000 501.000 2: 102.000 202.000 302.000 402.000 502.000 3: 103.000 203.000 303.000 403.000 503.000 4: 104.000 204.000 304.000 404.000 504.000 5: 105.000 205.000 305.000 405.000 505.000 6: 106.000 206.000 306.000 406.000 506.000 7: 107.000 207.000 307.000 407.000 507.000 8: 108.000 208.000 308.000 408.000 508.000 9: 109.000 209.000 309.000 409.000 509.000 10: 110.000 210.000 310.000 410.000 510.000 11: 111.000 211.000 311.000 411.000 511.000 12: 112.000 212.000 312.000 412.000 512.000 Row 6 7 Col 1: 601.000 701.000 2: 602.000 702.000 3: 603.000 703.000 4: 604.000 704.000 5: 605.000 705.000 6: 606.000 706.000 7: 607.000 707.000 8: 608.000 708.000 9: 609.000 709.000 10: 610.000 710.000 11: 611.000 711.000 12: 612.000 712.000 R8GE_TRANSPOSE_PRINT_SOME_TEST R8GE_TRANSPOSE_PRINT_SOME prints some of an R8GE matrix, transposed. Matrix row order M = 7 Matrix column order N = 12 Rows 3:5, Cols 4:8 Row 3 4 5 Col 4: 304.000 404.000 504.000 5: 305.000 405.000 505.000 6: 306.000 406.000 506.000 7: 307.000 407.000 507.000 8: 308.000 408.000 508.000 R8GE_TRF_TEST R8GE_TRF computes the LU factors of an R8GE matrix so that R8GE_TRS can solve the factored system. Number of matrix rows M = 5 Number of matrix columns N = 5 Solution: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 Solution to transposed system: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 R8GE_TRS_TEST R8GE_TRS solves a linear system that has been factored by R8GE_TRF. Number of matrix rows M = 5 Number of matrix columns N = 5 Solution: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 Solution to transposed system: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 R8GE_ZEROS_TEST R8GE_ZEROS zeros out a matrix in R8GE format. Matrix order M, N = 5 4 The zero R8GE matrix: Col: 1 2 3 4 Row --- 1 0.00000 0.00000 0.00000 0.00000 2 0.00000 0.00000 0.00000 0.00000 3 0.00000 0.00000 0.00000 0.00000 4 0.00000 0.00000 0.00000 0.00000 5 0.00000 0.00000 0.00000 0.00000 R8ROW_SWAP_TEST For a R8ROW (a matrix regarded as rows): R8ROW_SWAP swaps two rows; The original matrix: Col: 1 2 3 4 Row --- 1 1.00000 2.00000 3.00000 4.00000 2 5.00000 6.00000 7.00000 8.00000 3 9.00000 10.0000 11.0000 12.0000 Swap rows 1 and 3 The modified matrix: Col: 1 2 3 4 Row --- 1 9.00000 10.0000 11.0000 12.0000 2 5.00000 6.00000 7.00000 8.00000 3 1.00000 2.00000 3.00000 4.00000 R8VEC_INDICATOR1_TEST R8VEC_INDICATOR returns the indicator vector. Vector X: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 R8VEC_NORM_TEST R8VEC_NORM computes the L2 norm of an R8VEC. Vector X: 1: 0.36877889 2: 0.43400245 3: 0.84096371 4: 0.55170623 5: 0.61491302 R8VEC_NORM ( X ) = 1.30923 R8VEC_NORM_AFFINE_TEST R8VEC_NORM_AFFINE computes the L2 norm of the difference of two R8VECs. R8VEC_NORM_AFFINE(X,Y) = 1.25978 R8VEC_NORM (X-Y): 1.25978 R8VEC_PRINT_TEST R8VEC_PRINT prints an R8VEC. The R8VEC: 1: 123.45600 2: 0.50000000E-05 3: -1000000.0 4: 3.1415927 R8VEC_PRINT_SOME_TEST R8VEC_PRINT_SOME prints some of a pair of R8VEC's. No more than 10 lines from an R8VEC: 1: 1.00000 2: 4.00000 3: 9.00000 4: 16.0000 5: 25.0000 6: 36.0000 7: 49.0000 8: 64.0000 ........ .............. 100: 10000.0 R8GE_TO_R8VEC_TEST R8GE_TO_R8VEC converts an R8GE matrix to an R8VEC vector. Corresponding R8VEC vector: 1: 1.0000000 2: 2.0000000 3: 3.0000000 4: 4.0000000 5: 5.0000000 6: 6.0000000 7: 7.0000000 8: 8.0000000 9: 9.0000000 10: 10.000000 11: 11.000000 12: 12.000000 R8GE matrix: Col: 1 2 3 Row --- 1 1.00000 5.00000 9.00000 2 2.00000 6.00000 10.0000 3 3.00000 7.00000 11.0000 4 4.00000 8.00000 12.0000 R8VEC2_PRINT_SOME_TEST R8VEC2_PRINT_SOME prints some of a pair of R8VEC's. No more than 10 lines from a pair of R8VEC's: 1 1.00000 1.00000 2 4.00000 1.41421 3 9.00000 1.73205 4 16.0000 2.00000 5 25.0000 2.23607 6 36.0000 2.44949 7 49.0000 2.64575 8 64.0000 2.82843 ...... .............. .............. 100 10000.0 10.0000 R8GE_TEST Normal end of execution. 14 September 2021 10:27:46.056 AM