Thu Sep 13 17:09:37 2018 SIMPLEX_MONTE_CARLO_TEST Python version: 3.6.5 Test the SIMPLEX_MONTE_CARLO library. I4VEC_PRINT_TEST Python version: 3.6.5 I4VEC_PRINT prints an I4VEC. Here is an I4VEC: 0 91 1 92 2 93 3 94 I4VEC_PRINT_TEST: Normal end of execution. I4VEC_TRANSPOSE_PRINT_TEST Python version: 3.6.5 I4VEC_TRANSPOSE_PRINT prints an I4VEC with 5 entries to a row, and an optional title. My array: 1 2 3 4 5 6 7 8 9 10 11 12 I4VEC_TRANSPOSE_PRINT_TEST: Normal end of execution. I4VEC_UNIFORM_AB_TEST Python version: 3.6.5 I4VEC_UNIFORM_AB computes pseudorandom values in an interval [A,B]. The lower endpoint A = -100 The upper endpoint B = 200 The initial seed is 123456789 The random vector: 0 -35 1 187 2 149 3 69 4 25 5 -81 6 -23 7 -67 8 -87 9 90 10 -82 11 35 12 20 13 127 14 139 15 -100 16 170 17 5 18 -72 19 -96 I4VEC_UNIFORM_AB_TEST: Normal end of execution. MONOMIAL_VALUE_TEST Python version: 3.6.5 Use monomial_value() to evaluate some monomials in dimensions 1 through 3. Spatial dimension M = 1 Exponents: -1 V(X) X(0) 0.111111 9.0000 0.125 8.0000 0.2 5.0000 0.333333 3.0000 -1 -1.0000 Spatial dimension M = 2 Exponents: -1 -2 V(X) X(0) X(1) -0.0277778 -1.0000 6.0000 -0.111111 -1.0000 3.0000 0.00680272 3.0000 7.0000 0.03125 8.0000 -2.0000 0.0277778 9.0000 2.0000 Spatial dimension M = 3 Exponents: -3 -3 5 V(X) X(0) X(1) X(2) 0.0625 8.0000 -1.0000 -2.0000 -0.00137174 1.0000 9.0000 -1.0000 0.000244141 2.0000 8.0000 1.0000 1.21363 6.0000 5.0000 8.0000 0.158766 3.0000 9.0000 5.0000 MONOMIAL_VALUE_TEST Normal end of execution. R8MAT_PRINT_TEST Python version: 3.6.5 R8MAT_PRINT prints an R8MAT. Here is an R8MAT: Col: 0 1 2 3 4 Row 0 : 11 12 13 14 15 1 : 21 22 23 24 25 2 : 31 32 33 34 35 3 : 41 42 43 44 45 Col: 5 Row 0 : 16 1 : 26 2 : 36 3 : 46 R8MAT_PRINT_TEST: Normal end of execution. R8MAT_PRINT_SOME_TEST Python version: 3.6.5 R8MAT_PRINT_SOME prints some of an R8MAT. Here is an R8MAT: Col: 3 4 5 Row 0 : 14 15 16 1 : 24 25 26 2 : 34 35 36 R8MAT_PRINT_SOME_TEST: Normal end of execution. R8MAT_TRANSPOSE_PRINT_TEST Python version: 3.6.5 R8MAT_TRANSPOSE_PRINT prints an R8MAT. Here is an R8MAT, transposed: Row: 0 1 2 3 Col 0 : 11 21 31 41 1 : 12 22 32 42 2 : 13 23 33 43 R8MAT_TRANSPOSE_PRINT_TEST: Normal end of execution. R8MAT_TRANSPOSE_PRINT_SOME_TEST Python version: 3.6.5 R8MAT_TRANSPOSE_PRINT_SOME prints some of an R8MAT, transposed. R8MAT, rows 0:2, cols 3:5: Row: 0 1 2 Col 3 : 14 24 34 4 : 15 25 35 5 : 16 26 36 R8MAT_TRANSPOSE_PRINT_SOME_TEST: Normal end of execution. R8MAT_UNIFORM_AB_TEST Python version: 3.6.5 R8MAT_UNIFORM_AB computes a random R8MAT. -1 <= X <= 5 Initial seed is 123456789 Random R8MAT: Col: 0 1 2 3 Row 0 : 0.31051 -0.603288 -0.629637 -0.98897 1 : 4.73791 0.545467 1.69723 4.38502 2 : 3.97706 -0.340259 1.40784 1.10451 3 : 2.37017 -0.737026 3.52804 -0.432731 4 : 1.49184 2.80379 3.78372 -0.918299 R8MAT_UNIFORM_AB_TEST: Normal end of execution. R8VEC_PRINT_TEST Python version: 3.6.5 R8VEC_PRINT prints an R8VEC. Here is an R8VEC: 0: 123.456 1: 5e-06 2: -1e+06 3: 3.14159 R8VEC_PRINT_TEST: Normal end of execution. R8VEC_UNIFORM_01_TEST Python version: 3.6.5 R8VEC_UNIFORM_01 computes a random R8VEC. Initial seed is 123456789 Random R8VEC: 0: 0.218418 1: 0.956318 2: 0.829509 3: 0.561695 4: 0.415307 5: 0.0661187 6: 0.257578 7: 0.109957 8: 0.043829 9: 0.633966 R8VEC_UNIFORM_01_TEST: Normal end of execution. SIMPLEX_GENERAL_SAMPLE_TEST SIMPLEX_GENERAL_SAMPLE computes a Monte Carlo estimate of an integral over the interior of a general simplex in 3D. Simplex vertices: 1 0 0 2 0 0 1 2 0 1 0 3 N 1 X Y Z X^2 XY XZ Y^2 YZ Z^2 1 1 1.65301 0.0383438 0.240699 2.73246 0.0633828 0.397879 0.00147025 0.00922932 0.0579361 2 1 1.27953 0.443002 0.867026 1.66179 0.517316 1.15621 0.296001 0.28978 0.840907 4 1 1.11047 0.106982 0.813557 1.24547 0.113155 0.924962 0.0202689 0.0863224 0.882329 8 1 1.216 0.447415 0.757191 1.50956 0.508103 0.88421 0.350749 0.209647 1.03988 16 1 1.26252 0.514446 0.844578 1.64 0.631367 1.02496 0.40708 0.356328 1.04948 32 1 1.21845 0.495922 0.716681 1.50684 0.594882 0.857472 0.382341 0.232396 0.897127 64 1 1.24659 0.488949 0.858922 1.58747 0.589787 1.01258 0.377971 0.362851 1.12904 128 1 1.24609 0.471071 0.755085 1.59018 0.558411 0.916452 0.362607 0.32454 0.830786 256 1 1.24709 0.521803 0.710378 1.59719 0.623851 0.845154 0.433393 0.296905 0.832943 512 1 1.2362 0.5159 0.79062 1.56568 0.610438 0.941343 0.429591 0.31217 0.994037 1024 1 1.24995 0.491444 0.752503 1.60136 0.588624 0.89917 0.389395 0.294185 0.915248 2048 1 1.25566 0.49867 0.731285 1.61529 0.603344 0.878812 0.389636 0.292666 0.8624 4096 1 1.25 0.50107 0.746148 1.60013 0.601131 0.896665 0.400401 0.299783 0.886205 8192 1 1.2502 0.493427 0.759897 1.60102 0.592847 0.912525 0.392411 0.298577 0.917092 16384 1 1.24912 0.505825 0.746711 1.59843 0.604939 0.895425 0.409154 0.304681 0.890645 32768 1 1.24918 0.499839 0.754247 1.59765 0.599482 0.905099 0.399525 0.302215 0.902617 65536 1 1.24831 0.500552 0.74662 1.59546 0.600126 0.895144 0.401411 0.298906 0.892712 SIMPLEX_UNIT_MONOMIAL_INTEGRAL_TEST Python version: 3.6.5 Estimate monomial integrals using Monte Carlo over the interior of the unit simplex in M dimensions. Number of sample points used is 4192 We randomly choose the exponents. Ex Ey Ez MC-Estimate Exact Error 4 0 1 0.000596497 0.000595238 1.3e-06 2 1 4 1.21848e-05 1.32275e-05 1e-06 4 1 2 1.3095e-05 1.32275e-05 1.3e-07 0 4 2 0.000133047 0.000132275 7.7e-07 0 0 3 0.00828332 0.00833333 5e-05 1 3 4 3.44193e-06 3.6075e-06 1.7e-07 0 1 0 0.0416317 0.0416667 3.5e-05 2 3 2 6.43774e-06 6.61376e-06 1.8e-07 3 1 0 0.00123659 0.00119048 4.6e-05 4 4 1 1.22501e-06 1.2025e-06 2.3e-08 4 2 4 1.71043e-07 1.85e-07 1.4e-08 1 1 4 6.22057e-05 6.61376e-05 3.9e-06 3 0 2 0.000283257 0.000297619 1.4e-05 4 2 0 0.000138185 0.000132275 5.9e-06 3 0 0 0.00855041 0.00833333 0.00022 4 1 0 0.000628507 0.000595238 3.3e-05 4 2 1 1.37709e-05 1.32275e-05 5.4e-07 1 3 0 0.00118823 0.00119048 2.2e-06 1 4 4 1.17146e-06 1.2025e-06 3.1e-08 0 1 1 0.00827531 0.00833333 5.8e-05 SIMPLEX_UNIT_MONOMIAL_INTEGRAL_TEST: Normal end of execution. SIMPLEX_UNIT_SAMPLE_TEST00 Python version: 3.6.5 SIMPLEX_UNIT_SAMPLE samples the unit simplex in M dimensions. Sample points in the unit simplex. Row: 0 1 2 Col 0 : 0.653014 0.0191719 0.0802331 1 : 0.122743 0.379417 0.189469 2 : 0.436322 0.0635846 0.388548 3 : 0.118269 0.0364603 0.029345 4 : 0.0138444 0.134129 0.301972 5 : 0.0207729 0.0237097 0.286511 6 : 0.288996 0.0196653 0.466915 7 : 0.0792463 0.536617 0.149631 8 : 0.0966452 0.51108 0.0596006 9 : 0.366347 0.0599075 0.203121 SIMPLEX_UNIT_SAMPLE_TEST00 Normal end of execution. SIMPLEX_UNIT_SAMPLE_TEST01 SIMPLEX_UNIT_SAMPLE computes a Monte Carlo estimate of an integral over the interior of the unit simplex in 3D. N 1 X Y Z X^2 XY XZ Y^2 YZ Z^2 1 0.166667 0.108836 0.00319531 0.0133722 0.0710712 0.00208659 0.00873222 6.12602e-05 0.00025637 0.00107289 2 0.166667 0.0465888 0.0369168 0.0481681 0.0171202 0.00619286 0.0160657 0.0123334 0.00804945 0.0155724 4 0.166667 0.0184118 0.00891519 0.0451976 0.00408874 0.000514367 0.00618915 0.000844536 0.00239784 0.0163394 8 0.166667 0.0360005 0.0372846 0.0420662 0.0129251 0.00505735 0.00705661 0.0146145 0.00582353 0.019257 16 0.166667 0.0437533 0.0428705 0.046921 0.0191599 0.00974345 0.0100214 0.0169617 0.00989801 0.0194349 32 0.166667 0.0364091 0.0413269 0.0398156 0.0116544 0.00824662 0.0078217 0.0159309 0.00645544 0.0166135 64 0.166667 0.0410983 0.0407457 0.0477179 0.0157147 0.00840319 0.00853668 0.0157488 0.0100792 0.0209082 128 0.166667 0.0410154 0.0392559 0.0419492 0.0163329 0.00727833 0.00896483 0.0151086 0.009015 0.0153849 256 0.166667 0.0411811 0.0434836 0.0394655 0.0171697 0.00850398 0.00748752 0.0180581 0.00824735 0.0154249 512 0.166667 0.0393674 0.0429917 0.0439233 0.0155455 0.00787818 0.00837353 0.0178996 0.00867139 0.0184081 1024 0.166667 0.0416583 0.0409537 0.0418057 0.0169094 0.00809834 0.00814815 0.0162248 0.0081718 0.016949 2048 0.166667 0.0426096 0.0415558 0.0406269 0.017329 0.00872283 0.00819597 0.0162348 0.0081296 0.0159704 4096 0.166667 0.0416662 0.0417558 0.0414527 0.0166896 0.0083384 0.00836203 0.0166834 0.00832732 0.0164112 8192 0.166667 0.0417008 0.0411189 0.0422165 0.016769 0.00828496 0.00847933 0.0163504 0.0082938 0.0169832 16384 0.166667 0.0415194 0.0421521 0.0414839 0.0166988 0.0082595 0.0082619 0.0170481 0.00846335 0.0164934 32768 0.166667 0.0415293 0.0416533 0.0419026 0.0165493 0.00830354 0.00838069 0.0166469 0.00839485 0.0167151 65536 0.166667 0.0413845 0.0417127 0.0414789 0.0164739 0.00829776 0.00825136 0.0167255 0.00830295 0.0165317 Exact 0.166667 0.0416667 0.0416667 0.0416667 0.0166667 0.00833333 0.00833333 0.0166667 0.00833333 0.0166667 SIMPLEX_UNIT_SAMPLE_TEST02 SIMPLEX_UNIT_SAMPLE computes a Monte Carlo estimate of an integral over the interior of the unit simplex in 6D. N 1 U V^2 V^2W^2 X^4 Y^2Z^2 Z^6 1 0.00138889 0.000290196 5.22638e-08 3.44438e-11 5.46945e-08 1.22908e-07 3.74386e-06 2 0.00138889 0.000155902 0.000192056 1.20345e-07 3.36606e-06 1.68906e-09 4.7257e-07 4 0.00138889 7.56665e-05 9.00446e-05 2.83315e-06 4.50826e-07 5.95488e-09 6.99618e-08 8 0.00138889 8.90641e-05 5.72928e-05 2.01558e-06 1.81123e-05 3.74329e-09 7.26724e-08 16 0.00138889 0.000208737 5.02954e-05 6.79761e-07 7.31319e-06 9.83494e-09 7.80523e-07 32 0.00138889 0.000162178 5.72106e-05 1.63594e-06 3.52558e-06 2.23339e-08 2.00419e-06 64 0.00138889 0.000233964 4.57502e-05 7.37006e-07 2.69552e-06 2.10692e-08 7.3948e-07 128 0.00138889 0.000208762 6.43324e-05 1.40103e-06 5.33364e-06 1.86852e-08 7.25176e-07 256 0.00138889 0.000208645 4.88095e-05 1.31562e-06 7.09597e-06 1.74711e-08 1.06163e-06 512 0.00138889 0.000206396 5.02979e-05 1.0006e-06 7.22588e-06 1.71464e-08 8.10567e-07 1024 0.00138889 0.000200898 4.57717e-05 1.08842e-06 5.8484e-06 1.86196e-08 1.53546e-06 2048 0.00138889 0.00019878 4.80666e-05 1.15229e-06 6.51354e-06 1.75557e-08 1.24638e-06 4096 0.00138889 0.000199385 5.01331e-05 1.02137e-06 6.79476e-06 1.68284e-08 1.40324e-06 8192 0.00138889 0.000198351 4.78787e-05 1.06564e-06 6.70696e-06 1.67213e-08 1.49432e-06 16384 0.00138889 0.000199584 5.10857e-05 1.13646e-06 6.42033e-06 1.71447e-08 1.70993e-06 32768 0.00138889 0.000197031 4.97478e-05 1.08659e-06 6.45824e-06 1.72107e-08 1.53712e-06 65536 0.00138889 0.000198098 4.94459e-05 1.10593e-06 6.51338e-06 1.65313e-08 1.4986e-06 Exact 0.00138889 0.000198413 4.96032e-05 1.10229e-06 6.61376e-06 1.67014e-08 1.50313e-06 SIMPLEX_UNIT_TO_GENERAL_TEST01 SIMPLEX_UNIT_TO_GENERAL maps points in the unit simplex to a general simplex. Here we consider a simplex in 2D, a triangle. The vertices of the general triangle are: 1.0000 1.0000 3.0000 1.0000 2.0000 5.0000 ( XSI ETA ) ( X Y ) 0.0000 0.0000 1.0000 1.0000 1.0000 0.0000 3.0000 1.0000 0.0000 1.0000 2.0000 5.0000 0.8679 0.0255 2.7613 1.1019 0.1383 0.2106 1.4872 1.8425 0.2027 0.3299 1.7353 2.3197 0.1128 0.6893 1.9149 3.7572 0.6425 0.1981 2.4831 1.7923 0.8450 0.0145 2.7044 1.0580 0.3465 0.6312 2.3242 3.5247 0.0242 0.2926 1.3410 2.1704 0.3726 0.0254 1.7706 1.1014 0.4083 0.0761 1.8926 1.3046 SIMPLEX_UNIT_TO_GENERAL_TEST02 SIMPLEX_UNIT_TO_GENERAL maps points in the unit simplex to a general simplex. Here we consider a simplex in 3D, a tetrahedron. The vertices of the general tetrahedron are: 1.0000 1.0000 1.0000 3.0000 1.0000 1.0000 1.0000 4.0000 1.0000 1.0000 1.0000 5.0000 ( XSI ETA ) ( X Y ) 0.0000 0.0000 0.0000 1.0000 1.0000 1.0000 1.0000 0.0000 0.0000 3.0000 1.0000 1.0000 0.0000 1.0000 0.0000 1.0000 4.0000 1.0000 0.0000 0.0000 1.0000 1.0000 1.0000 5.0000 0.6530 0.0192 0.0802 2.3060 1.0575 1.3209 0.1227 0.3794 0.1895 1.2455 2.1383 1.7579 0.4363 0.0636 0.3885 1.8726 1.1908 2.5542 0.1183 0.0365 0.0293 1.2365 1.1094 1.1174 0.0138 0.1341 0.3020 1.0277 1.4024 2.2079 0.0208 0.0237 0.2865 1.0415 1.0711 2.1460 0.2890 0.0197 0.4669 1.5780 1.0590 2.8677 0.0792 0.5366 0.1496 1.1585 2.6099 1.5985 0.0966 0.5111 0.0596 1.1933 2.5332 1.2384 0.3663 0.0599 0.2031 1.7327 1.1797 1.8125 SIMPLEX_UNIT_VOLUME_TEST Python version: 3.6.5 SIMPLEX_UNIT_VOLUME returns the volume of the unit simplex in M dimensions. M Volume 1 1 2 0.5 3 0.166667 4 0.0416667 5 0.00833333 6 0.00138889 7 0.000198413 8 2.48016e-05 9 2.75573e-06 SIMPLEX_UNIT_VOLUME_TEST Normal end of execution. SIMPLEX_MONTE_CARLO_TEST: Normal end of execution. Thu Sep 13 17:09:45 2018