diff --git a/.gitignore b/.gitignore index 0505c1b..a222daf 100644 --- a/.gitignore +++ b/.gitignore @@ -20,6 +20,18 @@ GenericPricing/HaskellLH/GenPricing GenericPricing/Orig_COpenMp/GenPricing CalibVolDiff/Original/CalibVol +# Ad-hoc run artifacts +benchmarks/*/implementations/*/result.json +benchmarks/*/implementations/*/runtime.txt + +# all instantiations +instantiations/* + +#all hiperpret-created data +hiperpret/* + # emacs backups *~ +# For development, we instantiate in this directory. +instantiations/ \ No newline at end of file diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..f7271f0 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "hipermark"] + path = hipermark + url = https://github.com/HIPERFIT/hipermark.git diff --git a/InterestCalib/CppOpenCL/Makefile b/InterestCalib/CppOpenCL/Makefile deleted file mode 100644 index 037a4b4..0000000 --- a/InterestCalib/CppOpenCL/Makefile +++ /dev/null @@ -1,48 +0,0 @@ -MAKE_DIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) - -include ../../setup.mk - -ifndef ($(HAVE_GPU)) -include ../../platform.mk -endif - -INCLUDES += -I../includeC -GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -D GPU_DEV_ID=$(GPU_DEVICE_ID) \ - -D GPU_LOC_MEM=$(GPU_LOCAL_MEM) -D GPU_CONST_MEM=$(GPU_CONST_MEM) \ - -D GPU_REG_MEM=$(GPU_REG_MEM) -D GPU_GLB_MEM=$(GPU_DEVICE_MEM) \ - -D GPU_TILE=$(GPU_LOCAL_MEM_PER_TH) -D GPU_CORES=$(GPU_NUM_CORES) \ - -D CURR_DIR_PATH='"$(MAKE_DIR)"' - -SOURCES_CPP =SwapCalib.cpp -HELPERS =../includeC/ParseInput.h -OBJECTS =SwapCalib.o -EXECUTABLE =SwapCalib - - -default: gpu - -.cpp.o: $(SOURCES_CPP) $(HELPERS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< - -# The GPU version is in: ../CppAndGPU. This folder is CPU only! -gpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) $(LIB) - -cpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) $(LIB) - - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: $(EXECUTABLE) - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - -clean: - rm -f $(EXECUTABLE) $(OBJECTS) ./*.ptx SrcCL/*.ptx ./Debug.txt - @# clean nVidia compiler cache - rm -rf $(HOME)/.nv/ComputeCache/* - diff --git a/InterestCalib/CppOpenMP/Makefile b/InterestCalib/CppOpenMP/Makefile deleted file mode 100644 index 0cac6e1..0000000 --- a/InterestCalib/CppOpenMP/Makefile +++ /dev/null @@ -1,42 +0,0 @@ -include ../../setup.mk - -ifndef ($(HAVE_GPU)) -include ../../platform.mk -endif - -INCLUDES += -I../includeC -GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -#-fno-unsafe-math-optimizations -fno-finite-math-only -#-fmath-errno -ftrapping-math -fno-rounding-math -fsignaling-nans - -SOURCES_CPP =SwapCalib.cpp -HELPERS =../includeC/ParseInput.h -OBJECTS =SwapCalib.o -EXECUTABLE =SwapCalib - - -default: cpu - -.cpp.o: $(SOURCES_CPP) $(HELPERS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< - -# The GPU version is in: ../CppAndGPU. This folder is CPU only! -gpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) - -cpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) - - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: $(EXECUTABLE) - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - -clean: - rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) - diff --git a/InterestCalib/CppOpenMP/UtilCPU.h b/InterestCalib/CppOpenMP/UtilCPU.h deleted file mode 100644 index 4ed4ec9..0000000 --- a/InterestCalib/CppOpenMP/UtilCPU.h +++ /dev/null @@ -1,102 +0,0 @@ -#ifndef CPU_UTILITIES -#define CPU_UTILITIES - -/************************/ -/*** Helper Functions ***/ -/************************/ -bool is_pow2(uint n) { - uint c = 1; - while(c < n) { - c = c << 1; - } - return (c == n); -} - - -struct CpuArrays { - // size of the shape array - const uint SS; - - // shape of the irregular arrays for one genome - short* shape; - - // [13 * POP_SIZE] = - // { a, a_p, b, b_p, rho, rho_p, nu, nu_p, - // sigma, sigma_p, logLik, logLik_p, bf_rat } - REAL* genomes; - - // [ 4 * SS * POP_SIZE ] - REAL* ci_t1cs_scale; - - // [ 2 * NUM_SWAP_QUOTES * POP_SIZE ] - REAL* new_quote_price; - - // [ NUM_SWAP_QUOTES*NUM_HERMITE ] - REAL* accum0; - - // [ 8 * NUM_SWAP_QUOTES * POP_SIZE ] - // { mux, muy, sqrt_sigmax = sqrt(2.0) * sigmax, - // t2 = rhoxy / (sigmax*rhoxycs), sigmay_rhoxycs, zc_mat, f, df } - REAL* scalars; - - REAL gene_ranges[10]; - - CpuArrays (const uint n, short* shp) : SS(n) { - shape = shp; - - genomes = new REAL[ 13 * POP_SIZE ]; - ci_t1cs_scale = new REAL[ 4 * SS * POP_SIZE ]; - scalars = new REAL[ 8 * NUM_SWAP_QUOTES * POP_SIZE ]; - - new_quote_price = new REAL [ 2 * NUM_SWAP_QUOTES * POP_SIZE ]; - accum0 = new REAL [ NUM_SWAP_QUOTES * NUM_HERMITE * POP_SIZE ]; - - for(int i=0; i<5; i++) { gene_ranges[i] = g_mins[i]; } - for(int i=0; i<5; i++) { gene_ranges[i+5] = g_maxs[i]; } - } - - void releaseResources() { - delete[] shape; - delete[] genomes; - delete[] ci_t1cs_scale; - delete[] scalars; - delete[] new_quote_price; - delete[] accum0; - } - - // genome helpers - REAL* get_a () { return genomes; } - REAL* get_b () { return genomes + POP_SIZE*2; } - REAL* get_rho () { return genomes + POP_SIZE*4; } - REAL* get_nu () { return genomes + POP_SIZE*6; } - REAL* get_sigma () { return genomes + POP_SIZE*8; } - REAL* get_logLik() { return genomes + POP_SIZE*10;} - REAL* get_bf_rat() { return genomes + POP_SIZE*12;} - - // get the shape of the irregular array (for one genome) - short* get_shape (){ return shape; } - - // get the start iterator into arrays ci, t1cs, scale for genome i - REAL* get_ci (int i) { return ci_t1cs_scale + SS*i; } - REAL* get_t1cs (int i) { return ci_t1cs_scale + SS*i + SS*POP_SIZE; } - REAL* get_scale (int i) { return ci_t1cs_scale + SS*i + 2*SS*POP_SIZE; } - REAL* get_bbi (int i) { return ci_t1cs_scale + SS*i + 3*SS*POP_SIZE; } - - // get the start iterator into array-expanded scalars for genome i - REAL* get_mux (int i) { return scalars + i * NUM_SWAP_QUOTES ; } - REAL* get_muy (int i) { return scalars + i * NUM_SWAP_QUOTES + NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_sqsigx(int i) { return scalars + i * NUM_SWAP_QUOTES + 2 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_t2 (int i) { return scalars + i * NUM_SWAP_QUOTES + 3 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_sigrho(int i) { return scalars + i * NUM_SWAP_QUOTES + 4 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_zcmat (int i) { return scalars + i * NUM_SWAP_QUOTES + 5 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_f (int i) { return scalars + i * NUM_SWAP_QUOTES + 6 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_df (int i) { return scalars + i * NUM_SWAP_QUOTES + 7 * NUM_SWAP_QUOTES * POP_SIZE; } - - // get the quotes prices for genome i - REAL* get_quote (int i) { return new_quote_price + i * NUM_SWAP_QUOTES; } - REAL* get_price (int i) { return new_quote_price + i * NUM_SWAP_QUOTES + NUM_SWAP_QUOTES * POP_SIZE; } - - // get the accumulator for the irregular array for genome i - REAL* get_accum (int i) { return accum0 + i * NUM_SWAP_QUOTES * NUM_HERMITE; } -}; -#endif // CPU_UTILITIES diff --git a/InterestCalib/Data/Large/output.data b/InterestCalib/Data/Large/output.data deleted file mode 100644 index ee3d804..0000000 --- a/InterestCalib/Data/Large/output.data +++ /dev/null @@ -1,206 +0,0 @@ -0.023511 // a-field of the winning genome -0.964110 // b-field of the winning genome -0.025390 // sigma-field of the winning genome -0.142763 // nu-field of the winning genome --0.912444 // rho-field of the winning genome -504.367344 // LgLikelihood of the winning genome - -[ - [ 157.397565 , 115.320470 , 36.487100 ], - [ 158.760952 , 162.945479 , 2.568054 ], - [ 165.097976 , 174.297729 , 5.278183 ], - [ 175.510974 , 171.631308 , 2.260465 ], - [ 185.096581 , 168.408756 , 9.909120 ], - [ 193.322704 , 168.310831 , 14.860525 ], - [ 199.745999 , 169.877089 , 17.582659 ], - [ 204.980646 , 172.511293 , 18.821581 ], - [ 207.965455 , 172.824865 , 20.333063 ], - [ 210.211604 , 172.561368 , 21.818462 ], - [ 209.496752 , 177.275607 , 18.175735 ], - [ 198.058665 , 161.933876 , 22.308358 ], - [ 180.931070 , 139.430038 , 29.764772 ], - [ 162.740296 , 120.029132 , 35.583998 ], - [ 180.828953 , 136.735565 , 32.247198 ], - [ 197.570095 , 228.603138 , 13.575073 ], - [ 231.652896 , 275.866189 , 16.027079 ], - [ 267.035700 , 293.303444 , 8.955825 ], - [ 296.574053 , 305.655752 , 2.971218 ], - [ 320.041550 , 313.896508 , 1.957665 ], - [ 338.547315 , 323.484107 , 4.656553 ], - [ 352.372052 , 330.054072 , 6.761916 ], - [ 362.299599 , 335.261016 , 8.064935 ], - [ 369.752884 , 335.769411 , 10.121075 ], - [ 379.269057 , 354.321026 , 7.041081 ], - [ 362.343709 , 318.366856 , 13.813264 ], - [ 333.799298 , 274.710927 , 21.509290 ], - [ 301.589807 , 236.227803 , 27.669057 ], - [ 172.210684 , 192.203184 , 10.401753 ], - [ 227.955695 , 306.754568 , 25.687922 ], - [ 299.934061 , 377.675217 , 20.584129 ], - [ 362.136697 , 412.847194 , 12.283115 ], - [ 410.791383 , 436.793689 , 5.952995 ], - [ 448.676865 , 457.418930 , 1.911173 ], - [ 477.384722 , 472.046625 , 1.130841 ], - [ 499.183038 , 483.257228 , 3.295514 ], - [ 515.122617 , 491.981354 , 4.703687 ], - [ 527.462746 , 496.017051 , 6.339640 ], - [ 543.860701 , 526.391523 , 3.318666 ], - [ 520.875868 , 470.271579 , 10.760652 ], - [ 480.620983 , 406.010507 , 18.376489 ], - [ 434.912156 , 349.521869 , 24.430599 ], - [ 175.817605 , 234.956228 , 25.170060 ], - [ 281.983907 , 379.997542 , 25.793229 ], - [ 386.986699 , 470.343801 , 17.722590 ], - [ 470.710384 , 525.541048 , 10.433184 ], - [ 534.924952 , 566.158092 , 5.516682 ], - [ 583.629049 , 592.597274 , 1.513376 ], - [ 620.647894 , 612.901965 , 1.263812 ], - [ 648.638703 , 631.047390 , 2.787637 ], - [ 669.568744 , 645.427184 , 3.740400 ], - [ 684.736202 , 654.142965 , 4.676843 ], - [ 704.954513 , 694.837660 , 1.456002 ], - [ 674.726162 , 617.784741 , 9.217033 ], - [ 622.980296 , 533.755298 , 16.716461 ], - [ 563.277986 , 459.106740 , 22.689984 ], - [ 203.693343 , 276.585395 , 26.354266 ], - [ 354.131456 , 452.559843 , 21.749253 ], - [ 484.673742 , 563.065703 , 13.922347 ], - [ 585.697217 , 634.734726 , 7.725670 ], - [ 661.769994 , 685.829366 , 3.508070 ], - [ 719.413650 , 722.893858 , 0.481427 ], - [ 763.082942 , 749.627445 , 1.794958 ], - [ 796.409044 , 777.716103 , 2.403569 ], - [ 820.552620 , 793.738233 , 3.378241 ], - [ 838.266809 , 814.271603 , 2.946831 ], - [ 860.928096 , 858.501503 , 0.282654 ], - [ 824.031243 , 761.317980 , 8.237460 ], - [ 760.549282 , 657.575731 , 15.659573 ], - [ 687.849618 , 565.396155 , 21.657994 ], - [ 248.505950 , 302.881789 , 17.952826 ], - [ 434.064679 , 507.004879 , 14.386489 ], - [ 585.500618 , 646.006214 , 9.366101 ], - [ 700.296189 , 732.520960 , 4.399160 ], - [ 786.607031 , 799.352396 , 1.594461 ], - [ 851.884344 , 846.847045 , 0.594830 ], - [ 901.714482 , 886.814283 , 1.680194 ], - [ 939.036181 , 919.813612 , 2.089833 ], - [ 966.478792 , 947.705019 , 1.980972 ], - [ 986.566873 , 973.538216 , 1.338279 ], - [ 1012.284446 , 1018.774022 , 0.636999 ], - [ 968.529570 , 900.113746 , 7.600798 ], - [ 894.291386 , 777.120699 , 15.077540 ], - [ 809.047014 , 668.478449 , 21.028137 ], - [ 301.083452 , 329.637202 , 8.662175 ], - [ 515.826990 , 565.288233 , 8.749739 ], - [ 684.590231 , 726.481623 , 5.766339 ], - [ 811.675874 , 826.947428 , 1.846738 ], - [ 907.198294 , 908.089329 , 0.098122 ], - [ 979.880266 , 969.342726 , 1.087081 ], - [ 1034.847365 , 1020.253181 , 1.430447 ], - [ 1076.438202 , 1064.021851 , 1.166926 ], - [ 1107.169795 , 1100.814671 , 0.577311 ], - [ 1130.070001 , 1133.431347 , 0.296564 ], - [ 1158.486301 , 1173.896940 , 1.312776 ], - [ 1108.583472 , 1034.952546 , 7.114425 ], - [ 1023.739103 , 893.361764 , 14.594014 ], - [ 926.405670 , 768.766979 , 20.505393 ], - [ 356.263480 , 356.827677 , 0.158115 ], - [ 595.869060 , 617.529617 , 3.507614 ], - [ 780.304180 , 799.855865 , 2.444401 ], - [ 918.734772 , 925.119226 , 0.690122 ], - [ 1023.322212 , 1016.348538 , 0.686150 ], - [ 1102.541547 , 1091.098583 , 1.048756 ], - [ 1162.947248 , 1155.093079 , 0.679960 ], - [ 1208.815882 , 1211.268964 , 0.202522 ], - [ 1243.236271 , 1253.935152 , 0.853224 ], - [ 1268.212772 , 1292.295297 , 1.863547 ], - [ 1299.649410 , 1322.310735 , 1.713767 ], - [ 1243.247078 , 1165.542638 , 6.666804 ], - [ 1147.864983 , 1006.341959 , 14.063115 ], - [ 1037.737231 , 865.928307 , 19.841010 ], - [ 411.077411 , 385.708301 , 6.577279 ], - [ 673.052319 , 670.320845 , 0.407487 ], - [ 872.045789 , 871.766681 , 0.032016 ], - [ 1021.605672 , 1014.726741 , 0.677910 ], - [ 1134.443556 , 1123.647094 , 0.960841 ], - [ 1220.439476 , 1216.562717 , 0.318665 ], - [ 1286.238835 , 1291.521445 , 0.409022 ], - [ 1336.683060 , 1357.265823 , 1.516487 ], - [ 1373.994926 , 1405.905836 , 2.269776 ], - [ 1401.325508 , 1449.385390 , 3.315880 ], - [ 1434.917178 , 1466.233816 , 2.135856 ], - [ 1371.509883 , 1292.197312 , 6.137807 ], - [ 1264.493843 , 1115.647694 , 13.341680 ], - [ 1141.954794 , 960.931878 , 18.838267 ], - [ 464.369070 , 417.340024 , 11.268760 ], - [ 746.924235 , 725.581250 , 2.941502 ], - [ 960.029056 , 944.790788 , 1.612872 ], - [ 1119.892820 , 1104.819384 , 1.364335 ], - [ 1241.112296 , 1233.382877 , 0.626684 ], - [ 1333.761841 , 1339.925477 , 0.459998 ], - [ 1405.131840 , 1430.418237 , 1.767762 ], - [ 1459.286022 , 1504.133035 , 2.981586 ], - [ 1499.614145 , 1558.787332 , 3.796104 ], - [ 1529.026303 , 1603.723695 , 4.657747 ], - [ 1563.609130 , 1617.465612 , 3.329683 ], - [ 1491.509266 , 1414.735272 , 5.426739 ], - [ 1372.969721 , 1221.580427 , 12.392904 ], - [ 1238.265153 , 1052.546538 , 17.644694 ], - [ 697.607256 , 530.230908 , 31.566690 ], - [ 1069.199975 , 947.532306 , 12.840477 ], - [ 1345.044085 , 1275.884477 , 5.420523 ], - [ 1552.898160 , 1525.869310 , 1.771374 ], - [ 1711.010275 , 1711.039174 , 0.001689 ], - [ 1831.352455 , 1869.396149 , 2.035079 ], - [ 1922.088013 , 1996.914758 , 3.747118 ], - [ 1989.466621 , 2097.112670 , 5.133060 ], - [ 2037.854512 , 2165.268099 , 5.884425 ], - [ 2071.221986 , 2214.863774 , 6.485355 ], - [ 2085.093776 , 2210.469050 , 5.671886 ], - [ 1964.177356 , 1958.551506 , 0.287245 ], - [ 1790.799073 , 1696.520335 , 5.557183 ], - [ 1603.204230 , 1464.255987 , 9.489341 ], - [ 880.212905 , 661.437438 , 33.075761 ], - [ 1324.703181 , 1198.312686 , 10.547372 ], - [ 1650.853118 , 1613.025965 , 2.345105 ], - [ 1893.136248 , 1919.256956 , 1.360980 ], - [ 2073.770699 , 2162.521880 , 4.104059 ], - [ 2206.964010 , 2342.159055 , 5.772240 ], - [ 2304.126621 , 2488.030128 , 7.391531 ], - [ 2373.154766 , 2604.805409 , 8.893203 ], - [ 2420.005673 , 2685.680924 , 9.892286 ], - [ 2448.863167 , 2735.089966 , 10.464987 ], - [ 2422.889960 , 2699.275863 , 10.239261 ], - [ 2253.562833 , 2403.016190 , 6.219407 ], - [ 2034.519052 , 2098.532599 , 3.050396 ], - [ 1806.243306 , 1816.122090 , 0.543949 ], - [ 1023.193649 , 776.276975 , 31.807806 ], - [ 1525.146555 , 1409.444747 , 8.209035 ], - [ 1886.122306 , 1904.185866 , 0.948624 ], - [ 2148.130146 , 2251.764495 , 4.602362 ], - [ 2338.190044 , 2542.942445 , 8.051791 ], - [ 2474.348845 , 2745.634809 , 9.880628 ], - [ 2570.187192 , 2901.373100 , 11.414799 ], - [ 2635.146070 , 3027.489893 , 12.959377 ], - [ 2675.747420 , 3100.613536 , 13.702647 ], - [ 2697.190433 , 3157.776542 , 14.585773 ], - [ 2625.390139 , 3097.907042 , 15.252779 ], - [ 2405.414280 , 2785.983861 , 13.660150 ], - [ 2140.334096 , 2435.764543 , 12.128859 ], - [ 1918.911826 , 2120.329248 , 9.499346 ], - [ 1134.844622 , 876.885316 , 29.417679 ], - [ 1679.290415 , 1587.638861 , 5.772821 ], - [ 2062.069732 , 2124.580533 , 2.942266 ], - [ 2333.411719 , 2509.129235 , 7.003127 ], - [ 2525.701359 , 2819.187942 , 10.410323 ], - [ 2659.649760 , 3044.948789 , 12.653711 ], - [ 2750.616462 , 3196.018358 , 13.936150 ], - [ 2808.740074 , 3339.851753 , 15.902253 ], - [ 2841.435455 , 3435.052610 , 17.281166 ], - [ 2854.008165 , 3482.652710 , 18.050739 ], - [ 2726.384653 , 3448.098035 , 20.930767 ], - [ 2458.831616 , 3105.329082 , 20.818968 ], - [ 2239.608440 , 2736.951332 , 18.171419 ], - [ 1972.754114 , 2378.093534 , 17.044722 ] -] //Swaption Calibration Result: foreach swaption [CalibPrice,BlackPrice,PercentDiff] - diff --git a/InterestCalib/Data/Medium/output.data b/InterestCalib/Data/Medium/output.data deleted file mode 100644 index ee3d804..0000000 --- a/InterestCalib/Data/Medium/output.data +++ /dev/null @@ -1,206 +0,0 @@ -0.023511 // a-field of the winning genome -0.964110 // b-field of the winning genome -0.025390 // sigma-field of the winning genome -0.142763 // nu-field of the winning genome --0.912444 // rho-field of the winning genome -504.367344 // LgLikelihood of the winning genome - -[ - [ 157.397565 , 115.320470 , 36.487100 ], - [ 158.760952 , 162.945479 , 2.568054 ], - [ 165.097976 , 174.297729 , 5.278183 ], - [ 175.510974 , 171.631308 , 2.260465 ], - [ 185.096581 , 168.408756 , 9.909120 ], - [ 193.322704 , 168.310831 , 14.860525 ], - [ 199.745999 , 169.877089 , 17.582659 ], - [ 204.980646 , 172.511293 , 18.821581 ], - [ 207.965455 , 172.824865 , 20.333063 ], - [ 210.211604 , 172.561368 , 21.818462 ], - [ 209.496752 , 177.275607 , 18.175735 ], - [ 198.058665 , 161.933876 , 22.308358 ], - [ 180.931070 , 139.430038 , 29.764772 ], - [ 162.740296 , 120.029132 , 35.583998 ], - [ 180.828953 , 136.735565 , 32.247198 ], - [ 197.570095 , 228.603138 , 13.575073 ], - [ 231.652896 , 275.866189 , 16.027079 ], - [ 267.035700 , 293.303444 , 8.955825 ], - [ 296.574053 , 305.655752 , 2.971218 ], - [ 320.041550 , 313.896508 , 1.957665 ], - [ 338.547315 , 323.484107 , 4.656553 ], - [ 352.372052 , 330.054072 , 6.761916 ], - [ 362.299599 , 335.261016 , 8.064935 ], - [ 369.752884 , 335.769411 , 10.121075 ], - [ 379.269057 , 354.321026 , 7.041081 ], - [ 362.343709 , 318.366856 , 13.813264 ], - [ 333.799298 , 274.710927 , 21.509290 ], - [ 301.589807 , 236.227803 , 27.669057 ], - [ 172.210684 , 192.203184 , 10.401753 ], - [ 227.955695 , 306.754568 , 25.687922 ], - [ 299.934061 , 377.675217 , 20.584129 ], - [ 362.136697 , 412.847194 , 12.283115 ], - [ 410.791383 , 436.793689 , 5.952995 ], - [ 448.676865 , 457.418930 , 1.911173 ], - [ 477.384722 , 472.046625 , 1.130841 ], - [ 499.183038 , 483.257228 , 3.295514 ], - [ 515.122617 , 491.981354 , 4.703687 ], - [ 527.462746 , 496.017051 , 6.339640 ], - [ 543.860701 , 526.391523 , 3.318666 ], - [ 520.875868 , 470.271579 , 10.760652 ], - [ 480.620983 , 406.010507 , 18.376489 ], - [ 434.912156 , 349.521869 , 24.430599 ], - [ 175.817605 , 234.956228 , 25.170060 ], - [ 281.983907 , 379.997542 , 25.793229 ], - [ 386.986699 , 470.343801 , 17.722590 ], - [ 470.710384 , 525.541048 , 10.433184 ], - [ 534.924952 , 566.158092 , 5.516682 ], - [ 583.629049 , 592.597274 , 1.513376 ], - [ 620.647894 , 612.901965 , 1.263812 ], - [ 648.638703 , 631.047390 , 2.787637 ], - [ 669.568744 , 645.427184 , 3.740400 ], - [ 684.736202 , 654.142965 , 4.676843 ], - [ 704.954513 , 694.837660 , 1.456002 ], - [ 674.726162 , 617.784741 , 9.217033 ], - [ 622.980296 , 533.755298 , 16.716461 ], - [ 563.277986 , 459.106740 , 22.689984 ], - [ 203.693343 , 276.585395 , 26.354266 ], - [ 354.131456 , 452.559843 , 21.749253 ], - [ 484.673742 , 563.065703 , 13.922347 ], - [ 585.697217 , 634.734726 , 7.725670 ], - [ 661.769994 , 685.829366 , 3.508070 ], - [ 719.413650 , 722.893858 , 0.481427 ], - [ 763.082942 , 749.627445 , 1.794958 ], - [ 796.409044 , 777.716103 , 2.403569 ], - [ 820.552620 , 793.738233 , 3.378241 ], - [ 838.266809 , 814.271603 , 2.946831 ], - [ 860.928096 , 858.501503 , 0.282654 ], - [ 824.031243 , 761.317980 , 8.237460 ], - [ 760.549282 , 657.575731 , 15.659573 ], - [ 687.849618 , 565.396155 , 21.657994 ], - [ 248.505950 , 302.881789 , 17.952826 ], - [ 434.064679 , 507.004879 , 14.386489 ], - [ 585.500618 , 646.006214 , 9.366101 ], - [ 700.296189 , 732.520960 , 4.399160 ], - [ 786.607031 , 799.352396 , 1.594461 ], - [ 851.884344 , 846.847045 , 0.594830 ], - [ 901.714482 , 886.814283 , 1.680194 ], - [ 939.036181 , 919.813612 , 2.089833 ], - [ 966.478792 , 947.705019 , 1.980972 ], - [ 986.566873 , 973.538216 , 1.338279 ], - [ 1012.284446 , 1018.774022 , 0.636999 ], - [ 968.529570 , 900.113746 , 7.600798 ], - [ 894.291386 , 777.120699 , 15.077540 ], - [ 809.047014 , 668.478449 , 21.028137 ], - [ 301.083452 , 329.637202 , 8.662175 ], - [ 515.826990 , 565.288233 , 8.749739 ], - [ 684.590231 , 726.481623 , 5.766339 ], - [ 811.675874 , 826.947428 , 1.846738 ], - [ 907.198294 , 908.089329 , 0.098122 ], - [ 979.880266 , 969.342726 , 1.087081 ], - [ 1034.847365 , 1020.253181 , 1.430447 ], - [ 1076.438202 , 1064.021851 , 1.166926 ], - [ 1107.169795 , 1100.814671 , 0.577311 ], - [ 1130.070001 , 1133.431347 , 0.296564 ], - [ 1158.486301 , 1173.896940 , 1.312776 ], - [ 1108.583472 , 1034.952546 , 7.114425 ], - [ 1023.739103 , 893.361764 , 14.594014 ], - [ 926.405670 , 768.766979 , 20.505393 ], - [ 356.263480 , 356.827677 , 0.158115 ], - [ 595.869060 , 617.529617 , 3.507614 ], - [ 780.304180 , 799.855865 , 2.444401 ], - [ 918.734772 , 925.119226 , 0.690122 ], - [ 1023.322212 , 1016.348538 , 0.686150 ], - [ 1102.541547 , 1091.098583 , 1.048756 ], - [ 1162.947248 , 1155.093079 , 0.679960 ], - [ 1208.815882 , 1211.268964 , 0.202522 ], - [ 1243.236271 , 1253.935152 , 0.853224 ], - [ 1268.212772 , 1292.295297 , 1.863547 ], - [ 1299.649410 , 1322.310735 , 1.713767 ], - [ 1243.247078 , 1165.542638 , 6.666804 ], - [ 1147.864983 , 1006.341959 , 14.063115 ], - [ 1037.737231 , 865.928307 , 19.841010 ], - [ 411.077411 , 385.708301 , 6.577279 ], - [ 673.052319 , 670.320845 , 0.407487 ], - [ 872.045789 , 871.766681 , 0.032016 ], - [ 1021.605672 , 1014.726741 , 0.677910 ], - [ 1134.443556 , 1123.647094 , 0.960841 ], - [ 1220.439476 , 1216.562717 , 0.318665 ], - [ 1286.238835 , 1291.521445 , 0.409022 ], - [ 1336.683060 , 1357.265823 , 1.516487 ], - [ 1373.994926 , 1405.905836 , 2.269776 ], - [ 1401.325508 , 1449.385390 , 3.315880 ], - [ 1434.917178 , 1466.233816 , 2.135856 ], - [ 1371.509883 , 1292.197312 , 6.137807 ], - [ 1264.493843 , 1115.647694 , 13.341680 ], - [ 1141.954794 , 960.931878 , 18.838267 ], - [ 464.369070 , 417.340024 , 11.268760 ], - [ 746.924235 , 725.581250 , 2.941502 ], - [ 960.029056 , 944.790788 , 1.612872 ], - [ 1119.892820 , 1104.819384 , 1.364335 ], - [ 1241.112296 , 1233.382877 , 0.626684 ], - [ 1333.761841 , 1339.925477 , 0.459998 ], - [ 1405.131840 , 1430.418237 , 1.767762 ], - [ 1459.286022 , 1504.133035 , 2.981586 ], - [ 1499.614145 , 1558.787332 , 3.796104 ], - [ 1529.026303 , 1603.723695 , 4.657747 ], - [ 1563.609130 , 1617.465612 , 3.329683 ], - [ 1491.509266 , 1414.735272 , 5.426739 ], - [ 1372.969721 , 1221.580427 , 12.392904 ], - [ 1238.265153 , 1052.546538 , 17.644694 ], - [ 697.607256 , 530.230908 , 31.566690 ], - [ 1069.199975 , 947.532306 , 12.840477 ], - [ 1345.044085 , 1275.884477 , 5.420523 ], - [ 1552.898160 , 1525.869310 , 1.771374 ], - [ 1711.010275 , 1711.039174 , 0.001689 ], - [ 1831.352455 , 1869.396149 , 2.035079 ], - [ 1922.088013 , 1996.914758 , 3.747118 ], - [ 1989.466621 , 2097.112670 , 5.133060 ], - [ 2037.854512 , 2165.268099 , 5.884425 ], - [ 2071.221986 , 2214.863774 , 6.485355 ], - [ 2085.093776 , 2210.469050 , 5.671886 ], - [ 1964.177356 , 1958.551506 , 0.287245 ], - [ 1790.799073 , 1696.520335 , 5.557183 ], - [ 1603.204230 , 1464.255987 , 9.489341 ], - [ 880.212905 , 661.437438 , 33.075761 ], - [ 1324.703181 , 1198.312686 , 10.547372 ], - [ 1650.853118 , 1613.025965 , 2.345105 ], - [ 1893.136248 , 1919.256956 , 1.360980 ], - [ 2073.770699 , 2162.521880 , 4.104059 ], - [ 2206.964010 , 2342.159055 , 5.772240 ], - [ 2304.126621 , 2488.030128 , 7.391531 ], - [ 2373.154766 , 2604.805409 , 8.893203 ], - [ 2420.005673 , 2685.680924 , 9.892286 ], - [ 2448.863167 , 2735.089966 , 10.464987 ], - [ 2422.889960 , 2699.275863 , 10.239261 ], - [ 2253.562833 , 2403.016190 , 6.219407 ], - [ 2034.519052 , 2098.532599 , 3.050396 ], - [ 1806.243306 , 1816.122090 , 0.543949 ], - [ 1023.193649 , 776.276975 , 31.807806 ], - [ 1525.146555 , 1409.444747 , 8.209035 ], - [ 1886.122306 , 1904.185866 , 0.948624 ], - [ 2148.130146 , 2251.764495 , 4.602362 ], - [ 2338.190044 , 2542.942445 , 8.051791 ], - [ 2474.348845 , 2745.634809 , 9.880628 ], - [ 2570.187192 , 2901.373100 , 11.414799 ], - [ 2635.146070 , 3027.489893 , 12.959377 ], - [ 2675.747420 , 3100.613536 , 13.702647 ], - [ 2697.190433 , 3157.776542 , 14.585773 ], - [ 2625.390139 , 3097.907042 , 15.252779 ], - [ 2405.414280 , 2785.983861 , 13.660150 ], - [ 2140.334096 , 2435.764543 , 12.128859 ], - [ 1918.911826 , 2120.329248 , 9.499346 ], - [ 1134.844622 , 876.885316 , 29.417679 ], - [ 1679.290415 , 1587.638861 , 5.772821 ], - [ 2062.069732 , 2124.580533 , 2.942266 ], - [ 2333.411719 , 2509.129235 , 7.003127 ], - [ 2525.701359 , 2819.187942 , 10.410323 ], - [ 2659.649760 , 3044.948789 , 12.653711 ], - [ 2750.616462 , 3196.018358 , 13.936150 ], - [ 2808.740074 , 3339.851753 , 15.902253 ], - [ 2841.435455 , 3435.052610 , 17.281166 ], - [ 2854.008165 , 3482.652710 , 18.050739 ], - [ 2726.384653 , 3448.098035 , 20.930767 ], - [ 2458.831616 , 3105.329082 , 20.818968 ], - [ 2239.608440 , 2736.951332 , 18.171419 ], - [ 1972.754114 , 2378.093534 , 17.044722 ] -] //Swaption Calibration Result: foreach swaption [CalibPrice,BlackPrice,PercentDiff] - diff --git a/InterestCalib/Data/Small/output.data b/InterestCalib/Data/Small/output.data deleted file mode 100644 index 244da62..0000000 --- a/InterestCalib/Data/Small/output.data +++ /dev/null @@ -1,206 +0,0 @@ -0.325608 // a-field of the winning genome -0.001000 // b-field of the winning genome -0.009058 // sigma-field of the winning genome -0.018683 // nu-field of the winning genome --0.083963 // rho-field of the winning genome -624.116935 // LgLikelihood of the winning genome - -[ - [ 74.172585 , 115.320470 , 35.681337 ], - [ 100.626570 , 162.945479 , 38.245252 ], - [ 118.719023 , 174.297729 , 31.887223 ], - [ 132.735321 , 171.631308 , 22.662524 ], - [ 143.164628 , 168.408756 , 14.989796 ], - [ 151.813418 , 168.310831 , 9.801754 ], - [ 158.832697 , 169.877089 , 6.501402 ], - [ 164.984854 , 172.511293 , 4.362868 ], - [ 169.170571 , 172.824865 , 2.114449 ], - [ 172.872471 , 172.561368 , 0.180286 ], - [ 181.530751 , 177.275607 , 2.400298 ], - [ 180.340962 , 161.933876 , 11.367038 ], - [ 172.565436 , 139.430038 , 23.764892 ], - [ 162.247156 , 120.029132 , 35.173148 ], - [ 74.172585 , 69.393222 , 6.887362 ], - [ 100.626570 , 116.015964 , 13.264894 ], - [ 118.719023 , 139.816103 , 15.089163 ], - [ 132.735321 , 149.054929 , 10.948721 ], - [ 143.164628 , 155.120122 , 7.707249 ], - [ 151.813418 , 159.302301 , 4.701052 ], - [ 158.832697 , 163.950093 , 3.121313 ], - [ 164.984854 , 167.731363 , 1.637445 ], - [ 169.170571 , 170.144777 , 0.572575 ], - [ 172.872471 , 170.402787 , 1.449321 ], - [ 181.530751 , 179.579039 , 1.086827 ], - [ 180.340962 , 161.791994 , 11.464700 ], - [ 172.565436 , 139.415641 , 23.777673 ], - [ 162.247156 , 119.885477 , 35.335121 ], - [ 74.172585 , 65.999080 , 12.384271 ], - [ 100.626570 , 105.242095 , 4.385626 ], - [ 118.719023 , 129.573722 , 8.377237 ], - [ 132.735321 , 142.022857 , 6.539466 ], - [ 143.164628 , 149.987013 , 4.548651 ], - [ 151.813418 , 156.932387 , 3.261895 ], - [ 158.832697 , 161.950891 , 1.925395 ], - [ 164.984854 , 166.244493 , 0.757703 ], - [ 169.170571 , 168.937454 , 0.137990 ], - [ 172.872471 , 170.174723 , 1.585282 ], - [ 181.530751 , 180.595670 , 0.517776 ], - [ 180.340962 , 161.777322 , 11.474810 ], - [ 172.565436 , 139.416628 , 23.776797 ], - [ 162.247156 , 119.914803 , 35.302024 ], - [ 74.172585 , 61.368583 , 20.864099 ], - [ 100.626570 , 99.252149 , 1.384777 ], - [ 118.719023 , 122.849829 , 3.362484 ], - [ 132.735321 , 137.637329 , 3.561540 ], - [ 143.164628 , 147.875713 , 3.185841 ], - [ 151.813418 , 154.781404 , 1.917534 ], - [ 158.832697 , 160.084818 , 0.782161 ], - [ 164.984854 , 165.269065 , 0.171969 ], - [ 169.170571 , 168.580130 , 0.350243 ], - [ 172.872471 , 170.856618 , 1.179851 ], - [ 181.530751 , 181.485729 , 0.024807 ], - [ 180.340962 , 161.795624 , 11.462200 ], - [ 172.565436 , 139.412376 , 23.780571 ], - [ 162.247156 , 119.914803 , 35.302024 ], - [ 74.172585 , 58.655078 , 26.455521 ], - [ 100.626570 , 95.973733 , 4.848031 ], - [ 118.719023 , 119.408556 , 0.577457 ], - [ 132.735321 , 134.902103 , 1.606189 ], - [ 143.164628 , 145.442875 , 1.566421 ], - [ 151.813418 , 153.303090 , 0.971717 ], - [ 158.832697 , 158.972444 , 0.087907 ], - [ 164.984854 , 165.290371 , 0.184837 ], - [ 169.170571 , 168.326957 , 0.501176 ], - [ 172.872471 , 172.681440 , 0.110626 ], - [ 181.530751 , 182.061213 , 0.291365 ], - [ 180.340962 , 161.805228 , 11.455584 ], - [ 172.565436 , 139.451166 , 23.746141 ], - [ 162.247156 , 119.902772 , 35.315600 ], - [ 74.172585 , 54.317928 , 36.552677 ], - [ 100.626570 , 90.924762 , 10.670150 ], - [ 118.719023 , 115.804615 , 2.516660 ], - [ 132.735321 , 131.667834 , 0.810742 ], - [ 143.164628 , 143.353504 , 0.131756 ], - [ 151.813418 , 151.871055 , 0.037951 ], - [ 158.832697 , 158.972444 , 0.087907 ], - [ 164.984854 , 165.332970 , 0.210555 ], - [ 169.170571 , 169.958627 , 0.463675 ], - [ 172.872471 , 174.591476 , 0.984587 ], - [ 181.530751 , 182.627862 , 0.600736 ], - [ 180.340962 , 161.791994 , 11.464700 ], - [ 172.565436 , 139.366537 , 23.821284 ], - [ 162.247156 , 119.882956 , 35.337967 ], - [ 74.172585 , 51.415081 , 44.262312 ], - [ 100.626570 , 88.139705 , 14.167127 ], - [ 118.719023 , 113.272969 , 4.807903 ], - [ 132.735321 , 129.285558 , 2.668328 ], - [ 143.164628 , 141.639008 , 1.077118 ], - [ 151.813418 , 151.139856 , 0.445654 ], - [ 158.832697 , 159.077811 , 0.154085 ], - [ 164.984854 , 166.349944 , 0.820614 ], - [ 169.170571 , 171.699296 , 1.472764 ], - [ 172.872471 , 176.724544 , 2.179704 ], - [ 181.530751 , 183.033936 , 0.821260 ], - [ 180.340962 , 161.805228 , 11.455584 ], - [ 172.565436 , 139.341880 , 23.843195 ], - [ 162.247156 , 119.866098 , 35.357001 ], - [ 74.172585 , 49.394757 , 50.162869 ], - [ 100.626570 , 85.483070 , 17.715203 ], - [ 118.719023 , 110.722034 , 7.222582 ], - [ 132.735321 , 128.407529 , 3.370356 ], - [ 143.164628 , 140.690570 , 1.758510 ], - [ 151.813418 , 151.038030 , 0.513372 ], - [ 158.832697 , 159.896627 , 0.665386 ], - [ 164.984854 , 168.125416 , 1.867988 ], - [ 169.170571 , 173.579086 , 2.539774 ], - [ 172.872471 , 178.889185 , 3.363375 ], - [ 181.530751 , 183.044146 , 0.826792 ], - [ 180.340962 , 161.778554 , 11.473961 ], - [ 172.565436 , 139.305384 , 23.875640 ], - [ 162.247156 , 119.868276 , 35.354542 ], - [ 74.172585 , 48.150355 , 54.043693 ], - [ 100.626570 , 83.680300 , 20.251205 ], - [ 118.719023 , 108.828031 , 9.088644 ], - [ 132.735321 , 126.982834 , 4.530130 ], - [ 143.164628 , 140.271822 , 2.062285 ], - [ 151.813418 , 151.871055 , 0.037951 ], - [ 158.832697 , 161.228617 , 1.486039 ], - [ 164.984854 , 169.848150 , 2.863320 ], - [ 169.170571 , 175.507928 , 3.610867 ], - [ 172.872471 , 180.935750 , 4.456432 ], - [ 181.530751 , 183.039043 , 0.824028 ], - [ 180.340962 , 161.705481 , 11.524334 ], - [ 172.565436 , 139.273208 , 23.904259 ], - [ 162.247156 , 119.959075 , 35.252090 ], - [ 74.172585 , 47.566884 , 55.933243 ], - [ 100.626570 , 82.699087 , 21.677969 ], - [ 118.719023 , 107.658511 , 10.273700 ], - [ 132.735321 , 126.233454 , 5.150669 ], - [ 143.164628 , 140.576453 , 1.841116 ], - [ 151.813418 , 152.719787 , 0.593485 ], - [ 158.832697 , 162.995553 , 2.553969 ], - [ 164.984854 , 171.857872 , 3.999246 ], - [ 169.170571 , 177.664858 , 4.781073 ], - [ 172.872471 , 182.786539 , 5.423850 ], - [ 181.530751 , 184.309522 , 1.507666 ], - [ 180.340962 , 161.643543 , 11.567068 ], - [ 172.565436 , 139.231253 , 23.941595 ], - [ 162.247156 , 119.965390 , 35.244969 ], - [ 74.172585 , 43.226030 , 71.592407 ], - [ 100.626570 , 77.234542 , 30.287003 ], - [ 118.719023 , 103.998937 , 14.154074 ], - [ 132.735321 , 124.711169 , 6.434189 ], - [ 143.164628 , 139.489096 , 2.634995 ], - [ 151.813418 , 152.376815 , 0.369740 ], - [ 158.832697 , 162.771016 , 2.419546 ], - [ 164.984854 , 171.399588 , 3.742561 ], - [ 169.170571 , 176.519214 , 4.163084 ], - [ 172.872471 , 180.536313 , 4.245041 ], - [ 181.530751 , 180.178093 , 0.750734 ], - [ 180.340962 , 160.074815 , 12.660422 ], - [ 172.565436 , 138.305476 , 24.771224 ], - [ 162.247156 , 119.353334 , 35.938520 ], - [ 74.172585 , 43.304897 , 71.279901 ], - [ 100.626570 , 78.454597 , 28.260897 ], - [ 118.719023 , 105.606244 , 12.416671 ], - [ 132.735321 , 125.994568 , 5.350034 ], - [ 143.164628 , 141.582230 , 1.117653 ], - [ 151.813418 , 153.343235 , 0.997643 ], - [ 158.832697 , 162.893544 , 2.492946 ], - [ 164.984854 , 170.999163 , 3.517157 ], - [ 169.170571 , 175.833917 , 3.789568 ], - [ 172.872471 , 179.068771 , 3.460291 ], - [ 181.530751 , 176.723990 , 2.719926 ], - [ 180.340962 , 157.752190 , 14.319149 ], - [ 172.565436 , 137.392795 , 25.600062 ], - [ 162.247156 , 118.903128 , 36.453228 ], - [ 74.172585 , 43.462616 , 70.658354 ], - [ 100.626570 , 78.912756 , 27.516228 ], - [ 118.719023 , 106.612590 , 11.355539 ], - [ 132.735321 , 126.403955 , 5.008836 ], - [ 143.164628 , 142.375639 , 0.554160 ], - [ 151.813418 , 153.724089 , 1.242923 ], - [ 158.832697 , 162.443649 , 2.222895 ], - [ 164.984854 , 169.949698 , 2.921361 ], - [ 169.170571 , 173.598830 , 2.550858 ], - [ 172.872471 , 176.799304 , 2.221068 ], - [ 181.530751 , 173.447298 , 4.660467 ], - [ 180.340962 , 156.392633 , 15.312952 ], - [ 172.565436 , 136.374905 , 26.537530 ], - [ 162.247156 , 118.714142 , 36.670453 ], - [ 1403.330455 , 876.885316 , 60.035803 ], - [ 1901.397958 , 1587.638861 , 19.762624 ], - [ 2232.562804 , 2124.580533 , 5.082522 ], - [ 2471.970560 , 2509.129235 , 1.480939 ], - [ 2650.891041 , 2819.187942 , 5.969694 ], - [ 2785.299006 , 3044.948789 , 8.527230 ], - [ 2886.144180 , 3196.018358 , 9.695632 ], - [ 2960.257561 , 3339.851753 , 11.365600 ], - [ 3012.875689 , 3435.052610 , 12.290261 ], - [ 3047.821242 , 3482.652710 , 12.485640 ], - [ 3044.984927 , 3448.098035 , 11.690883 ], - [ 2877.611282 , 3105.329082 , 7.333129 ], - [ 2641.365086 , 2736.951332 , 3.492435 ], - [ 2382.949281 , 2378.093534 , 0.204187 ] -] //Swaption Calibration Result: foreach swaption [CalibPrice,BlackPrice,PercentDiff] - diff --git a/InterestCalib/HaskellLH/Makefile b/InterestCalib/HaskellLH/Makefile deleted file mode 100644 index 9519906..0000000 --- a/InterestCalib/HaskellLH/Makefile +++ /dev/null @@ -1,45 +0,0 @@ -# can be set using $>gmake GHC=/path/to/my/ghc -ifeq ($(strip $(GHC)),) - GHC=`which ghc` -endif - -# switch this on if llvm is enabled -#BACKEND=-fllvm - -OPTIMIZATION=-O2 -msse2 -rtsopts -EXECUTABLE=SwapCalib - -all: $(EXECUTABLE) - -$(EXECUTABLE): % : %.hs - $(GHC) $(OPTIMIZATION) --make $< -o $@ - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) - -# the Large dataset runs out of memory on the current Haskell implementation! -run_large: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) -# cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) - - -#------------------------------------------------------------------------- -# clean -#------------------------------------------------------------------------- -.PHONY : clean_executables clean_obj clean_source_backup -.SILENT : clean_executables clean_obj clean_source_backup - -clean: clean_executables clean_obj clean_source_backup - -clean_executables: - rm -f $(EXECUTABLE) - -clean_obj : - rm -f *.o *.hi - -clean_source_backup: - rm -f *~ - diff --git a/InterestCalib/OrigCpp/EvalGenomeOrig.h b/InterestCalib/OrigCpp/EvalGenomeOrig.h deleted file mode 100644 index efea067..0000000 --- a/InterestCalib/OrigCpp/EvalGenomeOrig.h +++ /dev/null @@ -1,155 +0,0 @@ -#ifndef EVAL_GENOME_INLINED -#define EVAL_GENOME_INLINED - -#include "Constants.h" -#include "GenAlgUtil.h" -#include "G2PP.h" -#include "G2PPorig.h" - - -/** - * MOST IMPORTANTLY: GENOME EVALUATION By Pricer of Swaption & BLACK PRICE - */ -void eval_genome_new ( - const REAL& a, - const REAL& b, - const REAL& rho, - const REAL& nu, - const REAL& sigma, - const REAL* swaption, - IntermElem* tmp_arrs, - REAL& new_quote, // output - REAL& new_price // output -) { - bool sanity = true; - - const REAL swap_freq = swaption[1]; - const REAL maturity = add_years( TODAY, swaption[0] ); - const UINT n_schedi = static_cast(12.0 * swaption[2] / swap_freq); - const REAL tmat0 = date_act_365( maturity, TODAY ); - - REAL strike; - { // BLACK PRICE computation - REAL lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; - - for(UINT i = 0; i < n_schedi; i++) { // reduce o map - // Map computes a1 and a2 (depends on i) - const REAL a1 = add_months( maturity, swap_freq*i ); - const REAL a2 = add_months( a1, swap_freq ); - - // Reduction( lvl: +, t0 : min, tn : max ) - lvl += zc(a2) * date_act_365(a2, a1); - t0 = std::min(t0, a1); - tn = std::max(tn, a2); - } - - strike = ( zc(t0) - zc(tn) ) / lvl; - const REAL d1 = 0.5 * swaption[3] * tmat0; - new_quote = lvl * strike * ( uGaussian_P(d1) - uGaussian_P(-d1) ); - } // END BLACK PRICE - - { // PRICER OF SWAPTION COMPUTATION - REAL v0_mat, dummy1, dummy2; - bigv( a, b, rho, nu, sigma, tmat0, v0_mat, dummy1, dummy2); -// - const REAL mux = - bigmx( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); - const REAL muy = - bigmy( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); -// - const REAL zc_mat = zc(maturity); -// - const REAL sqrt_bfun_a = sqrt( b_fun(2.0*a, tmat0) ); - const REAL sqrt_bfun_b = sqrt( b_fun(2.0*b, tmat0) ); - const REAL rhoxy = rho * b_fun(a+b, tmat0) / (sqrt_bfun_a * sqrt_bfun_b); - const REAL sigmax = sigma * sqrt_bfun_a; - const REAL sigmay = nu * sqrt_bfun_b; - - const REAL rhoxyc = 1.0 - rhoxy * rhoxy; // used in reduction kernel - const REAL rhoxycs = sqrt( rhoxyc ); // used in reduction kernel - const REAL sigmay_rhoxycs = sigmay * rhoxycs; - const REAL t4 = (rhoxy * sigmay) / sigmax; - - for( UINT i = 0; i < n_schedi; i++ ) { - const REAL beg_date = add_months( maturity, swap_freq*i ); //scheduleix[i]; - const REAL end_date = add_months( beg_date, swap_freq ); //scheduleiy[i]; - const REAL res = date_act_365( end_date, beg_date ) * strike; - - const REAL cii = ( i == n_schedi-1 ) ? 1.0 + res : res; - - REAL v0_end, vt_end, baii, bbii, date_tod1, date_tod2; - date_tod1 = date_act_365(end_date, TODAY); - bigv( a, b, rho, nu, sigma, date_tod1, v0_end, dummy1, dummy2 ); - date_tod2 = date_act_365(end_date, maturity); - bigv( a, b, rho, nu, sigma, date_tod2, vt_end, baii, bbii ); - - const REAL expo_aici = 0.5 * (vt_end - v0_end + v0_mat); - const REAL fact_aici = cii * zc(end_date) / zc_mat; - tmp_arrs[i].ci = fact_aici; // reuse the space to hold the factor of t1_cs - tmp_arrs[i].t1_cs = bbii * (mux * t4 - (muy - 0.5*rhoxyc*sigmay*sigmay*bbii) ) + expo_aici; - // hold only the exponent of the original t1_cs; - - tmp_arrs[i].bai = baii; - tmp_arrs[i].bbi = bbii; - tmp_arrs[i].aici = fact_aici * exp( expo_aici ); - tmp_arrs[i].log_aici = log( fact_aici ) + expo_aici; - tmp_arrs[i].scale = - ( baii + bbii * t4 ); - - sanity = ! ( isinf(tmp_arrs[i].aici) || isnan(tmp_arrs[i].aici) ); - assert(sanity && "Nan aici in pricer of swaption. Exiting!\n"); - } - - const REAL eps = 0.5 * sigmax; - - const REAL f = exactYhatOrig( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, - mux, muy, tmp_arrs, mux ); - - const REAL g = exactYhatOrig( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, - mux, muy, tmp_arrs, mux + eps ); - - const REAL h = exactYhatOrig( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, - mux, muy, tmp_arrs, mux - eps ); - - const REAL df = 0.5 * ( g - h ) / eps; - - const REAL sqrt2sigmax = sqrt(2.0) * sigmax;; - const REAL t2 = rhoxy / (sigmax*rhoxycs);; - - REAL accum = 0.0; - - for( UINT j = 0; j < NUM_HERMITE; j++ ) { - const REAL x_quad = HermiteCoeffs [j]; - const REAL w_quad = HermiteWeights[j]; - - const REAL x = sqrt2sigmax * x_quad + mux; - const REAL yhat_x = f + df*(x - mux); - const REAL h1 = ( (yhat_x - muy) / sigmay_rhoxycs ) - t2*( x - mux ); - - REAL accum1 = 0.0; - for( UINT i = 0; i < n_schedi; i++ ) { - const REAL h2 = h1 + tmp_arrs[i].bbi * sigmay_rhoxycs; - - const REAL expo_aici = tmp_arrs[i].t1_cs + tmp_arrs[i].scale*x; - const REAL fact_aici = tmp_arrs[i].ci; - const REAL expo_part = uGaussian_P_withExpFactor( -h2, expo_aici ); - accum1 += fact_aici * expo_part; - } - - sanity = ! ( isnan(accum1) || isinf(accum1) ); - assert(sanity && "Nan accum1 in pricer of swaption. Exiting!\n"); - - REAL tmp = sqrt(2.0) * x_quad; //(x - mux) / sigmax; - const REAL t1 = exp( - 0.5 * tmp * tmp ); - - accum += w_quad * t1 * ( uGaussian_P(-h1) - accum1 ); - } - - sanity = ! ( isnan(accum) || isinf(accum) ); - assert(sanity && "Nan accum1 in pricer of swaption. Exiting!\n"); - - new_price = zc_mat * ( accum / sqrt( PI ) ); - } -} - - - -#endif // end ifndef EVAL_GENOME_INLINED - diff --git a/InterestCalib/OrigCpp/GenAlgFlat.h b/InterestCalib/OrigCpp/GenAlgFlat.h deleted file mode 100644 index 3643bc3..0000000 --- a/InterestCalib/OrigCpp/GenAlgFlat.h +++ /dev/null @@ -1,281 +0,0 @@ -#ifndef GEN_ALG_FLAT -#define GEN_ALG_FLAT - -using namespace std; - -#include "Constants.h" -#include "GenAlgUtil.h" -#include "Genome.h" -#include "UtilCPU.h" -#include "EvalGenomeOrig.h" - - -/** - * Printing Swaption / Calibrated Price / Black Price / RMS - * The result is an array REAL[NUM_SWAP_QUOTES, 3] recording - * for each swaption the calibrated price, the black price - * and the percentagewise difference between the two. - */ -void makeSummary( const int winner, - const Genome& wgene, - const REAL* new_quote, - const REAL* new_price, - REAL* result // output -) { - REAL rms = 0.0; - - fprintf(stderr, "\n\nCALIBRATION RESULT: best genome is at index %d: ", winner); - fprintf(stderr, "{ a = %f, b = %f, sigma = %f, nu = %f, rho = %f }, Likelihood: %f!\n", - wgene.a, wgene.b, wgene.sigma, wgene.nu, wgene.rho, wgene.logLik ); - fprintf(stderr, "\nPer-Swaption Approximation w.r.t. Black Price:\n\n"); - - for( int i = 0; i < NUM_SWAP_QUOTES; i ++ ) { - REAL black_price = new_quote[i]; - REAL calib_price = new_price[i]; - REAL err_ratio = (calib_price - black_price) / black_price; - - result[3*i + 0] = 10000.0*calib_price; - result[3*i + 1] = 10000.0*black_price; - result[3*i + 2] = 100.0*fabs(err_ratio); - - rms += err_ratio * err_ratio; - - fprintf(stderr,"Swaption %d: {{%f, %f, %f},%f}, CalibratedPrice: %f, BlackPrice: %f, DiffPerc: %f\n", - i, SwaptionQuotes[4*i+0], SwaptionQuotes[4*i+1], SwaptionQuotes[4*i+2], SwaptionQuotes[4*i+3], - result[3*i + 0], result[3*i + 1], result[3*i + 2] ); - } - - rms = 100.0 * sqrt ( rms / NUM_SWAP_QUOTES ); - fprintf(stderr, "\n\n Best Genome RMS: %f\n\n", rms); -} - - -/** - * Utility function: find the genome with the best likelihood: - * scans the logLik array and fill in the index and likelihood - * of the best genome. - */ -void find_best(const Genome* genomes, int& best_ind, REAL& best_lik) { - bool sanity = true; - - best_lik = -INFINITY; - best_ind = 0; - - // this is in fact a reduction, but POP_SIZE is - // not big enough to warrant a parallel execution. - for ( UINT i = 0; i < POP_SIZE; i++ ) { // parallel reduction with MAX - REAL val = genomes[i].logLik; - - sanity = !( isnan(val) || isinf(val) ); - assert( sanity && "val is NaN in find_best" ); - - if( val > best_lik ) { best_ind = i; best_lik = val; } - } -} - -Move_Type selectMoveType(REAL move_selected) { - Move_Type move_type = NONE; - - REAL prob; - Move_Type type; - UINT k = 0; - do { - prob = mcmc_moves_selection_cumdensfct[k].fst; - type = mcmc_moves_selection_cumdensfct[k].snd; - - if( move_selected <= prob ) { - move_type = type; - } - k ++; - } while ( move_selected > prob && k < CUMDENSFCT_CARD ); - - assert(move_type != NONE && "MOVE_TYPE == NONE is ILLEGAL!"); - - return move_type; -} - -/** - * Main Entry Point for Swaption Calibration - * The (out) arguments are in fact the resulted - * winning genome result & its likelihood. - * The array result has size 3*NUM_SWAP_QUOTES - * and records for each swaption the calibrated - * price, the black price and the percentage - * difference between the two. - */ -REAL* mainKernelSeqCPU( Genome& winner ) { - - UINT n_schedi_max = 0; - for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { - const UINT n_schedi = static_cast(12.0 * SwaptionQuotes[4*ttt+2] / SwaptionQuotes[4*ttt+1]); - n_schedi_max = max(n_schedi_max, n_schedi); - } - - SeqArrays cpu_arrs(n_schedi_max); - Genome* genomes = cpu_arrs.genomes; - - srand ( SEED ); - srand48 ( SEED ); - - // initialized the genomes with random numbers inside - // their acceptable bounds => requires 5*POP_SIZE randoms - for( int i = 0; i < POP_SIZE; i++ ) { - REAL r01, tmp; - - r01 = getRandRandNorm(); - tmp = r01 * ( g_maxs[0] - g_mins[0]) + g_mins[0]; - genomes[i].a = genomes[i+POP_SIZE].a = tmp; - - r01 = getRandRandNorm(); - tmp = r01 * ( g_maxs[1] - g_mins[1]) + g_mins[1]; - genomes[i].b = genomes[i+POP_SIZE].b = tmp; - - r01 = getRandRandNorm(); - tmp = r01 * ( g_maxs[2] - g_mins[2]) + g_mins[2]; - genomes[i].rho = genomes[i+POP_SIZE].rho = tmp; - - r01 = getRandRandNorm(); - tmp = r01 * ( g_maxs[3] - g_mins[3]) + g_mins[3]; - genomes[i].nu = genomes[i+POP_SIZE].nu = tmp; - - r01 = getRandRandNorm(); - tmp = r01 * ( g_maxs[4] - g_mins[4]) + g_mins[4]; - genomes[i].sigma = genomes[i+POP_SIZE].sigma = tmp; - -// genomes[i].fbRat = genomes[i+POP_SIZE].fbRat = 1.0; - } - - // Initial evaluation of the genomes! - REAL quote, price; - for( int i = 0; i < POP_SIZE; i++ ) { - Genome& gene = genomes[i]; - REAL rms = 0.0; - for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { - eval_genome_new ( - gene.a, gene.b, gene.rho, gene.nu, gene.sigma, - SwaptionQuotes+4*ttt, cpu_arrs.tmp_arrs, quote, price - ); - rms += logLikelihood( quote, price ); - } - gene.logLik = rms; - } - - // convergence loop that runs the genetic algorithms - // (takes a population and returns a population) - for( int j = 0; j < MCMC_LOOPS; j++ ) { - - // select which move to perform. - // Note: this block can also be a loop (in fixed order) - // over the various move types - REAL move_selected = getRandUnifNorm(); - Move_Type move_type = selectMoveType(move_selected); - - if ( move_type == DIMS_ALL ) { - for( int i = 0; i < POP_SIZE; i++ ) { - genomes[i+POP_SIZE].mutate_dims_all( genomes[i] ); - } - - } else if ( move_type == DIMS_ONE ) { - - UINT dim_j = getRandIntNorm(GENOME_DIM); - - for( int i = 0; i < POP_SIZE; i++ ) { - genomes[i+POP_SIZE].mutate_dims_one( genomes[i], dim_j ); - } - } else /* if ( move_type == DEMCMC ) */ { - - for ( int i = 0; i < POP_SIZE; i++ ) { // parallel modulo random nums - // compute the k^th and the l^th genes - UINT cand_UB = POP_SIZE - 1; - UINT k = getRandIntNorm(cand_UB); // random in [0,pop_size-1) - if ( k == i ) { - k = cand_UB; - cand_UB -= 1; - } - UINT l = getRandIntNorm(cand_UB); - if ( l == i || l == k ) { - l = cand_UB; - } - - // do DEMCMC base on k^th and l^th genomes - genomes[i+POP_SIZE].mcmc_DE( genomes[i], genomes[k], genomes[l] ); - } - } - - // evaluate the proposals - for( int i = 0; i < POP_SIZE; i++ ) { - Genome& gene = genomes[i+POP_SIZE]; - - REAL rms = 0.0; - for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { - eval_genome_new ( - gene.a, gene.b, gene.rho, gene.nu, gene.sigma, - SwaptionQuotes+4*ttt, cpu_arrs.tmp_arrs, quote, price - ); - rms += logLikelihood( quote, price ); - } - gene.logLik = rms; - } - - // mcmc_acceptance_rejection(); - // Deciding whether to accept or reject the proposal, - // obtained by mutating/crossover of the individual. - for ( int i = 0; i < POP_SIZE; i++ ) { // parallel - // Metropolis: get a random U[0,1) for each candidate - REAL rand = getRandUnifNorm(); - - Genome& orig = genomes[i]; - Genome& muta = genomes[i+POP_SIZE]; - // selection: dimensions considered independent - // acceptance = min( 1, N.exp(c.logLik_proposal-c.logLik) * c.backward_forward_ratio ) - REAL acceptance = std::min( 1.0, exp( muta.logLik - orig.logLik ) * muta.fbRat ); - - // if acceptance criterion is met then p->p' else does nothing - if ( rand < acceptance ) - orig = muta; - } - - // print best candidate for the current iteration: - if ( (j % 16) == 0 ){ - int best_ind; REAL best_lik; - find_best(genomes, best_ind, best_lik); - fprintf(stderr, "\n Iteration: %d: Best Likelihood: %f, genome index: %d!\n", - j, best_lik, best_ind ); - } - } - - REAL* result = new REAL[3*NUM_SWAP_QUOTES]; - { // print best candidate for the current iteration: - int best_ind; REAL best_lik; - find_best(genomes, best_ind, best_lik); - //winner = genomes[best_ind]; - winner.a = genomes[best_ind].a; winner.b = genomes[best_ind].b; - winner.rho = genomes[best_ind].rho; winner.nu = genomes[best_ind].nu; - winner.sigma = genomes[best_ind].sigma; winner.logLik = genomes[best_ind].logLik; - - // recompute the calibrated price and the black price! - REAL* quotes = cpu_arrs.get_quote(); - REAL* prices = cpu_arrs.get_price(); - for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { - eval_genome_new ( - winner.a, winner.b, winner.rho, winner.nu, winner.sigma, - SwaptionQuotes+4*ttt, cpu_arrs.tmp_arrs, quote, price - ); - quotes[ttt] = quote; - prices[ttt] = price; - } - - - - // write summary - makeSummary( best_ind, winner, quotes, prices, result ); - } - - // Releasing the CPU resources: - cpu_arrs.releaseResources(); - - return result; -} - -#endif // end ifndef GEN_ALG_FLAT - diff --git a/InterestCalib/OrigCpp/Makefile b/InterestCalib/OrigCpp/Makefile deleted file mode 100644 index 0cac6e1..0000000 --- a/InterestCalib/OrigCpp/Makefile +++ /dev/null @@ -1,42 +0,0 @@ -include ../../setup.mk - -ifndef ($(HAVE_GPU)) -include ../../platform.mk -endif - -INCLUDES += -I../includeC -GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -#-fno-unsafe-math-optimizations -fno-finite-math-only -#-fmath-errno -ftrapping-math -fno-rounding-math -fsignaling-nans - -SOURCES_CPP =SwapCalib.cpp -HELPERS =../includeC/ParseInput.h -OBJECTS =SwapCalib.o -EXECUTABLE =SwapCalib - - -default: cpu - -.cpp.o: $(SOURCES_CPP) $(HELPERS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< - -# The GPU version is in: ../CppAndGPU. This folder is CPU only! -gpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) - -cpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) - - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: $(EXECUTABLE) - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - -clean: - rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) - diff --git a/InterestCalib/includeC/EvalGenomeInl.h b/InterestCalib/includeC/EvalGenomeInl.h deleted file mode 100644 index 6adc3d3..0000000 --- a/InterestCalib/includeC/EvalGenomeInl.h +++ /dev/null @@ -1,199 +0,0 @@ -#ifndef EVAL_GENOME_INLINED -#define EVAL_GENOME_INLINED - -#include "Constants.h" -#include "GenAlgUtil.h" -#include "G2PP.h" - - -/** - * MOST IMPORTANTLY: GENOME EVALUATION By Pricer of Swaption & BLACK PRICE - */ -REAL eval_genome( const REAL a, - const REAL b, - const REAL rho, - const REAL nu, - const REAL sigma, - - REAL* anew_quote, // [NUM_SWAP_QUOTES] - REAL* anew_price, // [NUM_SWAP_QUOTES] - - const int N, - short* flags, // [N] - - int * start_inds // [NUM_SWAP_QUOTES] -) { - REAL rms = 0.0; - bool sanity = true; - - // expand the irregular arrays - REAL *irreg_arrays = new REAL[8 * N]; - REAL *gbai, *gbbi, *gaici, *glog_aici, *gci, *gt1_cs, *gscale, *ghat_scale; - { // map intermediary arrays - REAL* ptr = irreg_arrays; - gbai = ptr; ptr += N; - gbbi = ptr; ptr += N; - gaici = ptr; ptr += N; - glog_aici = ptr; ptr += N; - gci = ptr; ptr += N; - gt1_cs = ptr; ptr += N; - gscale = ptr; ptr += N; - ghat_scale= ptr; ptr += N; - } - - // BIG KERNEL - for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { - const REAL mat_year = SwaptionQuotes[4*ttt + 0]; - const REAL swap_freq = SwaptionQuotes[4*ttt + 1]; - const REAL term_year = SwaptionQuotes[4*ttt + 2]; - const REAL quote = SwaptionQuotes[4*ttt + 3]; - - // adjust temporary array - const int beg_ind = start_inds[ttt]; - REAL *ci = gci + beg_ind, *bai = gbai + beg_ind, *bbi = gbbi + beg_ind, *aici = gaici + beg_ind; - REAL *log_aici = glog_aici + beg_ind, *t1_cs = gt1_cs + beg_ind, *scale = gscale + beg_ind; - REAL *hat_scale = ghat_scale + beg_ind; - - // new_quote does not have to be computed all the time, does it? - // it can just be computed once and indexed into an array ... - //const REAL new_quote = black_price ( TODAY, mat_year, swap_freq, term_year, quote ); - - const REAL maturity = add_years( TODAY, mat_year ); - const UINT n_schedi = static_cast(12.0 * term_year / swap_freq); - const REAL tmat0 = date_act_365( maturity, TODAY ); - - REAL strike; // new_quote, - { // BLACK PRICE computation - REAL lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; - - for(UINT i = 0; i < n_schedi; i++) { // reduce o map => in local memory - const REAL a1 = add_months( maturity, swap_freq*i ); - const REAL a2 = add_months( a1, swap_freq ); - - // Reduction( lvl: +, t0 : min, tn : max ) - lvl += zc(a2) * date_act_365(a2, a1); - t0 = std::min(t0, a1); - tn = std::max(tn, a2); - } - - strike = ( zc(t0) - zc(tn) ) / lvl; - const REAL d1 = 0.5 * quote * tmat0; - anew_quote[ttt] = lvl * strike * ( uGaussian_P(d1) - uGaussian_P(-d1) ); - } // END BLACK PRICE - - - //const REAL new_price = pricer_of_swaption( TODAY, mat_year, swap_freq, term_year, g_a, g_b, g_rho, g_nu, g_sigma); - //REAL new_price; - { // PRICER OF SWAPTION COMPUTATION - REAL v0_mat, dummy1, dummy2; - bigv( a, b, rho, nu, sigma, tmat0, v0_mat, dummy1, dummy2); -// - const REAL mux = - bigmx( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); - const REAL muy = - bigmy( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); -// - const REAL zc_mat = zc(maturity); -// - const REAL sqrt_bfun_a = sqrt( b_fun(2.0*a, tmat0) ); - const REAL sqrt_bfun_b = sqrt( b_fun(2.0*b, tmat0) ); - const REAL rhoxy = rho * b_fun(a+b, tmat0) / (sqrt_bfun_a * sqrt_bfun_b); - const REAL sigmax = sigma * sqrt_bfun_a; - const REAL sigmay = nu * sqrt_bfun_b; - - const REAL rhoxyc = 1.0 - rhoxy * rhoxy; // used in reduction kernel - const REAL rhoxycs = sqrt( rhoxyc ); // used in reduction kernel - const REAL sigmay_rhoxycs = sigmay * rhoxycs; - const REAL t4 = (rhoxy * sigmay) / sigmax; -// - - for( UINT i = 0; i < n_schedi; i++ ) { - const REAL beg_date = add_months( maturity, swap_freq*i ); //scheduleix[i]; - const REAL end_date = add_months( beg_date, swap_freq ); //scheduleiy[i]; - const REAL res = date_act_365( end_date, beg_date ) * strike; - - const REAL cii = ( i == n_schedi-1 ) ? 1.0 + res : res; - - REAL v0_end, vt_end, baii, bbii, date_tod1, date_tod2; - date_tod1 = date_act_365(end_date, TODAY); - bigv( a, b, rho, nu, sigma, date_tod1, v0_end, dummy1, dummy2 ); - date_tod2 = date_act_365(end_date, maturity); - bigv( a, b, rho, nu, sigma, date_tod2, vt_end, baii, bbii ); - - const REAL expo_aici = 0.5 * (vt_end - v0_end + v0_mat); - const REAL fact_aici = cii * zc(end_date) / zc_mat; - ci [i] = fact_aici; // reuse the space to hold the factor of t1_cs - t1_cs [i] = bbii * (mux * t4 - (muy - 0.5*rhoxyc*sigmay*sigmay*bbii) ) + expo_aici; - // hold only the exponent of the original t1_cs; - - bai [i] = baii; - bbi [i] = bbii; - aici [i] = fact_aici * exp( expo_aici ); - log_aici[i] = log( fact_aici ) + expo_aici; - scale [i] = - ( baii + bbii * t4 ); - - sanity = ! ( isinf(aici[i]) || isnan(aici[i]) ); - assert(sanity && "Nan aici in pricer of swaption. Exiting!\n"); - } -// - const REAL eps = 0.5 * sigmax; - - const REAL f = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, - mux, muy, bai, bbi, aici, log_aici, hat_scale, mux ); - const REAL g = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, - mux, muy, bai, bbi, aici, log_aici, hat_scale, mux + eps ); - const REAL h = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, - mux, muy, bai, bbi, aici, log_aici, hat_scale, mux - eps ); - const REAL df = 0.5 * ( g - h ) / eps; - - const REAL sqrt2sigmax = sqrt(2.0) * sigmax;; - const REAL t2 = rhoxy / (sigmax*rhoxycs);; - - REAL accum = 0.0; - - for( UINT j = 0; j < NUM_HERMITE; j++ ) { - const REAL x_quad = HermiteCoeffs [j]; - const REAL w_quad = HermiteWeights[j]; - - const REAL x = sqrt2sigmax * x_quad + mux; - const REAL yhat_x = f + df*(x - mux); - const REAL h1 = ( (yhat_x - muy) / sigmay_rhoxycs ) - t2*( x - mux ); - - REAL accum1 = 0.0; - for( UINT i = 0; i < n_schedi; i++ ) { - const REAL h2 = h1 + bbi[i] * sigmay_rhoxycs; - - const REAL expo_aici = t1_cs[i] + scale[i]*x; - const REAL fact_aici = ci[i]; - // accum1 += fact_aici * exp(expo_aici) * uGaussian_P(-h2); - const REAL expo_part = uGaussian_P_withExpFactor( -h2, expo_aici ); - accum1 += fact_aici * expo_part; - } - - sanity = ! ( isnan(accum1) || isinf(accum1) ); - assert(sanity && "Nan accum1 in pricer of swaption. Exiting!\n"); - - REAL tmp = sqrt(2.0) * x_quad; //(x - mux) / sigmax; - const REAL t1 = exp( - 0.5 * tmp * tmp ); - - accum += w_quad * t1 * ( uGaussian_P(-h1) - accum1 ); - } - - sanity = ! ( isnan(accum) || isinf(accum) ); - assert(sanity && "Nan accum1 in pricer of swaption. Exiting!\n"); - - anew_price[ttt] = zc_mat * ( accum / sqrt( PI ) ); - -// const REAL tmp = (anew_price[ttt] - anew_quote[ttt]) / anew_quote[ttt]; -// rms += tmp * tmp; - const REAL lik = logLikelihood( anew_quote[ttt], anew_price[ttt] ); - rms += lik; - } - } - - delete[] irreg_arrays; - - return rms; -// return 0.0-rms; -} - -#endif // end ifndef EVAL_GENOME_INLINED - diff --git a/InterestCalib/includeC/ParseInput.h b/InterestCalib/includeC/ParseInput.h deleted file mode 100644 index 042725c..0000000 --- a/InterestCalib/includeC/ParseInput.h +++ /dev/null @@ -1,199 +0,0 @@ -#ifndef PARSE_INPUT -#define PARSE_INPUT - -#include "ParserC.h" -#include -#include -#include -#include "GenAlgUtil.h" - -//using namespace std; - -#if WITH_FLOAT - #define read_real read_float -#else - #define read_real read_double -#endif - -/***********************************/ -/********** READ DATA SET **********/ -/***********************************/ - -void readDataSet( UINT& pop_size, - UINT& num_conv_iters, - UINT& num_swap_quotes, - REAL*& swaption_quotes, // [num_swap_quotes,4] - - UINT& num_hermitians, - REAL*& hermite_coefs, // [num_hermite] - REAL*& hermite_weights, // [num_hermite] - - UINT& num_sobol_bits, - int*& sobol_dirs_vct // [num_sobol_bits] -) { - int64_t shape[3]; - bool atr_ok = true; - - if ( read_int( static_cast( &pop_size ) ) || - read_int( static_cast( &num_conv_iters ) ) ) { - fprintf(stderr, "Syntax error when reading population size or convergence-loop count!\n"); - exit(1); - } - atr_ok = (pop_size >= 64) && (num_conv_iters >= 100); - assert(atr_ok && "Population size < 64 OR convergence-loop count < 100!\n"); - - { // swaption quotes - if ( read_int( static_cast( &num_swap_quotes ) ) ) { - fprintf(stderr, "Syntax error when reading NUM_SWAP_QUOTES.\n"); - exit(1); - } - atr_ok = num_swap_quotes > 0; - assert(atr_ok && "Number of swaptions LESS or equal to ZERO!\n"); - - if ( read_array(sizeof(REAL), read_real, (void**)&swaption_quotes, shape, 2) ) { - fprintf(stderr, "Syntax error when reading the swaption quotes.\n"); - exit(1); - } - atr_ok = ( shape[1] == 4 && shape[0] == num_swap_quotes ); - assert(atr_ok && "Incorrect shape of the swaption quotes!"); - } - - { // hermitean coefficients - if ( read_int( static_cast( &num_hermitians ) ) ) { - fprintf(stderr, "Syntax error when reading number of hermitians.\n"); - exit(1); - } - atr_ok = num_hermitians > 0; - assert(atr_ok && "Number of hermitians LESS or equal to ZERO!\n"); - - if ( read_array(sizeof(REAL), read_real, (void**)&hermite_coefs, shape, 1) ) { - fprintf(stderr, "Syntax error when reading the hermitian coeficients.\n"); - exit(1); - } - atr_ok = ( shape[0] == num_hermitians ); - assert(atr_ok && "Incorrect shape of the hermitian coefficients!"); - - if ( read_array(sizeof(REAL), read_real, (void**)&hermite_weights, shape, 1) ) { - fprintf(stderr, "Syntax error when reading the hermitian weights.\n"); - exit(1); - } - atr_ok = ( shape[0] == num_hermitians ); - assert(atr_ok && "Incorrect shape of the hermitian weights!"); - } - - { // sobol direction vectors! - if ( read_int( static_cast( &num_sobol_bits ) ) ) { - fprintf(stderr, "Syntax error when reading NUM_SOBOL_BITS.\n"); - exit(1); - } - atr_ok = num_sobol_bits > 0; - assert(atr_ok && "Number of sobol bits LESS or equal to ZERO!\n"); - - if ( read_array(sizeof(int), read_int, (void**)&sobol_dirs_vct, shape, 1) ) { - fprintf(stderr, "Syntax error when reading sobol direction vectors.\n"); - exit(1); - } - atr_ok = ( shape[0] == num_sobol_bits ); - assert( atr_ok && "Incorrect shape of sobol direction vectors!" ); - } -} - -REAL* readOutput( const int& N, REAL& ref_logLik ) { - REAL* result; - int64_t shape[3]; - - REAL ref_a, ref_b, ref_sigma, ref_nu, ref_rho; - - // reading the reference genome! - if( read_real( &ref_a ) || read_real( &ref_b ) || - read_real( &ref_sigma ) || read_real( &ref_nu ) || - read_real( &ref_rho ) || read_real( &ref_logLik ) ) { - fprintf(stderr, "Syntax error when reading the reference genome or its likelihood.\n"); - exit(1); - } - - // reading the standard output - if ( read_array(sizeof(REAL), read_real, (void**)&result, shape, 2) ) { - fprintf(stderr, "Syntax error when reading the output.\n"); - exit(1); - } - bool ok = ( shape[0] == N ) && ( shape[1] == 3 ); - assert(ok && "Incorrect shape of the reference array result!"); - - return result; -} - -bool validate( const REAL& logLik, const REAL* res, const int& N ) { - bool is_valid = true; - - REAL ref_logLik; - REAL* ref_res = readOutput( N, ref_logLik ); - - if( fabs(ref_logLik - logLik) > 1.0 ) { - is_valid = false; - fprintf(stderr, "Difference in logLikelihood > 1.0: result logLik %f, reference logLik = %f!\n", - logLik, ref_logLik ); - return is_valid; - } else if ( logLik < ref_logLik && fabs(ref_logLik - logLik) > 0.5 ) { - is_valid = false; - fprintf(stderr, "Result likelihood is worse than reference with more than 0.5: result logLik %f, reference logLik = %f!\n", - logLik, ref_logLik ); - return is_valid; - } - - for ( int i = 0; i < N; i ++ ) { - REAL lgLik_cur = logLikelihood( res[3*i+1], res[3*i]); - REAL lgLik_ref = logLikelihood(ref_res[3*i+1],ref_res[3*i]); - REAL diff_curr_lgLik = (lgLik_cur > lgLik_ref) ? - 0.0 : lgLik_ref - lgLik_cur ; - - if (diff_curr_lgLik > 0.7) { - is_valid = false; - fprintf(stderr, "Error[%d] = %f, Acceptable = 1.1!\n", - i, diff_curr_lgLik ); - break; - } - } - - return is_valid; -} - -void writeStatsAndResult( const bool& valid, - const REAL& wg_a, - const REAL& wg_b, - const REAL& wg_sigma, - const REAL& wg_nu, - const REAL& wg_rho, - const REAL& wg_logLik, - const REAL* calib_arr, - const int & NUM_SWAP_QUOTES, - const bool& is_gpu, - const int & P, - const unsigned long int& elapsed -) { - // print stats to stdout - fprintf(stdout, "// Dataset with Number of Swaption Quotes = %d.\n", - NUM_SWAP_QUOTES ); - - if(valid) { fprintf(stdout, "1\t\t// VALID Result,\n"); } - else { fprintf(stdout, "0\t\t// INVALID Result,\n"); } - - fprintf(stdout, "%ld\t\t// Runtime in microseconds,\n", elapsed); - if(is_gpu) fprintf(stdout, "%d\t\t// GPU Threads,\n\n", P); - else fprintf(stdout, "%d\t\t// CPU Threads,\n\n", P); - - // write the genome - write_scal(&wg_a, "a-field of the winning genome"); - write_scal(&wg_b, "b-field of the winning genome"); - write_scal(&wg_sigma, "sigma-field of the winning genome"); - write_scal(&wg_nu, "nu-field of the winning genome"); - write_scal(&wg_rho, "rho-field of the winning genome"); - write_scal(&wg_logLik,"LgLikelihood of the winning genome"); - - // write the result - write_2Darr( calib_arr, static_cast(NUM_SWAP_QUOTES), 3, - "Swaption Calibration Result: foreach swaption [CalibPrice,BlackPrice,PercentDiff]" ); -} - -#endif // PARSE_INPUT - diff --git a/InterestCalib/includeC/tmp/Constants.h b/InterestCalib/includeC/tmp/Constants.h deleted file mode 100644 index 8fd8365..0000000 --- a/InterestCalib/includeC/tmp/Constants.h +++ /dev/null @@ -1,42 +0,0 @@ -#ifndef CONSTANTS_H -#define CONSTANTS_H - -#define WITH_FLOATS 1 - -#define REAL3_CT 4 -#define TRANSPOSE_UV 1 - -#if (WITH_FLOATS) - typedef float REAL; - typedef unsigned int ULONG; -#else - #pragma OPENCL EXTENSION cl_khr_fp64: enable - typedef double REAL; - typedef unsigned long ULONG; -#endif - -#define WARP (1< 1 - phi(h_i(x, yhat)) < EPS - else if ( yu <= y0 ) res = y0 - 1.0; // yhat is lower than y0 => phi(h_i(x, yhat)) < EPS) - else { - const REAL root_lb = std::max( yl, y0 ); - const REAL root_ub = std::min( yu, y1 ); - - REAL root, error; UINT iter; - rootFinding_Brent(1, n_schedi, scales, bbi, root_lb, root_ub, 1.0e-4, 1000, root, iter, error); - //rootBisection(1, n_schedi, scales, bbi, root_lb, root_ub, 1.0e-4, 1000, root, iter, error); - - res = ( error == -INFTY ) ? y0 - 1.0 : ( error == INFTY ) ? y1 + 1.0 : root; - } - - return res; -} - - - -/////////////////////////////////////////////////////////// -/////////////////////////////////////////////////////////// -/// Main function of Module G2PP: pricer_of_swaption /// -/////////////////////////////////////////////////////////// -/////////////////////////////////////////////////////////// - -REAL pricer_of_swaption( const REAL& today, - - const REAL& sw_mat, // swaptionQuote begins ... - const REAL& sw_freq, - const REAL& sw_ty, // swaptionQuote ends. - - const REAL& a, // genome begins ... - const REAL& b, - const REAL& rho, - const REAL& nu, - const REAL& sigma // genome ends. -) { - //SwapOfSwap sos = extended_swaption_of_swaption(sw_mat, sw_freq, sw_ty); - const REAL maturity = add_years( TODAY, sw_mat ); - const UINT n_schedi = static_cast(12.0 * sw_ty / sw_freq); -// - const REAL tmat0 = date_act_365( maturity, today ); // BIG BUG -- was TODAY - REAL v0_mat, dummy1, dummy2; - bigv( a, b, rho, nu, sigma, tmat0, v0_mat, dummy1, dummy2); -// - const REAL mux = - bigmx( a, b, rho, nu, sigma, today, maturity, today, maturity ); - const REAL muy = - bigmy( a, b, rho, nu, sigma, today, maturity, today, maturity ); -// - const REAL zc_mat = zc(maturity); -// - const REAL sqrt_bfun_a = sqrt( b_fun(2.0*a, tmat0) ); - const REAL sqrt_bfun_b = sqrt( b_fun(2.0*b, tmat0) ); - const REAL rhoxy = rho * b_fun(a+b, tmat0) / (sqrt_bfun_a * sqrt_bfun_b); - const REAL sigmax = sigma * sqrt_bfun_a; - const REAL sigmay = nu * sqrt_bfun_b; - - const REAL rhoxyc = 1.0 - rhoxy * rhoxy; // used in reduction kernel - const REAL rhoxycs = sqrt( rhoxyc ); // used in reduction kernel - const REAL sigmay_rhoxycs = sigmay * rhoxycs; - const REAL t4 = (rhoxy * sigmay) / sigmax; -// - REAL lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; - for( UINT i = 0; i < n_schedi; i++ ) { - REAL a1 = add_months( maturity, sw_freq*i ); - //sos.swap_sched1[i] = a1; - REAL a2 = add_months( a1, sw_freq ); - //sos.swap_sched2[i] = a2; - - // Reduction( lvl: +, t0 : min, tn : max ) - lvl += zc(a2) * date_act_365(a2, a1); - t0 = std::min(t0, a1); - tn = std::max(tn, a2); - } - - const REAL strike = ( zc(t0) - zc(tn) ) / lvl; -// - REAL* ci = new REAL[n_schedi]; - REAL* bai = new REAL[n_schedi]; - REAL* bbi = new REAL[n_schedi]; - REAL* aici = new REAL[n_schedi]; - REAL* log_aici = new REAL[n_schedi]; - REAL* t1_cs = new REAL[n_schedi]; - REAL* scale = new REAL[n_schedi]; - REAL* hat_scale= new REAL[n_schedi]; - - for( UINT i = 0; i < n_schedi; i++ ) { - const REAL beg_date = add_months( maturity, sw_freq*i ); //scheduleix[i]; - const REAL end_date = add_months( beg_date, sw_freq ); //scheduleiy[i]; - const REAL res = date_act_365( end_date, beg_date ) * strike; - - const REAL cii = ( i == n_schedi-1 ) ? 1.0 + res : res; - - REAL v0_end, vt_end, baii, bbii, date_tod1, date_tod2; - date_tod1 = date_act_365(end_date, today); - bigv( a, b, rho, nu, sigma, date_tod1, v0_end, dummy1, dummy2 ); - date_tod2 = date_act_365(end_date, maturity); - bigv( a, b, rho, nu, sigma, date_tod2, vt_end, baii, bbii ); - - const REAL expo_aici = 0.5 * (vt_end - v0_end + v0_mat); - const REAL fact_aici = cii * zc(end_date) / zc_mat; - ci [i] = fact_aici; // reuse the space to hold the factor of t1_cs - t1_cs [i] = bbii * (mux * t4 - (muy - 0.5*rhoxyc*sigmay*sigmay*bbii) ) + expo_aici; // hold only the exponent of the original t1_cs; - - bai [i] = baii; - bbi [i] = bbii; - aici [i] = fact_aici * exp( expo_aici ); - log_aici[i] = log( fact_aici ) + expo_aici; - scale [i] = - ( baii + bbii * t4 ); - - if( isinf(aici[i]) || isnan(aici[i]) ) { - printf("NaN aici in pricer of swaption. Exiting!\n"); exit(0); - } - } -// - - const REAL eps = 0.5 * sigmax; - - const REAL f = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, mux, muy, bai, bbi, aici, log_aici, hat_scale, mux ); - const REAL g = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, mux, muy, bai, bbi, aici, log_aici, hat_scale, mux + eps ); - const REAL h = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, mux, muy, bai, bbi, aici, log_aici, hat_scale, mux - eps ); - const REAL df = 0.5 * ( g - h ) / eps; - - // AT this point we need: - // scalars: sqrt2sigmax, t2, f, df, mux, muy, sigmay_rhoxycs, zc_mat - // arrays : t1_cs, bbi, scale, ci - - const REAL sqrt2sigmax = sqrt(2.0) * sigmax; - const REAL t2 = rhoxy / (sigmax*rhoxycs); - // t2 * (sqrt2sigmax * x_quad) -> sqrt(2.0) * rhoxy / rhoxycs * xquad - - REAL accum0 = 0.0; - for( UINT j = 0; j < Gauss_DIM; j++ ) { - const REAL x_quad = GaussHermiteCoefs::coefs [j]; - const REAL w_quad = GaussHermiteCoefs::weights[j]; - - const REAL x = sqrt2sigmax * x_quad + mux; - - const REAL yhat_x = f + df*(x - mux); - const REAL h1 = ( (yhat_x - muy) / sigmay_rhoxycs ) - t2*( x - mux ); - - REAL accum1 = 0.0; - for( UINT i = 0; i < n_schedi; i++ ) { - const REAL h2 = h1 + bbi[i] * sigmay_rhoxycs; - - const REAL expo_aici = t1_cs[i] + scale[i]*x; - const REAL fact_aici = ci[i]; -// accum1 += fact_aici * exp(expo_aici) * uGaussian_P(-h2); - const REAL expo_part = uGaussian_P_withExpFactor( -h2, expo_aici ); - accum1 += fact_aici * expo_part; - - if( isnan(accum1) || isinf(accum1) ) { - printf( "accum is Nan -- expo_aici: %f, fact_aici: %f, h2: %f, t1_cs: %f, scale: %f, x: %f, bbi: %f, mux: %f, muy: %f\n", - expo_aici, fact_aici, h2, t1_cs[i], scale[i], x, bbi[i], mux, muy ); - printf( "accum is Nan -- t4: %f, rhoxyc: %f, v0mat: %f, b: %f, aici: %f\n", - t4, rhoxyc, v0_mat, b, aici[i] ); - exit(0); - } - } - - REAL tmp = sqrt(2.0) * x_quad; //(x - mux) / sigmax; - const REAL t1 = exp( - 0.5 * tmp * tmp ); - - accum0 += w_quad * t1 * ( uGaussian_P(-h1) - accum1 ); - } - - if( isnan(accum0) || isinf(accum0) ) { - printf("Numerically Instable Implem: end of pricer_of_swaption: accum0 in NaN or Inf!\n"); - exit(0); - } - - delete[] ci; delete[] hat_scale; - delete[] bai; delete[] aici; delete[] log_aici; - delete[] bbi; delete[] t1_cs; delete[] scale; - - return zc_mat * ( accum0 / sqrt( PI ) ); -} - - -//////////////////////////////// -//// Pricer for one genome: //// -//////////////////////////////// - -REAL pricer (const REAL a = 0.02453, const REAL b = 0.98376, const REAL rho = -0.82400, const REAL nu = 0.11830, const REAL sigma = 0.02398) { - //let genome = {0.02453, 0.98376, ~0.82400, 0.11830, 0.02398} in - - REAL rms = 0.0, logLik = 0.0; - for( UINT i = 0; i < NUM_SWAP_QUOTES; i++ ) { - const REAL mat_year = SwaptionQuotes[i][0]; - const REAL swap_freq = SwaptionQuotes[i][1]; - const REAL term_year = SwaptionQuotes[i][2]; - const REAL quote = SwaptionQuotes[i][3]; - - const REAL g2pp_price = pricer_of_swaption( TODAY, mat_year, swap_freq, term_year, a, b, rho, nu, sigma); - const REAL market_price = black_price ( TODAY, mat_year, swap_freq, term_year, quote ); - - const REAL tmp = (g2pp_price - market_price) / market_price; - rms += tmp * tmp; - logLik += logLikelihood( market_price, g2pp_price ); - } - - rms = 100.0 * sqrt ( rms / NUM_SWAP_QUOTES ); - - printf("\n\n!!!!!!!!!!!!!Computed RMS is: %f, Computed LogLik is: %f\n\n", rms, logLik); - - return rms; -} - - -////////////////////////////////////////////////////// -//// Test pricer_of_swaption: -//// -//// params=params2dict(a = 0.02453, b = 0.98376, sigma = 0.02398, nu = 0.11830, rho = -0.82400) -//// swaption=['swaption_maturity_in_year': 10, 'swap_term_in_year': 4, 'swap_frequency': 6] -//// assert "%.3f" % (1e4*pricer_of_swaption(today=today,zc=zc,swaption=swaption,params=params)) == "657.822" -//// swaption=['swaption_maturity_in_year': 30, 'swap_term_in_year': 30, 'swap_frequency': 6] -//// assert "%.3f" % (1e4*pricer_of_swaption(today=today,zc=zc,swaption=swaption,params=params)) == "1902.976" -//// -////////////////////////////////////////////////////// - - -void test_pricer_of_swaption() { - const REAL a = 0.02453; - const REAL b = 0.98376; - const REAL rho = -0.82400; - const REAL nu = 0.11830; - const REAL sigma = 0.02398; - - // (maturity, frequency, term) = swaption - REAL maturity = 10.0; - REAL freq = 6.0; - REAL term = 4.0; - - const REAL price1 = 1.0e4 * pricer_of_swaption( TODAY, maturity, freq, term, a, b, rho, nu, sigma); - printf("Pricer_of_swaption test I = 657.82158867845 : "); - if( equalEps(price1, 657.82158867845) ) printf(" SUCCESS!\n\n"); - else printf("%f FAILS!\n\n", price1); - - // let swaption = {30.0, 6.0, 30.0} - maturity = 30.0; - freq = 6.0; - term = 30.0; - - const REAL price2 = 1.0e4 * pricer_of_swaption( TODAY, maturity, freq, term, a, b, rho, nu, sigma ); - printf("Pricer_of_swaption test II = 1902.97628191498 : "); - if( equalEps(price2, 1902.97628191498) ) printf(" SUCCESS!\n\n"); - else printf("%f FAILS!\n\n", price2); - - - //let swaption = {30.0, 6.0, 25.0} in - maturity = 30.0; - freq = 6.0; - term = 25.0; - - const REAL price3 = 1.0e4 * pricer_of_swaption( TODAY, maturity, freq, term, a, b, rho, nu, sigma ); - printf("Pricer_of_swaption test III = 1840.859126408099 : "); - if( equalEps(price3, 1840.859126408099) ) printf(" SUCCESS!\n\n"); - else printf("%f FAILS!\n\n", price3); -} - -#endif // ifndef G2PP diff --git a/LocVolCalib/AllParOpenCLMP/Makefile b/LocVolCalib/AllParOpenCLMP/Makefile deleted file mode 100644 index 4ac70f6..0000000 --- a/LocVolCalib/AllParOpenCLMP/Makefile +++ /dev/null @@ -1,54 +0,0 @@ -MAKE_DIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) - -include ../../setup.mk - -ifndef ($(HAVE_GPU)) -include ../../platform.mk -endif - -INCLUDES += -I../includeC -GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -D GPU_DEV_ID=$(GPU_DEVICE_ID) \ - -D GPU_LOC_MEM=$(GPU_LOCAL_MEM) -D GPU_CONST_MEM=$(GPU_CONST_MEM) \ - -D GPU_REG_MEM=$(GPU_REG_MEM) -D GPU_GLB_MEM=$(GPU_DEVICE_MEM) \ - -D GPU_TILE=$(GPU_LOCAL_MEM_PER_TH) -D GPU_CORES=$(GPU_NUM_CORES) \ - -D CURR_DIR_PATH='"$(MAKE_DIR)"' - -SOURCES_CPP =VolCalibAll.cpp -HELPERS =PrepareKernels.h Vect_CPU.h Vect_GPU.h VolCalibInit.h ../includeC/Constants.h \ - ../includeC/ParseInput.h ../includeC/DataStructConst.h ../includeC/ParPrefixUtil.h -OBJECTS =VolCalibAll.o -EXECUTABLE =VolCalib - -ifeq ($(HAVE_GPU),1) -default: gpu -else -# cannot build this one... -no-gpu: - @echo "\n*** No GPU configured, cannot build `pwd` ***\n" -endif - -#.cpp.o: $(SOURCES_CPP) $(HELPERS) -# $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< - -#$(OBJECTS) -cpu: - $(CXX) $(CXXFLAGS) -D IS_GPU=0 $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(SOURCES_CPP) $(LIB) - -gpu: - $(CXX) $(CXXFLAGS) -D IS_GPU=1 $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(SOURCES_CPP) $(LIB) - - -run_small: - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - -clean: - rm -f $(EXECUTABLE) $(OBJECTS) ./*.ptx ./Debug.txt - @# clean nVidia compiler cache - rm -rf $(HOME)/.nv/ComputeCache/* - diff --git a/LocVolCalib/COpenMP/Makefile b/LocVolCalib/COpenMP/Makefile deleted file mode 100644 index 88daa45..0000000 --- a/LocVolCalib/COpenMP/Makefile +++ /dev/null @@ -1,39 +0,0 @@ -include ../../setup.mk - -ifndef ($(HAVE_GPU)) -include ../../platform.mk -endif - -INCLUDES += -I../includeC -GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) - -SOURCES_CPP =VolCalibOrig.cpp -HELPERS =../includeC/ParseInput.h -OBJECTS =VolCalibOrig.o -EXECUTABLE =VolCalib - - -default: cpu - -.cpp.o: $(SOURCES_CPP) $(HELPERS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< - -# The GPU version is in: ../VectAll and ../VectOuters. This folder is CPU only! - -cpu: $(EXECUTABLE) -$(EXECUTABLE): $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) - - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: $(EXECUTABLE) - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - -clean: - rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) - diff --git a/LocVolCalib/COpenMP/VolCalibOrig.cpp b/LocVolCalib/COpenMP/VolCalibOrig.cpp deleted file mode 100644 index 293c5e1..0000000 --- a/LocVolCalib/COpenMP/VolCalibOrig.cpp +++ /dev/null @@ -1,445 +0,0 @@ -#include - -#define WITH_FLOATS 0 -#define WORKGROUP_SIZE 512 - -typedef double REAL; - -#include "Util.h" -#include "../includeC/ParseInput.h" - -using namespace std; - - -// Macros for 2-dim array indexing -#define Dx(i,j) Dx[(i)*3 + j] -#define Dy(i,j) Dy[(i)*3 + j] -#define Dxx(i,j) Dxx[(i)*3 + j] -#define Dyy(i,j) Dyy[(i)*3 + j] -#define MuX(i,j) MuX[(i)*numX + j] -#define VarX(i,j) VarX[(i)*numX + j] -#define MuY(i,j) MuY[(i)*numY + j] -#define VarY(i,j) VarY[(i)*numY + j] -#define ResultE(i,j) ResultE[(i)*numY + j] - -#define U(i,j) U[(i)*numX + j] -#define V(i,j) V[(i)*numY + j] - -/***********************************/ - -/** - * Initializes MuX, MuY, VarX and VarY - */ -inline -void updateParams( const unsigned numX, - const unsigned numY, - const unsigned g, - const REAL alpha, - const REAL beta, - const REAL nu, - REAL* X, REAL* Y, REAL* Time, - - REAL* MuX, REAL* VarX, // output - REAL* MuY, REAL* VarY // output -) { - - for(unsigned j=0; j(s0/dx); - - for(unsigned i=0; i(numY/2); - - for(unsigned i=0; i=0; i--) { - y[i] = (y[i] - c[i]*y[i+1]) / b[i]; - } -} - -void -rollback( const unsigned numX, - const unsigned numY, - const unsigned g, - REAL* a, REAL* b, REAL* c, REAL* Time, REAL* U, REAL* V, - REAL* Dx, REAL* Dxx, REAL* MuX, REAL* VarX, - REAL* Dy, REAL* Dyy, REAL* MuY, REAL* VarY, - - REAL* ResultE // output -) { - const REAL dtInv = 1.0 / (Time[g+1]-Time[g]); - int i, j; - - // explicit x - for(j=0; j=0; --i ) { - updateParams( numX, numY, i, alpha, beta, nu, - X, Y, Time, MuX, VarX, MuY, VarY ); - - rollback( numX, numY, i, - a, b, c, Time, U, V, - Dx, Dxx, MuX, VarX, - Dy, Dyy, MuY, VarY, - ResultE - ); - } - - REAL res = ResultE(indX,indY); - - return res; -} - -void run_CPUkernel( - const unsigned& outer, - const unsigned& numX, - const unsigned& numY, - const unsigned& numT, - const REAL& s0, - const REAL& t, - const REAL& alpha, - const REAL& nu, - const REAL& beta, - const unsigned& P, - REAL* a, REAL* b, REAL* c, REAL* Time, REAL* U, REAL* V, - REAL* X, REAL* Dx, REAL* Dxx, REAL* MuX, REAL* VarX, - REAL* Y, REAL* Dy, REAL* Dyy, REAL* MuY, REAL* VarY, - REAL* ResultE, - - REAL* result // output -) { - const unsigned numZ = max( numX, numY ); -#pragma omp parallel default(shared) - { - // compute the start of private arrays - int th_id = omp_get_thread_num(); - unsigned long int offs; - offs = th_id*numZ; - REAL *ap = a + offs, *bp = b + offs, *cp = c + offs; - - offs = th_id*numX*3; - REAL *Xp = X + th_id*numX, *Dxp = Dx + offs, *Dxxp = Dxx + offs; - - offs = th_id*numY*3; - REAL *Yp = Y + th_id*numY, *Dyp = Dy + offs, *Dyyp = Dyy + offs; - REAL *Timep = Time + th_id*numT; - - offs = th_id*numX*numY; - REAL *Up = U + offs, *Vp = V + offs, - *MuXp = MuX + offs, *MuYp = MuY + offs, - *VarXp = VarX + offs, *VarYp = VarY + offs, - *ResultEp = ResultE + offs; - -#pragma omp for schedule(static) - for( unsigned i = 0; i < outer; ++ i ) { - REAL strike = 0.001*i; - result[i] = value( s0, strike, t, - alpha, nu, beta, - numX, numY, numT, - ap, bp, cp, Timep, Up, Vp, - Xp, Dxp, Dxxp, MuXp, VarXp, - Yp, Dyp, Dyyp, MuYp, VarYp, - ResultEp - ); - } - } // end parallel region -} - -int main() { - unsigned OUTER_LOOP_COUNT, numX, numY, numT; - REAL s0, t, alpha, nu, beta, strike; - REAL *a, *b, *c, *U, *V, *Time, - *X, *Dx, *Dxx, *MuX, *VarX, - *Y, *Dy, *Dyy, *MuY, *VarY, - *ResultE; - - fprintf(stdout, "\n// Original (Sequential) Volatility Calibration Benchmark:\n"); - readDataSet( OUTER_LOOP_COUNT, numX, numY, numT, s0, t, alpha, nu, beta ); - - REAL* result = new REAL[OUTER_LOOP_COUNT]; - const int Ps = get_CPU_num_threads(); - - unsigned long int elapsed = 0; - { // Main Computational Kernel - struct timeval t_start, t_end, t_diff; - - { // Global Array Allocation - const unsigned numZ = max( numX, numY ); - a = new REAL[Ps*numZ]; // [Ps, max(numX,numY)] - b = new REAL[Ps*numZ]; // [Ps, max(numX,numY)] - c = new REAL[Ps*numZ]; // [Ps, max(numX,numY)] - V = new REAL[Ps*numX*numY]; // [Ps, numX, numY] - U = new REAL[Ps*numY*numX]; // [Ps, numY, numX] - - X = new REAL[Ps*numX]; // [Ps, numX] - Dx = new REAL[Ps*numX*3]; // [Ps, numX, 3] - Dxx = new REAL[Ps*numX*3]; // [Ps, numX, 3] - Y = new REAL[Ps*numY]; // [Ps, numY] - Dy = new REAL[Ps*numY*3]; // [Ps, numY, 3] - Dyy = new REAL[Ps*numY*3]; // [Ps, numY, 3] - Time = new REAL[Ps*numT]; // [Ps, numT] - - MuX = new REAL[Ps*numY*numX]; // [Ps, numY, numX] - MuY = new REAL[Ps*numX*numY]; // [Ps, numX, numY] - VarX = new REAL[Ps*numY*numX]; // [Ps, numY, numX] - VarY = new REAL[Ps*numX*numY]; // [Ps, numX, numY] - ResultE = new REAL[Ps*numX*numY]; // [Ps, numX, numY] - } - - { // Computation Kernel - gettimeofday(&t_start, NULL); - - - run_CPUkernel( OUTER_LOOP_COUNT, numX, numY, numT, - s0, t, alpha, nu, beta, Ps, - a, b, c, Time, U, V, - X, Dx, Dxx, MuX, VarX, - Y, Dy, Dyy, MuY, VarY, - ResultE, result - ); - - gettimeofday(&t_end, NULL); - timeval_subtract(&t_diff, &t_end, &t_start); - elapsed = t_diff.tv_sec*1e6+t_diff.tv_usec; - } - - { // Global Array Deallocation - delete[] a; delete[] b; delete[] c; - delete[] V; delete[] U; - delete[] X; delete[] Dx; delete[] Dxx; - delete[] Y; delete[] Dy; delete[] Dyy; - delete[] MuX; delete[] MuY; - delete[] VarX; delete[] VarY; - delete[] Time; delete[] ResultE; - } - } - - { // validation and writeback of the result - bool is_valid = validate( result, OUTER_LOOP_COUNT ); - writeStatsAndResult( is_valid, result, OUTER_LOOP_COUNT, - numX, numY, numT, false, Ps, elapsed ); -// writeResult( res.data(), OUTER_LOOP_COUNT ); - } - - delete[] result; - return 0; -} - diff --git a/LocVolCalib/Data/Large/input.data b/LocVolCalib/Data/Large/input.data deleted file mode 100644 index 58b7939..0000000 --- a/LocVolCalib/Data/Large/input.data +++ /dev/null @@ -1,10 +0,0 @@ -256 // OUTER -- no restrictions -256 // NUM_X -- 2^x, where x \in {5, ..., 9} -256 // NUM_Y -- 2^x, where x \in {5, ..., 9} -64 // NUM_T -- no restrictions -0.03 // s0 -5.0 // t -0.2 // alpha -0.6 // nu -0.5 // beta - diff --git a/LocVolCalib/Data/Medium/input.data b/LocVolCalib/Data/Medium/input.data deleted file mode 100644 index dfa769d..0000000 --- a/LocVolCalib/Data/Medium/input.data +++ /dev/null @@ -1,9 +0,0 @@ -128 // OUTER -- no restrictions -256 // NUM_X -- 2^x, where x \in {5, ..., 9} -32 // NUM_Y -- 2^x, where x \in {5, ..., 9} -64 // NUM_T -- no restrictions -0.03 // s0 -5.0 // t -0.2 // alpha -0.6 // nu -0.5 // beta diff --git a/LocVolCalib/Data/Small/input.data b/LocVolCalib/Data/Small/input.data deleted file mode 100644 index 4403d69..0000000 --- a/LocVolCalib/Data/Small/input.data +++ /dev/null @@ -1,9 +0,0 @@ -16 // OUTER -- no restrictions -32 // NUM_X -- 2^x, where x \in {5, ..., 9} -256 // NUM_Y -- 2^x, where x \in {5, ..., 9} -256 // NUM_T -- no restrictions -0.03 // s0 -5.0 // t -0.2 // alpha -0.6 // nu -0.5 // beta diff --git a/LocVolCalib/HaskellLH/Makefile b/LocVolCalib/HaskellLH/Makefile deleted file mode 100644 index c9e0ea8..0000000 --- a/LocVolCalib/HaskellLH/Makefile +++ /dev/null @@ -1,46 +0,0 @@ -# can be set using $>gmake GHC=/path/to/my/ghc -ifeq ($(strip $(GHC)),) - GHC=`which ghc` -endif - -# switch this on if llvm is enabled -#BACKEND=-fllvm - -OPTIMIZATION=-O2 -msse2 -rtsopts -#-Wall -EXECUTABLE=VolCalib - -all: $(EXECUTABLE) - -$(EXECUTABLE): % : %.hs - $(GHC) $(OPTIMIZATION) --make $< -o $@ - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) - -# the Large dataset runs out of memory on the current Haskell implementation! -run_large: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) -# cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) - - -#------------------------------------------------------------------------- -# clean -#------------------------------------------------------------------------- -.PHONY : clean_executables clean_obj clean_source_backup -.SILENT : clean_executables clean_obj clean_source_backup - -clean: clean_executables clean_obj clean_source_backup - -clean_executables: - rm -f $(EXECUTABLE) - -clean_obj : - rm -f *.o *.hi - -clean_source_backup: - rm -f *~ - diff --git a/LocVolCalib/OrigCpp/Makefile b/LocVolCalib/OrigCpp/Makefile deleted file mode 100644 index ebab2e3..0000000 --- a/LocVolCalib/OrigCpp/Makefile +++ /dev/null @@ -1,36 +0,0 @@ -include ../../setup.mk - -ifndef ($(HAVE_GPU)) -include ../../platform.mk -endif - -INCLUDES += -I../includeC - -SOURCES_CPP =VolCalibOrig.cpp -HELPERS =../includeC/ParseInput.h -OBJECTS =VolCalibOrig.o -EXECUTABLE =VolCalib - -#g++ -I. -I/usr/local/cuda/include -O3 NordeaVect.cpp -lOpenCL -default: cpu - -.cpp.o: $(SOURCES_CPP) $(HELPERS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< - -cpu: $(EXECUTABLE) - -$(EXECUTABLE): $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) - - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: $(EXECUTABLE) - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - -clean: - rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) diff --git a/LocVolCalib/OrigCpp/VolCalibOrig.cpp b/LocVolCalib/OrigCpp/VolCalibOrig.cpp deleted file mode 100644 index 94ca842..0000000 --- a/LocVolCalib/OrigCpp/VolCalibOrig.cpp +++ /dev/null @@ -1,394 +0,0 @@ -#include - -#define WITH_FLOATS 0 -#define WORKGROUP_SIZE 512 - -typedef double REAL; - -#include "Util.h" -#include "../includeC/ParseInput.h" - -using namespace std; - - -// Macros for 2-dim array indexing -#define Dx(i,j) Dx[(i)*3 + j] -#define Dy(i,j) Dy[(i)*3 + j] -#define Dxx(i,j) Dxx[(i)*3 + j] -#define Dyy(i,j) Dyy[(i)*3 + j] -#define MuX(i,j) MuX[(i)*numX + j] -#define VarX(i,j) VarX[(i)*numX + j] -#define MuY(i,j) MuY[(i)*numY + j] -#define VarY(i,j) VarY[(i)*numY + j] -#define ResultE(i,j) ResultE[(i)*numY + j] - -#define U(i,j) U[(i)*numX + j] -#define V(i,j) V[(i)*numY + j] - -/***********************************/ - -/** - * Initializes MuX, MuY, VarX and VarY - */ -inline -void updateParams( const unsigned numX, - const unsigned numY, - const unsigned g, - const REAL alpha, - const REAL beta, - const REAL nu, - REAL* X, REAL* Y, REAL* Time, - - REAL* MuX, REAL* VarX, // output - REAL* MuY, REAL* VarY // output -) { - - for(unsigned j=0; j(s0/dx); - - for(unsigned i=0; i(numY/2); - - for(unsigned i=0; i=0; i--) { - y[i] = (y[i] - c[i]*y[i+1]) / b[i]; - } -} - -void -rollback( const unsigned numX, - const unsigned numY, - const unsigned g, - REAL* a, REAL* b, REAL* c, REAL* Time, REAL* U, REAL* V, - REAL* Dx, REAL* Dxx, REAL* MuX, REAL* VarX, - REAL* Dy, REAL* Dyy, REAL* MuY, REAL* VarY, - - REAL* ResultE // output -) { - const REAL dtInv = 1.0 / (Time[g+1]-Time[g]); - int i, j; - - // explicit x - for(j=0; j=0; --i ) { - updateParams( numX, numY, i, alpha, beta, nu, - X, Y, Time, MuX, VarX, MuY, VarY ); - - rollback( numX, numY, i, - a, b, c, Time, U, V, - Dx, Dxx, MuX, VarX, - Dy, Dyy, MuY, VarY, - ResultE - ); - } - - REAL res = ResultE(indX,indY); - - return res; -} - - -int main() { - unsigned OUTER_LOOP_COUNT, numX, numY, numT; - REAL s0, t, alpha, nu, beta, strike; - REAL *a, *b, *c, *U, *V, *Time, - *X, *Dx, *Dxx, *MuX, *VarX, - *Y, *Dy, *Dyy, *MuY, *VarY, - *ResultE; - - fprintf(stdout, "\n// Original (Sequential) Volatility Calibration Benchmark:\n"); - readDataSet( OUTER_LOOP_COUNT, numX, numY, numT, s0, t, alpha, nu, beta ); - - REAL* result = new REAL[OUTER_LOOP_COUNT]; - - unsigned long int elapsed = 0; - { // Main Computational Kernel - struct timeval t_start, t_end, t_diff; - - { // Global Array Allocation - const unsigned numZ = max( numX, numY ); - a = new REAL[numZ]; // [max(numX,numY)] - b = new REAL[numZ]; // [max(numX,numY)] - c = new REAL[numZ]; // [max(numX,numY)] - V = new REAL[numX*numY]; // [numX, numY] - U = new REAL[numY*numX]; // [numY, numX] - - X = new REAL[numX]; // [numX] - Dx = new REAL[numX*3]; // [numX, 3] - Dxx = new REAL[numX*3]; // [numX, 3] - Y = new REAL[numY]; // [numY] - Dy = new REAL[numY*3]; // [numY, 3] - Dyy = new REAL[numY*3]; // [numY, 3] - Time = new REAL[numT]; // [numT] - - MuX = new REAL[numY*numX]; // [numY, numX] - MuY = new REAL[numX*numY]; // [numX, numY] - VarX = new REAL[numY*numX]; // [numY, numX] - VarY = new REAL[numX*numY]; // [numX, numY] - ResultE = new REAL[numX*numY]; // [numX, numY] - } - - { // Computation Kernel - gettimeofday(&t_start, NULL); - - REAL strike; - for( unsigned i = 0; i < OUTER_LOOP_COUNT; ++ i ) { - strike = 0.001*i; - result[i] = value( s0, strike, t, - alpha, nu, beta, - numX, numY, numT, - a, b, c, Time, U, V, - X, Dx, Dxx, MuX, VarX, - Y, Dy, Dyy, MuY, VarY, - ResultE - ); - } - - gettimeofday(&t_end, NULL); - timeval_subtract(&t_diff, &t_end, &t_start); - elapsed = t_diff.tv_sec*1e6+t_diff.tv_usec; - } - - { // Global Array Deallocation - delete[] a; delete[] b; delete[] c; - delete[] V; delete[] U; - delete[] X; delete[] Dx; delete[] Dxx; - delete[] Y; delete[] Dy; delete[] Dyy; - delete[] MuX; delete[] MuY; - delete[] VarX; delete[] VarY; - delete[] Time; delete[] ResultE; - } - } - - { // validation and writeback of the result - bool is_valid = validate( result, OUTER_LOOP_COUNT ); - writeStatsAndResult( is_valid, result, OUTER_LOOP_COUNT, - numX, numY, numT, false, 1, elapsed ); -// writeResult( res.data(), OUTER_LOOP_COUNT ); - } - - delete[] result; - return 0; -} - diff --git a/LocVolCalib/OutParOpenCLMP/Makefile b/LocVolCalib/OutParOpenCLMP/Makefile deleted file mode 100644 index 3b7244e..0000000 --- a/LocVolCalib/OutParOpenCLMP/Makefile +++ /dev/null @@ -1,56 +0,0 @@ -MAKE_DIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) - -include ../../setup.mk - -ifndef ($(HAVE_GPU)) -include ../../platform.mk -endif - -INCLUDES += -I../includeC -GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -D GPU_DEV_ID=$(GPU_DEVICE_ID) \ - -D GPU_LOC_MEM=$(GPU_LOCAL_MEM) -D GPU_CONST_MEM=$(GPU_CONST_MEM) \ - -D GPU_REG_MEM=$(GPU_REG_MEM) -D GPU_GLB_MEM=$(GPU_DEVICE_MEM) \ - -D GPU_TILE=$(GPU_LOCAL_MEM_PER_TH) -D GPU_CORES=$(GPU_NUM_CORES) \ - -D CURR_DIR_PATH='"$(MAKE_DIR)"' - -SOURCES_CPP =VolCalibOuter.cpp -HELPERS =PrepareKernels.h Vect_CPU.h Vect_GPU.h VolCalibInit.h ../includeC/Constants.h \ - ../includeC/ParseInput.h ../includeC/DataStructConst.h ../includeC/ParPrefixUtil.h -OBJECTS =VolCalibOuter.o -EXECUTABLE =VolCalib - - -ifeq ($(HAVE_GPU),1) -default: gpu -else -# cannot build this one... -no-gpu: - @echo "\n*** No GPU configured, cannot build `pwd` ***\n" -endif - - -#.cpp.o: -# $(CXX) $(CXXFLAGS) $(INCLUDES) -c -o $@ $< - -#$(OBJECTS) -cpu: - $(CXX) $(CXXFLAGS) -D IS_GPU=0 $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(SOURCES_CPP) $(LIB) - -gpu: - $(CXX) $(CXXFLAGS) -D IS_GPU=1 $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(SOURCES_CPP) $(LIB) - - -run_small: - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - -clean: - rm -f $(EXECUTABLE) $(OBJECTS) ./*.ptx ./Debug.txt - @# clean nVidia compiler cache - rm -rf $(HOME)/.nv/ComputeCache/* - diff --git a/LocVolCalib/includeC/Constants.h b/LocVolCalib/includeC/Constants.h deleted file mode 100644 index 8fd8365..0000000 --- a/LocVolCalib/includeC/Constants.h +++ /dev/null @@ -1,42 +0,0 @@ -#ifndef CONSTANTS_H -#define CONSTANTS_H - -#define WITH_FLOATS 1 - -#define REAL3_CT 4 -#define TRANSPOSE_UV 1 - -#if (WITH_FLOATS) - typedef float REAL; - typedef unsigned int ULONG; -#else - #pragma OPENCL EXTENSION cl_khr_fp64: enable - typedef double REAL; - typedef unsigned long ULONG; -#endif - -#define WARP (1< -#include - -#include -#include -#include -#include - -#include - -using namespace std; - -/////////////////////////////////////////////////////// -//// FLAGS and CONSTANT SCALARS! -/////////////////////////////////////////////////////// - -#define TRIDAG_ALL_OPT_ON -#define MOST_OPTIMISED_ON - -//#define IS_GPU -//#define DEBUG_PRINT_GPU_INFO - -unsigned int OUTER_LOOP_COUNT; //128; //1024; //100; -unsigned int NUM_X ; //256; //256; //64; //256; -unsigned int NUM_Y ; //32; //32; //32; -unsigned int NUM_T ; //64; //64; //64; -unsigned int NUM_XY ; //NUM_X*NUM_Y; - -/////////////////////////////////////////////////////// -//// GLOBAL ARRAYS ! -/////////////////////////////////////////////////////// - -/// grid /// -REAL* myX ; // 1-dim, size: NUM_X -REAL* myY ; // 1-dim, size: NUM_Y -REAL* myTimeline; // 1-dim, size: NUM_T - -unsigned int myXindex, myYindex; - -/// variable /// -REAL* myResArr; //[OUTER_LOOP_COUNT * NUM_Y * NUM_X]; // 3-dim, size: OUTER_LOOP_COUNT x NUM_Y x NUM_X - - -/// coeffs /// -REAL *myMuX, *myVarX; // 2-dim, size: NUM_X x NUM_Y -REAL *myMuY, *myVarY; // 2-dim, size: NUM_X x NUM_Y - -// operators -REAL *myDx, *myDxx; // 2-dim, size: NUM_X x REAL3_CT -REAL *myDy, *myDyy; // 2-dim, size: NUM_Y x REAL3_CT - -void allocGlobArrs() { - myX = new REAL[NUM_X]; - myY = new REAL[NUM_Y]; - myTimeline = new REAL[NUM_T]; - - myMuX = new REAL[NUM_X * NUM_Y]; - myVarX= new REAL[NUM_X * NUM_Y]; - myMuY = new REAL[NUM_X * NUM_Y]; - myVarY= new REAL[NUM_X * NUM_Y]; - - myDx = new REAL[NUM_X * REAL3_CT]; - myDxx = new REAL[NUM_X * REAL3_CT]; - myDy = new REAL[NUM_Y * REAL3_CT]; - myDyy = new REAL[NUM_Y * REAL3_CT]; - - myResArr = new REAL[OUTER_LOOP_COUNT * NUM_Y * NUM_X]; -} - -void deallocGlobArrs() { - delete[] myX; - delete[] myY; - delete[] myTimeline; - - delete[] myMuX; - delete[] myVarX; - delete[] myMuY; - delete[] myVarY; - - delete[] myDx; - delete[] myDxx; - delete[] myDy; - delete[] myDyy; - - delete[] myResArr; -} - -#endif // end include NORDEA_DATA_STRUCT diff --git a/LocVolCalib/includeC/ParseInput.h b/LocVolCalib/includeC/ParseInput.h deleted file mode 100644 index c79bb83..0000000 --- a/LocVolCalib/includeC/ParseInput.h +++ /dev/null @@ -1,138 +0,0 @@ -#ifndef PARSE_INPUT -#define PARSE_INPUT - -#include "ParserC.h" -#include -#include -#include - -using namespace std; - -#include -using std::cout; -using std::endl; - - -#if WITH_FLOATS - #define read_real read_float -#else - #define read_real read_double -#endif - -const float EPS = 0.00001; - -/***********************************/ -/********** READ DATA SET **********/ -/***********************************/ - -void readDataSet( unsigned int& outer, - unsigned int& num_X, - unsigned int& num_Y, - unsigned int& num_T, - REAL & s0, - REAL & t, - REAL & alpha, - REAL & nu, - REAL & beta -) { - if( read_int ( static_cast( &outer ) ) || - read_int ( static_cast( &num_X ) ) || - read_int ( static_cast( &num_Y ) ) || - read_int ( static_cast( &num_T ) ) || - read_real( static_cast ( &s0 ) ) || - read_real( static_cast ( &t ) ) || - read_real( static_cast ( &alpha ) ) || - read_real( static_cast ( &nu ) ) || - read_real( static_cast ( &beta ) ) ) { - - fprintf(stderr, "Syntax error when reading the dataset, i.e., four ints and six reals.\n"); - exit(1); - } - - { // check dataset invariants: - bool atr_ok = true; - - atr_ok = outer > 0; - assert(atr_ok && "Outer loop count less than 0!"); - - atr_ok = (num_X > 0) && (num_X <= WORKGROUP_SIZE) && is_pow2(num_X); - assert(atr_ok && "Illegal NUM_X value!"); - - atr_ok = (num_Y > 0) && (num_Y <= WORKGROUP_SIZE) && is_pow2(num_Y); - assert(atr_ok && "Illegal NUM_X value!"); - - atr_ok = num_T > 0; - assert(atr_ok && "NUM_T value less or equal to zero!!"); - } -} - -REAL* readOutput( const int& N ) { - REAL* result; - int64_t shape[3]; - - // reading the standard output - if (read_array(sizeof(REAL), read_real, (void**)&result, shape, 1) ) { - fprintf(stderr, "Syntax error when reading the output.\n"); - exit(1); - } - - bool ok = ( shape[0] == N ); - assert(ok && "Incorrect shape of the standard result!"); - - return result; -} - -bool validate( const REAL* res, const int& N ) { - bool is_valid = true; - - REAL* std_res = readOutput( N ); - - for ( int i = 0; i < N; i ++ ) { - float err = fabs(std_res[i] - res[i]); - if ( err > EPS || isnan(res[i]) || isinf(res[i]) ) { - is_valid = false; - fprintf(stderr, "Error[%d] = %f, EPS = %f!\n", i, err, EPS); - break; - } - } - - return is_valid; -} - -void writeStatsAndResult( const bool& valid, const REAL* data, - const int & outer, const int & num_X, - const int & num_Y, const int & num_T, - const bool& is_gpu,const int & P, - const unsigned long int& elapsed -) { - // print stats to stdout - fprintf(stdout, "// OUTER=%d, NUM_X=%d, NUM_Y=%d, NUM_T=%d.\n", - outer, num_X, num_Y, num_T ); - - if(valid) { fprintf(stdout, "1\t\t// VALID Result,\n"); } - else { fprintf(stdout, "0\t\t// INVALID Result,\n"); } - - fprintf(stdout, "%ld\t\t// Runtime in microseconds,\n", elapsed); - if(is_gpu) fprintf(stdout, "%d\t\t// GPU Threads,\n\n", P); - else fprintf(stdout, "%d\t\t// CPU Threads,\n\n", P); - - // write the result - write_1Darr( data, static_cast(outer), - "Volatility Calibration Result" ); -} - -#if 0 -void writeResult( const REAL* res, const unsigned int N, const char* msg ) { - //ofstream fout; - //fout.open ("output.data"); - cout << "\n[ " - for( int k=0; k -using std::cout; -using std::endl; - -#include -using std::ifstream; - -#include - -const int MAX_CHARS_PER_LINE = 512; -const int MAX_TOKENS_PER_LINE = 20; -const char* const DELIMITER = " :="; - -const float EPS = 0.00001; - -/***********************************/ -/********** READ DATA SET **********/ -/***********************************/ - -bool is_pow2(int atr_val) { - int x = 1; - - for(int i = 0; i < 31; i++) { - if(x == atr_val) return true; - x = (x << 1); - } - return false; -} -#if 0 -static bool is_pow2(unsigned int x) { - while(x > 1) { - if( x & 1 ) return false; - x = x >> 1; - } - return true; -} -#endif - -inline int parseIntAttribute(ifstream& fin, char* buf, const char* atr) { - int ret_val; - - assert( (!fin.eof()) && "incomplete input.data file!" ); - fin.getline(buf, MAX_CHARS_PER_LINE); - - { // reading the atribute name - char* token_atr = strtok(buf, DELIMITER); - bool ok = (token_atr != NULL) && (strcmp(token_atr, atr) == 0); - assert( ok && "illegal/missing attribute name in input.data file!"); - // the result of strtok is part of buf, - // i.e., no dealocation is necessary! - } - - { // reading the attribute value - char* token_val = strtok(NULL, DELIMITER); - assert( token_val && "missing attribute value in input.data file!"); - ret_val = atoi(token_val); - } - - return ret_val; -} - -void readDataSet( unsigned int& outer, - unsigned int& num_X, - unsigned int& num_Y, - unsigned int& num_T -) { - char buf[MAX_CHARS_PER_LINE]; - int atr_val; bool atr_ok; - - // create a file-reading object - ifstream fin; - fin.open("input.data"); - assert(fin.good() && "Error opening input.data file!"); - - { // seeting and checking legality of the outer loop count - atr_val = parseIntAttribute(fin, buf, "OUTER"); - atr_ok = atr_val > 0; - assert(atr_ok && "outer loop count less than 0!"); - outer = static_cast(atr_val); - } - - { // seeting and checking legality of NUM_X - atr_val = parseIntAttribute(fin, buf, "NUM_X"); - atr_ok = (atr_val > 0) && (atr_val <= 512) && is_pow2(atr_val); - assert(atr_ok && "illegal NUM_X value!"); - num_X = static_cast(atr_val); - } - - { // seeting and checking legality of NUM_Y - atr_val = parseIntAttribute(fin, buf, "NUM_Y"); - atr_ok = (atr_val > 0) && (atr_val <= 512) && is_pow2(atr_val); - assert(atr_ok && "illegal NUM_Y value!"); - num_Y = static_cast(atr_val); - } - - { // seeting and checking legality of NUM_T - atr_val = parseIntAttribute(fin, buf, "NUM_T"); - atr_ok = atr_val > 0; - assert(atr_ok && "NUM_T value less or equal to zero!"); - num_T = static_cast(atr_val); - } - - fin.close(); - - cout<<"Parameters: { OUTER = "< EPS ) { - is_valid = false; - cout<<"INVALID: error["< "< compile the benchmark -# run_X run the benchmark with data set X -# (where X is in {small,medium,large}) -# clean -# -# Some centralised targets are defined here: -# run_all: runs all benchmarks with all data -# clean: calls make clean in all configured subdirectories -# OptionPricing: compile all programs in OptionPricing subdir -# - - -################################################################# - -# As per today, we have the following working directories: - -# Option Pricing -# ./OptionPricing/OrigCpp -- sequential, original C(++) code -# ./OptionPricing/CppOpenMP -- OpenMP version -# ./OptionPricing/CppOpenCL -- GPU version using OpenCL -# ./OptionPricing/HaskellLH -- Haskell version documenting all parallelism. -# -# Local Volatility Calibration -# ./LocVolCalib/OrigCpp -- sequential, original C(++) code -# ./LocVolCalib/COpenMP -- OpenMP C version of the code -# ./LocVolCalib/AllParOpenCLMP -- parallelizing the outer two loops in OpenCL and OpenMP -# ./LocVolCalib/OutParOpenCLMP -- parallelizing the whole loop nest in OpenCL and OpenMP -# ./LocVolCalib/HaskellLH -- Haskell version documenting all parallelism. -# -# Interest Rate Calibration: -# ./InterestCalib/OrigCpp -- sequential C++ code (translated from the original Caml code) -# ./InterestCalib/CppOpenMP -- OpenMP version, in which only the outermost loop is parallel -# ./InterestCalib/CppOpenCL -- OpenCL version, which needs to exploit parallelism on all levels. -# ./InterestCalib/HaskellLH -- Haskell version documenting all parallelism. -# - -BENCHMARKS =OptionPricing #LocVolCalib #InterestCalib - -VERSIONS_OptionPricing = OptionPricing/OrigCpp OptionPricing/CppOpenMP \ - OptionPricing/HaskellLH OptionPricing/CppOpenCL - -VERSIONS_LocVolCalib = LocVolCalib/OrigCpp LocVolCalib/COpenMP LocVolCalib/AllParOpenCLMP \ - LocVolCalib/HaskellLH LocVolCalib/OutParOpenCLMP - -VERSIONS_InterestCalib = InterestCalib/OrigCpp InterestCalib/CppOpenMP \ - InterestCalib/CppOpenCL InterestCalib/HaskellLH - -include platform.mk - -####################### rules start here ######################## - -# default: help text -.PHONY: help -help: - @echo "\tFor now, please read the makefile before using it" - @echo "\t XXX Help text should be added soon here" - -all : $(BENCHMARKS) run_all - -run_all :: - @echo "Running all benchmarks" - -OptionPricing: $(VERSIONS_OptionPricing) - -LocVolCalib: $(VERSIONS_LocVolCalib) - -InterestCalib: $(VERSIONS_InterestCalib) - - -################## target construction functions ################ -# : -# $(MAKE) -C - -#run_ : -# make -C run_ - -# XXX BTW some renaming/reducing dir.s will be appropriate... -# */Data/[small|medium|large][in|out] is good enough - -define runRule -# arg.s: benchmark/version, Category (small,medium,large) -#$$(warning runRule($(1),$(2))) - -.PHONY: run_$(1)_$(2) -run_$(1)_$(2): $(1) - $$(MAKE) -C $(1) run_$(2) -run_all :: run_$(1)_$(2) - -endef - -define mkStdRule -# arg.: Benchmark/Version# -#$$(warning mkStdRule($(1))) - -.PHONY: $(1) -# building the target -$(1): - $$(MAKE) -C $(1) - -# running small,medium,large -$$(eval $$(call runRule,$(1),small)) -$$(eval $$(call runRule,$(1),medium)) -$$(eval $$(call runRule,$(1),large)) - -# and cleaning... -clean :: - $$(MAKE) -C $(1) clean -endef - -################## constructing the targets ################ - -$(foreach B,$(VERSIONS_OptionPricing),$(eval $(call mkStdRule,$(B)))) -$(foreach B,$(VERSIONS_LocVolCalib),$(eval $(call mkStdRule,$(B)))) - -$(foreach B,$(VERSIONS_InterestCalib),$(eval $(call mkStdRule,$(B)))) - -# custom rules would go here as well diff --git a/OptionPricing/CppOpenCL/Makefile b/OptionPricing/CppOpenCL/Makefile deleted file mode 100644 index 3862aef..0000000 --- a/OptionPricing/CppOpenCL/Makefile +++ /dev/null @@ -1,62 +0,0 @@ -MAKE_DIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) - -include ../../setup.mk - -ifndef ($(HAVE_GPU)) - ifeq ($(OS),Darwin) - include ../../platform.macbookpro.mk - else - include ../../platform.mk - endif -endif - -INCLUDES += -I../includeC -GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -D GPU_DEV_ID=$(GPU_DEVICE_ID) \ - -D GPU_LOC_MEM=$(GPU_LOCAL_MEM) -D GPU_CONST_MEM=$(GPU_CONST_MEM) \ - -D GPU_REG_MEM=$(GPU_REG_MEM) -D GPU_GLB_MEM=$(GPU_DEVICE_MEM) \ - -D GPU_TILE=$(GPU_LOCAL_MEM_PER_TH) -D GPU_CORES=$(GPU_NUM_CORES) \ - -D CURR_DIR_PATH='"$(MAKE_DIR)"' - -SOURCES_CPP =GenPricing.cpp -HELPERS =StructGPU.h ../includeC/Constants.h ../includeC/Optimizations.h ../includeC/ParseInput.h -OBJECTS =GenPricing.o -EXECUTABLE =GenPricing - - -ifeq ($(HAVE_GPU),1) -#g++ -I. -I/usr/local/cuda/include -O3 NordeaVect.cpp -lOpenCL -default: gpu -else -# cannot build this one... but proceed (return 0) -no-gpu: - @echo "$(HAVE_GPU) \n*** No GPU configured, cannot build `pwd` ***\n" -endif - -.cpp.o: $(SOURCES_CPP) $(HELPERS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< - -gpu: $(OBJECTS) $(SOURCES_CPP) $(HELPERS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) $(LIB) - -# The CPU version is in: ../Orig_COpenMP. This folder is GPU only! -cpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) $(LIB) - -run_small: - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - - -#default: $(OBJECTS) -# $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) $(LIB) - -clean: - rm -f $(EXECUTABLE) $(OBJECTS) ./*.ptx ./Debug.txt - @# clean nVidia compiler cache - rm -rf $(HOME)/.nv/ComputeCache/* - diff --git a/OptionPricing/CppOpenMP/Makefile b/OptionPricing/CppOpenMP/Makefile deleted file mode 100644 index f4b87c0..0000000 --- a/OptionPricing/CppOpenMP/Makefile +++ /dev/null @@ -1,42 +0,0 @@ -include ../../setup.mk - -ifndef ($(HAVE_GPU)) -include ../../platform.mk -endif - -INCLUDES += -I../includeC -GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) - -SOURCES_CPP =GenPricing.cpp -HELPERS =Contracts.h SobolGaussBB.h ../includeC/Constants.h ../includeC/Optimizations.h ../includeC/ParseInput.h -# XXX what about the boilerplate in ../includeC ??? -OBJECTS =GenPricing.o -EXECUTABLE =GenPricing - -default: cpu - -# TODO need redesign, probably use different executable names (or -# standardisation of "gpu" targets across all benchmarks) - -.cpp.o: $(SOURCES_CPP) $(HELPERS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< - -# The GPU version is in: ../CppOpenCL. This folder is CPU only! -gpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) - -cpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: $(EXECUTABLE) - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - -clean: - rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) - diff --git a/OptionPricing/Data/Large/input.data b/OptionPricing/Data/Large/input.data deleted file mode 100644 index 979fe1f..0000000 --- a/OptionPricing/Data/Large/input.data +++ /dev/null @@ -1,4090 +0,0 @@ -3 // contract number -131072 // number of Monte-Carlo Iterations -367 // number of path dates -3 // number of underlyings -1 // number of models -30 // integer bit-length representation for Sobol - -// Begin Direction vectors [3*367][30] -[ - [ - 536870912, 268435456, 134217728, 67108864, 33554432, 16777216, 8388608, 4194304, 2097152, 1048576, 524288, 262144, 131072, 65536, 32768, 16384, 8192, 4096, 2048, 1024, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 570425344, 855638016, 713031680, 1069547520, 538968064, 808452096, 673710080, 1010565120, 572653568, 858980352, 715816960, 1073725440, 536879104, 805318656, 671098880, 1006648320, 570434048, 855651072, 713042560, 1069563840, 538976288, 808464432, 673720360, 1010580540, 572662306, 858993459 - ], - [ - 536870912, 805306368, 402653184, 603979776, 973078528, 385875968, 595591168, 826277888, 438304768, 657457152, 999817216, 358875136, 538574848, 807862272, 406552576, 605372416, 975183872, 389033984, 597170176, 828646400, 437926400, 656873216, 1002152832, 357921088, 536885792, 805312304, 402662296, 603992420, 973085210, 385885991 - ], - [ - 536870912, 805306368, 939524096, 335544320, 234881024, 721420288, 411041792, 616562688, 920649728, 1062207488, 381157376, 258736128, 771883008, 453181440, 545488896, 817971200, 954261504, 340963328, 238651392, 732843008, 417426944, 609285376, 909831040, 1068349120, 383778848, 256901168, 783810616, 460062740, 537001998, 805503019 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 167772160, 285212672, 713031680, 566231040, 853540864, 489684992, 952631296, 208928768, 316801024, 758317056, 550076416, 813154304, 417505280, 1009913856, 172697600, 297131008, 704744960, 553894656, 847291520, 499194688, 954376224, 204607536, 306915352, 766893116, 536972810, 805552913 - ], - [ - 536870912, 805306368, 402653184, 469762048, 301989888, 721420288, 92274688, 264241152, 941621248, 741343232, 169345024, 924581888, 395444224, 619380736, 1034256384, 603963392, 838868992, 452997120, 494934016, 331357184, 706744832, 120597248, 261621120, 953946048, 800208928, 148581424, 935168536, 350484252, 630339474, 1072370923 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 503316480, 754974720, 629145600, 440401920, 94371840, 711983104, 229113856, 374079488, 330694656, 996212736, 907247616, 557531136, 867573760, 190918656, 1041467392, 490437632, 766918144, 643898624, 462663040, 125527616, 672545696, 202454896, 373006376, 288845836, 1000351766, 930090001 - ], - [ - 536870912, 268435456, 402653184, 872415232, 838860800, 956301312, 612368384, 717225984, 211812352, 386924544, 302514176, 688128000, 1015414784, 516751360, 1051492352, 773734400, 914432000, 63877120, 807741440, 165200896, 748683776, 118489344, 168296832, 486802240, 243663648, 667747216, 439124552, 81674924, 975249610, 350138737 - ], - [ - 536870912, 268435456, 671088640, 469762048, 973078528, 1023410176, 713031680, 339738624, 912261120, 797966336, 176685056, 71565312, 510263296, 865533952, 814120960, 961232896, 887136256, 668078080, 116070400, 382772224, 1047134720, 597098752, 411468416, 625689024, 249602976, 449975248, 745216680, 43033924, 134873446, 201786361 - ], - [ - 536870912, 268435456, 402653184, 67108864, 704643072, 385875968, 696254464, 205520896, 920649728, 946864128, 359137280, 859045888, 302907392, 50659328, 462192640, 524599296, 895541248, 590794752, 168810496, 118033408, 831447552, 138662144, 485185920, 796511296, 1021313184, 1064304752, 619184920, 997458052, 250479054, 745865975 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 838860800, 889192448, 645922816, 46137344, 476053504, 584056832, 210239488, 465829888, 820903936, 689897472, 73695232, 249118720, 110075904, 315338752, 610637824, 517665792, 1049494016, 785318144, 376210304, 735921088, 402760480, 738505552, 168368744, 151499820, 344957894, 936096557 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 503316480, 922746880, 41943040, 423624704, 228589568, 651165696, 195559424, 500957184, 791019520, 261292032, 1040285696, 118407168, 982065152, 625250304, 329533440, 298984448, 153690624, 76845824, 579619712, 692987840, 900670432, 450334832, 363187112, 719119956, 765461306, 382730781 - ], - [ - 536870912, 805306368, 402653184, 603979776, 838860800, 117440512, 478150656, 658505728, 752877568, 1060110336, 141033472, 209453056, 244187136, 272957440, 678068224, 1014546432, 377724928, 876875776, 443160576, 998185984, 168665600, 318837504, 914397568, 71818816, 40763680, 527762288, 939688008, 335855668, 705536494, 587273091 - ], - [ - 536870912, 268435456, 671088640, 738197504, 637534208, 150994944, 813694976, 943718400, 77594624, 179306496, 798490624, 967049216, 134348800, 1006698496, 235044864, 620937216, 377643008, 826314752, 874711040, 854819840, 725109248, 856992512, 664336768, 94804544, 100663328, 419430416, 411041832, 339738668, 580911142, 61865993 - ], - [ - 536870912, 805306368, 939524096, 603979776, 100663296, 452984832, 998244352, 188743680, 866123776, 389021696, 287834112, 172228608, 824836096, 977731584, 153714688, 507854848, 254402560, 88403968, 883578880, 235160576, 118055424, 422917888, 371224704, 326210368, 654926368, 691353392, 773877944, 930190180, 554263078, 842348331 - ], - [ - 536870912, 268435456, 134217728, 872415232, 771751936, 486539264, 629145600, 163577856, 467664896, 472907776, 168296448, 993787904, 201981952, 37552128, 260734976, 587087872, 535322624, 705662976, 729954304, 79891456, 912360960, 569626368, 1072277120, 974077120, 595691040, 818138896, 409052808, 1022573812, 443254286, 869191437 - ], - [ - 536870912, 805306368, 134217728, 67108864, 369098752, 654311424, 562036736, 1044381696, 333447168, 1068498944, 487063552, 614727680, 652869632, 790036480, 635600896, 682835968, 881451008, 518402048, 587823104, 933663744, 426354176, 844586752, 25366144, 239108416, 467682848, 1001484080, 185235080, 61216068, 124379190, 290861079 - ], - [ - 536870912, 805306368, 134217728, 603979776, 436207616, 1023410176, 830472192, 1061158912, 274726912, 946864128, 752353280, 1040973824, 660209664, 206503936, 247103488, 796737536, 671293440, 335712256, 302135296, 419587072, 730054144, 37987072, 568382336, 120820672, 1018805792, 108831536, 193090440, 843240420, 702586426, 590426893 - ], - [ - 536870912, 805306368, 402653184, 335544320, 637534208, 452984832, 578813952, 364904448, 903872512, 84934656, 498597888, 152829952, 794951680, 886243328, 374964224, 51200000, 911761408, 856600576, 777627648, 655301632, 140164608, 1007657216, 718934912, 701382080, 523919392, 752726064, 41953304, 633494548, 769842726, 286331163 - ], - [ - 536870912, 805306368, 134217728, 67108864, 1040187392, 721420288, 696254464, 272629760, 945815552, 202375168, 973602816, 360448000, 47579136, 965935104, 671121408, 872464384, 905977856, 788533248, 394328064, 994094080, 299935232, 475021568, 40427904, 426520640, 954132512, 753882608, 718703448, 227747404, 503316482, 452984835 - ], - [ - 536870912, 268435456, 134217728, 335544320, 167772160, 822083584, 343932928, 884998144, 618659840, 753926144, 953679872, 852230144, 61734912, 386334720, 598638592, 117915648, 732864512, 319229952, 565086208, 570938368, 892262912, 382142208, 298731904, 976729280, 689351392, 150700016, 716743768, 536617964, 152480482, 419135473 - ], - [ - 536870912, 268435456, 402653184, 603979776, 33554432, 486539264, 679477248, 155189248, 580911104, 678428672, 745013248, 1043595264, 997326848, 936706048, 1021870080, 57950208, 64118784, 648384512, 973113344, 687879168, 847299072, 809547008, 136348288, 1009833408, 642257824, 520412624, 901408584, 563183252, 737329666, 177583361 - ], - [ - 536870912, 805306368, 134217728, 738197504, 234881024, 687865856, 176160768, 750780416, 429916160, 355467264, 1017643008, 563347456, 825622528, 514523136, 110526464, 312197120, 952016896, 869232640, 505976832, 290771968, 781595136, 245081856, 1052701824, 919569344, 447225376, 345248144, 1035356408, 929807420, 464961058, 40591763 - ], - [ - 536870912, 805306368, 671088640, 335544320, 436207616, 486539264, 511705088, 742391808, 375390208, 995098624, 229113856, 905183232, 966393856, 533528576, 209747968, 356564992, 987799552, 504385536, 524838912, 1071936512, 1020426752, 1026142464, 785570176, 69807424, 38934176, 560547792, 280145512, 729389876, 368705538, 161284099 - ], - [ - 536870912, 805306368, 134217728, 335544320, 100663296, 721420288, 713031680, 666894336, 371195904, 326107136, 918028288, 904134656, 997851136, 317915136, 1004699648, 73908224, 1042325504, 930123776, 951597056, 182778880, 402305536, 506671872, 121795200, 819401408, 515383904, 300157520, 897191688, 770924636, 392310882, 145205587 - ], - [ - 536870912, 268435456, 939524096, 201326592, 1040187392, 385875968, 713031680, 398458880, 140509184, 609222656, 174587904, 627310592, 64094208, 708509696, 895123456, 1003438080, 637558784, 184578048, 746592256, 213937152, 484463104, 613417728, 680037248, 385142336, 31066144, 722404560, 1021355752, 881884540, 277363234, 452229073 - ], - [ - 536870912, 268435456, 134217728, 603979776, 905969664, 721420288, 109051904, 20971520, 664797184, 919601152, 422051840, 198967296, 617480192, 71892992, 638091264, 592199680, 583409664, 923111424, 214849536, 810150912, 403225088, 743232768, 306603648, 491120448, 770582176, 131712624, 645969848, 289415012, 799054338, 315639041 - ], - [ - 536870912, 805306368, 939524096, 469762048, 570425344, 1056964608, 58720256, 557842432, 786432000, 632291328, 270008320, 139722752, 607518720, 1048248320, 494436352, 1017430016, 583983104, 262107136, 190187520, 898317312, 402681344, 738211072, 436261760, 587209408, 562087520, 507533392, 761275736, 82897452, 1056476674, 769934595 - ], - [ - 536870912, 268435456, 671088640, 67108864, 33554432, 486539264, 310378496, 239075328, 186646528, 634388480, 96993280, 367263744, 1032454144, 966590464, 1000374272, 646987776, 879271936, 980684800, 828508160, 346649600, 291686912, 78215424, 962727040, 11126592, 996294432, 497644432, 702714920, 334101364, 583180290, 909709313 - ], - [ - 536870912, 268435456, 402653184, 335544320, 503316480, 117440512, 746586112, 876609536, 236978176, 523239424, 950534144, 712769536, 154009600, 870907904, 209747968, 608190464, 371220480, 187715584, 648574976, 763108352, 632205824, 128569600, 44087424, 997211328, 780698272, 558692848, 797334712, 513135524, 690880514, 602472449 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 100663296, 218103808, 746586112, 641728512, 1029701632, 883949568, 439877632, 996933632, 967442432, 920715264, 492863488, 78692352, 37249024, 124579840, 1068111872, 1004614656, 836776448, 586176768, 1062770048, 870064832, 630354144, 9296304, 139121832, 336691844, 574119938, 929886211 - ], - [ - 536870912, 805306368, 939524096, 335544320, 570425344, 553648128, 981467136, 62914560, 488636416, 76546048, 748158976, 818675712, 1054212096, 701431808, 273580032, 134463488, 739794944, 906792960, 58091520, 463459328, 964092416, 513755904, 435617408, 677350720, 475410144, 235914608, 393104184, 965967628, 402705634, 604016243 - ], - [ - 536870912, 805306368, 671088640, 67108864, 973078528, 285212672, 343932928, 692060160, 148897792, 1058013184, 669515776, 14942208, 185204736, 904724480, 367558656, 635748352, 227188736, 162336768, 864577536, 582255616, 906162688, 521778432, 394939264, 682457152, 252243360, 267679376, 81938344, 822706164, 618852866, 17413379 - ], - [ - 536870912, 805306368, 939524096, 201326592, 704643072, 754974720, 897581056, 1019215872, 656408576, 680525824, 824705024, 397148160, 633208832, 881393664, 320241664, 249937920, 906518528, 255651840, 748046336, 790987776, 480837120, 392988416, 278833792, 1025073472, 1035890720, 143231216, 18277464, 803573652, 696815138, 519835635 - ], - [ - 536870912, 268435456, 134217728, 469762048, 637534208, 587202560, 25165824, 1019215872, 442499072, 355467264, 715653120, 557056000, 11141120, 739573760, 1046642688, 923877376, 1004576768, 972042240, 952678400, 671415296, 201498112, 773947136, 1061744512, 667215808, 534962976, 466722832, 696299528, 817952900, 878763298, 707850001 - ], - [ - 536870912, 805306368, 402653184, 67108864, 167772160, 721420288, 612368384, 817889280, 312475648, 630194176, 253231104, 516685824, 62521344, 841154560, 523927552, 920895488, 530243584, 1014222848, 1040369664, 964656128, 194533888, 504151808, 152735872, 330557760, 438455520, 53428848, 950012424, 1049638652, 865619170, 705446515 - ], - [ - 536870912, 805306368, 671088640, 335544320, 1040187392, 452984832, 260046848, 566231040, 580911104, 292552704, 446169088, 490995712, 411172864, 742719488, 841121792, 422952960, 1052385280, 191991808, 397989888, 502594560, 146433536, 879868672, 238603392, 859074240, 463109856, 532801488, 964754152, 515911108, 991977186, 1068529619 - ], - [ - 536870912, 805306368, 402653184, 603979776, 973078528, 620756992, 679477248, 239075328, 639631360, 187695104, 798490624, 669253632, 987365376, 108331008, 706772992, 218251264, 346038272, 275787776, 959977472, 110371840, 157432320, 262219008, 400730240, 584273472, 578455072, 272071472, 673224600, 1006793700, 505428186, 523253621 - ], - [ - 536870912, 805306368, 671088640, 469762048, 503316480, 922746880, 1048576000, 750780416, 933232640, 359661568, 231211008, 302776320, 822476800, 1031995392, 276594688, 845529088, 728637440, 184496128, 78817280, 32168960, 336903680, 840550144, 18888320, 363856064, 208142752, 746339952, 474885448, 877595084, 677034022, 911655987 - ], - [ - 536870912, 268435456, 939524096, 872415232, 436207616, 419430400, 729808896, 943718400, 648019968, 433061888, 1071120384, 549715968, 72482816, 547684352, 384663552, 592920576, 805969920, 673255424, 203405312, 774009856, 54508032, 850544896, 331854720, 518413376, 1064150176, 639067344, 522851928, 615589252, 619162482, 913730613 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 1040187392, 754974720, 629145600, 775946240, 689963008, 397410304, 626524160, 496762880, 575537152, 253034496, 111771648, 1053310976, 517480448, 786182144, 921573376, 182795264, 886160896, 434400512, 1011746176, 303373888, 992588064, 747137968, 167263064, 342622364, 909516750, 960044373 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 234881024, 687865856, 427819008, 457179136, 333447168, 890241024, 664272896, 441712640, 911343616, 544669696, 491290624, 918994944, 176332800, 702935040, 504891392, 823397376, 229778944, 694621440, 886085504, 93516352, 626043488, 315809360, 280018040, 851632964, 547919818, 450289443 - ], - [ - 536870912, 805306368, 402653184, 67108864, 503316480, 318767104, 763363328, 708837376, 199229440, 328204288, 157810688, 1048313856, 1036648448, 478478336, 1053982720, 421904384, 144220160, 148959232, 371865600, 1058354176, 800753152, 593090304, 726832000, 124111168, 91790944, 208719312, 750920840, 942213868, 873504546, 101507001 - ], - [ - 536870912, 268435456, 402653184, 603979776, 771751936, 452984832, 947912704, 146800640, 253755392, 512753664, 802684928, 1032060928, 595460096, 56819712, 325877760, 189710336, 794304512, 21237760, 442374144, 586359808, 708095488, 621468416, 998643840, 343349440, 701142816, 178911888, 164274648, 447346308, 298492926, 1051328419 - ], - [ - 536870912, 268435456, 134217728, 603979776, 369098752, 620756992, 595591168, 616562688, 98566144, 544210944, 699924480, 737935360, 962199552, 807862272, 403210240, 739131392, 842047488, 858935296, 109750272, 124089344, 557465088, 630657280, 164674944, 37905856, 313692256, 156856752, 671098840, 872422220, 503319298, 16792235 - ], - [ - 536870912, 805306368, 939524096, 738197504, 369098752, 452984832, 243269632, 960495616, 228589568, 737148928, 450363392, 293339136, 700317696, 704577536, 1005355008, 315113472, 90578944, 327364608, 617789440, 779578368, 623556096, 834366208, 904697472, 365454656, 635831200, 499330288, 837991000, 667377468, 1020435614, 846680143 - ], - [ - 536870912, 268435456, 134217728, 469762048, 1040187392, 956301312, 276824064, 868220928, 614465536, 30408704, 732430336, 877395968, 919994368, 437583872, 53903360, 60735488, 945168384, 13963264, 1058441216, 764337152, 157163008, 206121216, 854104192, 806875072, 404667040, 336783568, 572527400, 118492044, 696788086, 593247941 - ], - [ - 536870912, 805306368, 402653184, 67108864, 100663296, 989855744, 377487360, 767557632, 1033895936, 326107136, 209190912, 752091136, 571342848, 219611136, 898400256, 1062518784, 376840192, 365113344, 159553536, 222544896, 863675904, 1012386560, 886353536, 640735680, 186647456, 246422640, 702022904, 1000619540, 678825774, 448989351 - ], - [ - 536870912, 805306368, 939524096, 201326592, 973078528, 922746880, 41943040, 171966464, 509607936, 407896064, 761790464, 350486528, 639500288, 84475904, 29065216, 1053409280, 423337984, 864677888, 1037801472, 765066240, 886284800, 372099840, 1025876096, 226541888, 81805024, 772806928, 822621064, 934559220, 871771542, 749548797 - ], - [ - 536870912, 805306368, 134217728, 67108864, 838860800, 922746880, 931135488, 868220928, 429916160, 183500800, 656932864, 263454720, 1073348608, 798162944, 267747328, 665632768, 198844416, 363016192, 1023248384, 573096960, 254284288, 1001654016, 100286336, 479410112, 175483808, 594345456, 637153448, 747834484, 41266778, 661447011 - ], - [ - 536870912, 805306368, 134217728, 469762048, 33554432, 83886080, 1048576000, 750780416, 1029701632, 101711872, 590872576, 764674048, 157155328, 673644544, 738951168, 169492480, 420323328, 1018785792, 702556160, 63974400, 718801408, 507779328, 730217600, 711141824, 93160416, 628714192, 570441304, 889199492, 914367078, 817895859 - ], - [ - 536870912, 268435456, 402653184, 738197504, 33554432, 922746880, 394264576, 1044381696, 434110464, 800063488, 38273024, 64225280, 882769920, 402456576, 179601408, 987217920, 103456768, 288018432, 379467776, 821902336, 87333376, 681040640, 499824000, 161143104, 55981664, 224996848, 675971496, 282785636, 355861334, 815336809 - ], - [ - 536870912, 805306368, 134217728, 67108864, 838860800, 385875968, 1015021568, 784334848, 920649728, 181403648, 886571008, 366739456, 208535552, 154730496, 765820928, 1065041920, 933601280, 477851648, 824551424, 565933056, 155556352, 313221888, 939370112, 593972672, 967544928, 894584592, 750265528, 382472908, 987105494, 1022700533 - ], - [ - 536870912, 268435456, 402653184, 603979776, 503316480, 50331648, 360710144, 213909504, 190840832, 1041235968, 319291392, 227278848, 684851200, 359596032, 1024557056, 109232128, 21651456, 599240704, 727713792, 772801536, 185075200, 697043200, 919734144, 376373440, 680625504, 172147504, 170549976, 497532804, 946343106, 597428067 - ], - [ - 536870912, 268435456, 939524096, 469762048, 234881024, 922746880, 377487360, 1010827264, 996147200, 386924544, 109576192, 73138176, 661520384, 420937728, 831750144, 316096512, 456138752, 577417216, 646449152, 341574656, 527306240, 85395200, 1066632064, 634867136, 229647776, 506117904, 501745368, 55312836, 434507682, 21693975 - ], - [ - 536870912, 805306368, 671088640, 67108864, 838860800, 184549376, 545259520, 666894336, 52428800, 915406848, 785907712, 11796480, 902955008, 941686784, 1040285696, 218775552, 832495616, 138809344, 913442816, 426839040, 1006209536, 1059995904, 412413056, 1003688640, 488734752, 194659824, 927394504, 217193636, 832573238, 709889773 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 973078528, 285212672, 662700032, 725614592, 576716800, 714080256, 114819072, 270794752, 325976064, 1024786432, 630489088, 239714304, 66494464, 718581760, 305530880, 913378304, 479887872, 634179328, 448409216, 632910912, 623813088, 183547600, 156762776, 929302948, 51252534, 981798729 - ], - [ - 536870912, 805306368, 939524096, 738197504, 1040187392, 318767104, 595591168, 423624704, 228589568, 11534336, 2621440, 49545216, 973209600, 151846912, 446464000, 1003569152, 443277312, 616706048, 937682944, 377895936, 902424064, 830420736, 727148928, 279147456, 136315232, 384828816, 671615496, 604244412, 705299458, 17367553 - ], - [ - 536870912, 268435456, 134217728, 201326592, 1040187392, 620756992, 796917760, 482344960, 526385152, 722468864, 310902784, 927203328, 832962560, 795803648, 856326144, 379305984, 88891392, 716615680, 635963392, 5506048, 355336704, 824902400, 321687424, 3459392, 111602656, 201160496, 759984088, 917946052, 333975202, 693373649 - ], - [ - 536870912, 268435456, 671088640, 335544320, 100663296, 50331648, 58720256, 465567744, 522190848, 691011584, 305659904, 766246912, 610664448, 1044709376, 401899520, 495796224, 885825536, 649408512, 602712064, 193278976, 534028800, 824783104, 1043506048, 397160896, 895886176, 953251632, 213025960, 452480380, 419440678, 43282967 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 436207616, 654311424, 192937984, 583008256, 27262976, 917504000, 623378432, 335282176, 876740608, 1073676288, 910458880, 217923584, 466493440, 320991232, 921053184, 215874560, 816062976, 673379072, 392209536, 555727552, 110003808, 642663024, 350268936, 266318812, 892241218, 201212963 - ], - [ - 536870912, 268435456, 671088640, 738197504, 503316480, 486539264, 729808896, 574619648, 652214272, 957349888, 159907840, 156499968, 1014366208, 786366464, 270958592, 1026670592, 784277504, 149975040, 470288384, 638845952, 420874752, 428804864, 558794624, 276154176, 817965792, 222001296, 381190584, 216713796, 772253794, 622508373 - ], - [ - 536870912, 805306368, 939524096, 469762048, 234881024, 486539264, 713031680, 977272832, 283115520, 1053818880, 129499136, 1017905152, 522584064, 636682240, 5537792, 402145280, 592879616, 409120768, 798132224, 1021004800, 481963520, 792131328, 501361536, 474676032, 435956896, 1045820816, 854499768, 365868020, 741641934, 577261051 - ], - [ - 536870912, 268435456, 134217728, 872415232, 973078528, 352321536, 964689920, 415236096, 694157312, 781189120, 407371776, 237240320, 69861376, 153419776, 213286912, 444252160, 471293952, 504705024, 654444544, 412156928, 458523136, 616287488, 1047260800, 773518656, 1057744480, 613085744, 356769880, 196014756, 317317778, 256638921 - ], - [ - 536870912, 268435456, 939524096, 603979776, 704643072, 16777216, 931135488, 331350016, 295698432, 762314752, 811073536, 7602176, 568197120, 615448576, 150568960, 110182400, 206774272, 510636032, 852666368, 909833216, 111642112, 100551936, 118137984, 277805376, 324636512, 987840688, 864757640, 702265004, 682404606, 1055260417 - ], - [ - 536870912, 805306368, 939524096, 201326592, 704643072, 1023410176, 494927872, 734003200, 517996544, 510656512, 405274624, 353632256, 427950080, 902758400, 99450880, 351617024, 325951488, 1033916416, 851945472, 763059200, 380118528, 4267776, 707267712, 336855104, 369230816, 789513904, 747473496, 474300972, 136685266, 486823977 - ], - [ - 536870912, 805306368, 939524096, 201326592, 771751936, 956301312, 276824064, 339738624, 228589568, 839909376, 521666560, 496762880, 650510336, 251068416, 372015104, 700465152, 460201984, 82628608, 85985280, 441453568, 79171072, 445383424, 123603840, 1043009088, 768246816, 23545104, 536519528, 44080260, 663760838, 232250215 - ], - [ - 536870912, 805306368, 402653184, 67108864, 771751936, 218103808, 159383552, 457179136, 782237696, 684720128, 1056440320, 519831552, 787087360, 921894912, 853573632, 485867520, 301604864, 409210880, 53118976, 764857344, 88253952, 1002295552, 625124224, 196992832, 1027779680, 264100816, 323137064, 45995124, 448964702, 436068143 - ], - [ - 536870912, 805306368, 402653184, 201326592, 301989888, 184549376, 629145600, 868220928, 929038336, 770703360, 363331584, 268697600, 672268288, 335740928, 504004608, 421412864, 781099008, 374378496, 78948352, 446143488, 944516608, 96132864, 939526784, 1006636480, 167775200, 117443888, 931135544, 952108364, 316670418, 506463117 - ], - [ - 536870912, 268435456, 671088640, 603979776, 301989888, 150994944, 192937984, 767557632, 757071872, 149946368, 299368448, 591134720, 536215552, 625147904, 510754816, 496451584, 650125312, 129626112, 179415040, 53392384, 267485696, 223825152, 979381888, 260700992, 801746528, 203603248, 662670248, 773342284, 119513534, 479310259 - ], - [ - 536870912, 268435456, 671088640, 872415232, 167772160, 218103808, 159383552, 180355072, 522190848, 315621376, 321388544, 79953920, 540147712, 172032000, 779386880, 371572736, 692183040, 150097920, 745834496, 1059439616, 46262784, 993156352, 819235456, 708167488, 122284128, 669409200, 485395784, 912311284, 438791338, 1061592705 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 33554432, 822083584, 796917760, 801112064, 98566144, 682622976, 1058537472, 614203392, 625606656, 1002373120, 831094784, 214384640, 863248384, 351997952, 388999168, 954160128, 494404096, 267127552, 900860544, 982713152, 106662752, 220481456, 232237720, 619925980, 791283390, 751765259 - ], - [ - 536870912, 268435456, 134217728, 738197504, 570425344, 788529152, 629145600, 46137344, 1033895936, 328204288, 1002962944, 824442880, 365297664, 741933056, 390299648, 661438464, 170156032, 642207744, 132515840, 778634240, 514556416, 68733696, 503998592, 84564928, 646676832, 88655024, 274885992, 197025764, 713395826, 928367497 - ], - [ - 536870912, 268435456, 402653184, 201326592, 704643072, 117440512, 75497472, 20971520, 597688320, 292552704, 1058537472, 411303936, 860487680, 682819584, 1072070656, 962183168, 1067900928, 594243584, 873621504, 906343424, 890768896, 260310784, 801770624, 636682944, 910592928, 791265680, 71231944, 984577036, 620261166, 264681085 - ], - [ - 536870912, 268435456, 671088640, 872415232, 838860800, 1056964608, 310378496, 759169024, 631242752, 1001390080, 985137152, 959184896, 1073086464, 680460288, 910196736, 757186560, 502489088, 1066643456, 282290176, 845394944, 122380800, 381663488, 119893632, 787265216, 51112480, 77495696, 139854664, 1010762620, 913868262, 223201591 - ], - [ - 536870912, 268435456, 671088640, 469762048, 637534208, 1056964608, 847249408, 943718400, 652214272, 447741952, 1045954560, 167510016, 2752512, 436535296, 152076288, 631029760, 383279104, 950259712, 55109632, 377426944, 267420160, 791462656, 8414080, 761256128, 627240224, 863638992, 878708504, 854592444, 817366446, 256642067 - ], - [ - 536870912, 268435456, 939524096, 469762048, 234881024, 956301312, 1015021568, 532676608, 1008730112, 393216000, 9961472, 30670848, 1026686976, 939065344, 289636352, 83279872, 382967808, 682684416, 748824576, 784282624, 565315072, 943260416, 358845824, 260491584, 407612576, 275052976, 756033576, 109458988, 215058734, 733988521 - ], - [ - 536870912, 805306368, 402653184, 738197504, 771751936, 922746880, 528482304, 314572800, 908066816, 581959680, 703070208, 235143168, 117571584, 126681088, 1054507008, 404963328, 363667456, 913682432, 482813952, 826063872, 624930304, 388167424, 371197312, 313526976, 837290592, 570688112, 687997416, 814547420, 559579154, 182669213 - ], - [ - 536870912, 268435456, 671088640, 872415232, 33554432, 1056964608, 377487360, 926941184, 157286400, 435159040, 733478912, 390856704, 426115072, 838795264, 532447232, 358203392, 644440064, 661344256, 686778368, 472142848, 1066131968, 214014208, 1069318784, 89769664, 241790752, 325803792, 720334712, 589582444, 688647958, 998348671 - ], - [ - 536870912, 805306368, 939524096, 469762048, 838860800, 520093696, 8388608, 683671552, 287309824, 730857472, 240648192, 821821440, 188612608, 546373632, 415989760, 691159040, 932405248, 1011224576, 803604480, 195890176, 139824640, 166938368, 44100736, 970479552, 213084192, 618010160, 725484104, 277938660, 550207766, 892488959 - ], - [ - 536870912, 268435456, 134217728, 469762048, 905969664, 318767104, 209715200, 432013312, 547356672, 1072693248, 865599488, 994836480, 1047134208, 969211904, 817528832, 939245568, 798793728, 223064064, 762062848, 893744128, 695339520, 390660864, 275812224, 1053737920, 373173920, 188510896, 280658696, 670813580, 664577742, 290174511 - ], - [ - 536870912, 268435456, 939524096, 67108864, 436207616, 922746880, 612368384, 1044381696, 367001600, 321912832, 915931136, 626262016, 394133504, 75431936, 720273408, 464371712, 785080320, 430886912, 232515584, 524030976, 10356224, 877593856, 452364416, 867814592, 315977632, 128045648, 550331480, 213245788, 441675486, 536533145 - ], - [ - 536870912, 805306368, 939524096, 469762048, 838860800, 385875968, 360710144, 432013312, 85983232, 944766976, 989331456, 1013710848, 774242304, 801964032, 203522048, 819052544, 1034444800, 118935552, 495421440, 1037880320, 724168192, 492246784, 947381376, 808851904, 852517728, 314236272, 243370952, 910278868, 804284766, 116054955 - ], - [ - 536870912, 268435456, 939524096, 201326592, 973078528, 150994944, 343932928, 54525952, 1021313024, 728760320, 498597888, 42205184, 542244864, 426180608, 816807936, 403423232, 471556096, 34574336, 85026816, 782013440, 173336064, 678713088, 674367616, 559351104, 704087456, 1040171408, 468804760, 283940940, 23913846, 749756077 - ], - [ - 536870912, 268435456, 134217728, 603979776, 838860800, 318767104, 159383552, 952107008, 85983232, 808452096, 12058624, 251396096, 747503616, 4653056, 795246592, 542523392, 1063264256, 675786752, 460859392, 441168896, 141437440, 331398400, 817800832, 384694720, 9831648, 374015984, 242257320, 987582460, 238071686, 363525443 - ], - [ - 536870912, 268435456, 671088640, 738197504, 838860800, 251658240, 461373440, 448790528, 807403520, 762314752, 228065280, 467402752, 1050804224, 255787008, 249987072, 323371008, 904568832, 786329600, 372123648, 342307840, 117572096, 663686912, 14583424, 321538240, 82881120, 407729520, 812819176, 151157228, 848047470, 945304235 - ], - [ - 536870912, 805306368, 939524096, 469762048, 771751936, 117440512, 293601280, 272629760, 140509184, 770703360, 128450560, 47448064, 195690496, 617938944, 681738240, 122699776, 301293568, 432001024, 1038051328, 103472128, 446555648, 667589376, 991989120, 101796544, 320725472, 462066384, 624985592, 820069036, 724953490, 236886233 - ], - [ - 536870912, 268435456, 402653184, 335544320, 503316480, 285212672, 494927872, 490733568, 564133888, 1049624576, 197656576, 913047552, 452591616, 171376640, 786202624, 635486208, 246915072, 570773504, 319948800, 512427008, 466519552, 778814720, 251209600, 338596928, 1070280544, 947229520, 334341736, 60972708, 763792242, 357026011 - ], - [ - 536870912, 268435456, 671088640, 872415232, 301989888, 452984832, 411041792, 884998144, 195035136, 827326464, 1055391744, 631504896, 474087424, 125108224, 653492224, 698826752, 307421184, 979505152, 930711552, 518407168, 900426240, 876895488, 863169664, 888279744, 850494496, 181552176, 245460072, 1019565972, 799761690, 189027993 - ], - [ - 536870912, 805306368, 134217728, 67108864, 704643072, 754974720, 226492416, 834666496, 908066816, 141557760, 378011648, 123469824, 23461888, 17235968, 328957952, 1054097408, 314318848, 505868288, 1013032960, 881179648, 776866304, 652938496, 500533376, 675236416, 124365280, 840546096, 285738728, 731644524, 851839530, 1018626763 - ], - [ - 536870912, 805306368, 402653184, 201326592, 369098752, 83886080, 629145600, 12582912, 291504128, 30408704, 116916224, 102498304, 756940800, 830930944, 449085440, 41533440, 559079424, 597848064, 398231552, 1034275840, 917300736, 439710464, 694160768, 1037045056, 150474592, 253494064, 513671640, 877068596, 774146270, 57262519 - ], - [ - 536870912, 268435456, 134217728, 201326592, 838860800, 486539264, 998244352, 46137344, 769654784, 416284672, 753401856, 424935424, 1059979264, 1026359296, 942702592, 129548288, 997580800, 965226496, 131106816, 308855808, 605938176, 773600000, 656311424, 714457920, 189099232, 842068912, 245723128, 920712564, 407728090, 1052045797 - ], - [ - 536870912, 268435456, 134217728, 469762048, 570425344, 956301312, 327155712, 524288000, 618659840, 240123904, 996671488, 991166464, 981860352, 81068032, 666009600, 145276928, 204152832, 333950976, 517638144, 448578560, 757932544, 343062272, 1065877632, 625216064, 166594272, 599851216, 1060405688, 897437140, 941206074, 68122901 - ], - [ - 536870912, 805306368, 134217728, 738197504, 503316480, 50331648, 847249408, 465567744, 597688320, 47185920, 272105472, 1049886720, 902692864, 682295296, 474447872, 367935488, 507011072, 93753344, 593463296, 23743488, 586048000, 649698048, 659427200, 57347264, 937922208, 993938928, 268463976, 939692148, 605126830, 838944085 - ], - [ - 536870912, 268435456, 671088640, 201326592, 704643072, 687865856, 293601280, 583008256, 136314880, 944766976, 241696768, 19136512, 970850304, 78184448, 85360640, 731103232, 600104960, 364793856, 813729792, 793691136, 686057984, 358650624, 229433984, 77225536, 559842912, 669503408, 133358216, 401823572, 1072170362, 870581945 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 167772160, 184549376, 142606336, 968884224, 622854144, 426770432, 337117184, 638320640, 152698880, 1067122688, 994082816, 400670720, 885563392, 883322880, 388638720, 912307200, 578816512, 583011072, 631242880, 481299904, 993525920, 880544944, 360844136, 542574636, 393907278, 822792159 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 973078528, 83886080, 494927872, 859832320, 778043392, 418381824, 1027080192, 647233536, 1037697024, 665780224, 558989312, 528039936, 459923456, 224808960, 711714816, 250434560, 439905792, 35592960, 687997056, 1066076736, 173248480, 166871696, 783966840, 248781740, 221350838, 780748617 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 436207616, 754974720, 511705088, 750780416, 622854144, 389021696, 372768768, 448528384, 660733952, 114229248, 271155200, 1035911168, 484745216, 143405056, 63219712, 582759424, 58501632, 683686656, 457092224, 339685440, 61811488, 536738672, 487162472, 110022332, 417116134, 53492755 - ], - [ - 536870912, 805306368, 939524096, 67108864, 704643072, 788529152, 260046848, 826277888, 174063616, 240123904, 234356736, 51118080, 697958400, 139001856, 83197952, 897761280, 374808576, 973008896, 286099456, 42912768, 768421376, 448262400, 813171328, 692848576, 1048186336, 475598160, 653101080, 647940180, 936714398, 229375123 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 234881024, 486539264, 545259520, 633339904, 1025507328, 1053818880, 347602944, 295436288, 591790080, 569049088, 291536896, 482295808, 93872128, 155504640, 251168768, 586370048, 82208256, 1039392512, 796789632, 431426368, 419860000, 579094128, 784395464, 1017616628, 898032910, 290230551 - ], - [ - 536870912, 805306368, 402653184, 67108864, 1040187392, 654311424, 612368384, 926941184, 882900992, 586153984, 566755328, 921960448, 937295872, 233111552, 693141504, 599506944, 510320640, 311980032, 1012033536, 841464832, 145657344, 686738688, 550660480, 828881088, 437161632, 689883152, 463102472, 399750252, 1039172314, 827048129 - ], - [ - 536870912, 805306368, 939524096, 872415232, 100663296, 184549376, 109051904, 675282944, 681574400, 426770432, 336068608, 906756096, 856555520, 848101376, 776044544, 597868544, 535928832, 1010962432, 514205696, 712530944, 645923328, 406848256, 278922112, 762315584, 302514272, 1024196784, 898498664, 449643140, 115442314, 986890647 - ], - [ - 536870912, 268435456, 939524096, 469762048, 503316480, 285212672, 780140544, 910163968, 799014912, 36700160, 373817344, 1067712512, 977141760, 172949504, 564363264, 725237760, 616865792, 401477632, 76654592, 653536256, 27492864, 993673472, 482648960, 200151488, 445753824, 938749200, 790855912, 226116196, 862232954, 165548515 - ], - [ - 536870912, 805306368, 134217728, 335544320, 503316480, 385875968, 427819008, 20971520, 572522496, 198180864, 505937920, 836501504, 522846208, 727252992, 434995200, 524075008, 698081280, 193236992, 608659456, 782263296, 236708352, 767857408, 401041536, 808478016, 739501024, 13144688, 258304280, 737502548, 150233538, 1065177805 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 704643072, 117440512, 645922816, 1010827264, 106954752, 934281216, 841482240, 500432896, 127008768, 351469568, 382500864, 673234944, 584458240, 890458112, 1052735488, 1034722304, 1041932800, 171151616, 317282944, 150982592, 751163552, 120524144, 945552104, 592993540, 1071546950, 747880907 - ], - [ - 536870912, 268435456, 134217728, 335544320, 100663296, 251658240, 260046848, 658505728, 899678208, 34603008, 578289664, 604766208, 503709696, 319225856, 495222784, 776093696, 891297792, 718942208, 815577088, 330427392, 1046878720, 359832832, 662700672, 591396928, 1000341728, 420479408, 737673368, 206307972, 606471074, 911671893 - ], - [ - 536870912, 268435456, 671088640, 469762048, 704643072, 83886080, 578813952, 272629760, 35651584, 238026752, 432537600, 1004797952, 635043840, 337575936, 871792640, 1009205248, 758226944, 1011585024, 271075328, 1060826112, 222593536, 78397696, 7676544, 686281152, 945646240, 199048272, 521791528, 175209476, 1038928034, 852929571 - ], - [ - 536870912, 268435456, 939524096, 201326592, 436207616, 16777216, 528482304, 121634816, 1054867456, 663748608, 445120512, 650379264, 380502016, 301137920, 1054769152, 460079104, 836624384, 65327104, 169752576, 684270592, 296092160, 762773760, 722502528, 659505344, 787177888, 530354192, 377870840, 1019933812, 396409326, 242575225 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 33554432, 452984832, 327155712, 171966464, 891289600, 686817280, 781713408, 197394432, 208273408, 710475776, 841449472, 159006720, 668737536, 292384768, 752179200, 719369216, 43448832, 566462208, 862815104, 131285184, 560177568, 886256240, 384006424, 9749780, 985931882, 552169771 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 369098752, 83886080, 343932928, 843055104, 861929472, 309329920, 26738688, 464257024, 308150272, 906821632, 353271808, 1015988224, 239820800, 627847168, 393283584, 353723392, 702835200, 557077760, 612098176, 346026688, 657255392, 471570320, 325059112, 40895092, 697827582, 665584067 - ], - [ - 536870912, 268435456, 671088640, 738197504, 436207616, 251658240, 679477248, 717225984, 996147200, 554696704, 329777152, 24379392, 70385664, 18284544, 60850176, 695648256, 674603008, 454619136, 212318208, 33428480, 49619456, 545140992, 767171200, 307422912, 58760096, 608642544, 749189640, 301864300, 720708246, 209596705 - ], - [ - 536870912, 268435456, 402653184, 603979776, 436207616, 318767104, 880803840, 759169024, 790626304, 445644800, 736624640, 762576896, 681443328, 350552064, 1072988160, 684965888, 105816064, 799739904, 903686144, 868701184, 426516992, 1027199232, 573639040, 549357120, 956115872, 240604208, 67379400, 168677780, 185535186, 277579481 - ], - [ - 536870912, 268435456, 939524096, 872415232, 369098752, 989855744, 427819008, 46137344, 794820608, 250609664, 347602944, 698089472, 104988672, 656867328, 920027136, 367935488, 834215936, 387846144, 118228992, 327635968, 599820800, 803345664, 951396736, 463029824, 323780832, 832913904, 999662456, 55267548, 161589774, 261097331 - ], - [ - 536870912, 268435456, 939524096, 872415232, 301989888, 1056964608, 411041792, 1044381696, 748683264, 972029952, 369623040, 84148224, 730726400, 13434880, 1071939584, 853524480, 155066368, 31690752, 1003563008, 79002624, 740295168, 598737152, 279446400, 938738496, 923140384, 76088304, 541753736, 899859428, 208839370, 264786847 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 234881024, 251658240, 243269632, 113246208, 526385152, 1020264448, 345505792, 490471424, 915275776, 583598080, 627998720, 31408128, 454811648, 444452864, 564905984, 128998400, 306924032, 883301632, 608053888, 319065792, 277742176, 29950512, 770605192, 874464092, 83616254, 795726673 - ], - [ - 536870912, 268435456, 402653184, 738197504, 436207616, 50331648, 981467136, 784334848, 123731968, 946864128, 879230976, 183762944, 783155200, 1000275968, 265846784, 913817600, 291643392, 829583360, 367851520, 851241984, 487203328, 126251264, 960690560, 639889088, 844276640, 473018672, 364960296, 31562796, 347495382, 470376119 - ], - [ - 536870912, 268435456, 134217728, 469762048, 369098752, 385875968, 343932928, 801112064, 731906048, 254803968, 808976384, 683409408, 427687936, 970522624, 879525888, 1016152064, 721969152, 311267328, 818313216, 589640704, 922647040, 211367168, 855669376, 109065408, 986512352, 572618160, 897358504, 936437580, 929357842, 572314559 - ], - [ - 536870912, 268435456, 671088640, 469762048, 301989888, 318767104, 947912704, 901775360, 379584512, 254803968, 933756928, 884211712, 316801024, 198377472, 427196416, 542097408, 585408512, 869576704, 762316800, 776141824, 602710528, 407941376, 540674688, 220593600, 980951840, 550268976, 589834504, 729714332, 592218698, 845823171 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 234881024, 687865856, 595591168, 935329792, 559939584, 1009778688, 42467328, 407633920, 816447488, 140443648, 322666496, 68042752, 705617920, 856223744, 948230144, 860277760, 471990784, 152240896, 672236160, 126960576, 374694112, 574010000, 864172600, 801259388, 896325654, 238734531 - ], - [ - 536870912, 805306368, 134217728, 738197504, 167772160, 1023410176, 142606336, 1069547520, 761266176, 485490688, 116916224, 66322432, 796262400, 918355968, 752844800, 94420992, 874176512, 625020928, 1001146368, 387871744, 1053575680, 401504000, 976505472, 85620160, 398608928, 828864016, 519948968, 402109932, 25110654, 766682147 - ], - [ - 536870912, 268435456, 671088640, 335544320, 704643072, 150994944, 478150656, 448790528, 748683264, 141557760, 620232704, 104595456, 378929152, 551747584, 655458304, 883933184, 612294656, 855330816, 825358336, 689185792, 799537664, 234300672, 179730560, 609805376, 407411232, 90420432, 425288680, 1053266300, 1051106082, 1031582971 - ], - [ - 536870912, 805306368, 134217728, 469762048, 1040187392, 956301312, 75497472, 1035993088, 18874368, 588251136, 263716864, 769916928, 180224000, 661454848, 108298240, 1053540352, 648306688, 156487680, 752777216, 831663104, 662444544, 508100352, 828957312, 326898368, 205790048, 1047330384, 855040424, 184619852, 998807770, 339950637 - ], - [ - 536870912, 268435456, 134217728, 603979776, 301989888, 956301312, 226492416, 440401920, 622854144, 592445440, 811073536, 953942016, 287178752, 561446912, 25395200, 1011204096, 102932480, 869675008, 899577856, 1052126208, 451312128, 674901248, 740326016, 919678784, 102628256, 737406160, 423943032, 632036724, 782106922, 305595201 - ], - [ - 536870912, 268435456, 402653184, 469762048, 1040187392, 419430400, 25165824, 264241152, 954204160, 544210944, 396886016, 450101248, 654180352, 283836416, 880640000, 766459904, 568123392, 7614464, 128129024, 47582208, 989291008, 786723072, 763132288, 740720064, 773134816, 949554320, 668787608, 359936060, 539171310, 135663191 - ], - [ - 536870912, 268435456, 402653184, 335544320, 973078528, 553648128, 25165824, 809500672, 673185792, 357564416, 522715136, 198443008, 770572288, 657522688, 458260480, 337723392, 861724672, 137318400, 89516032, 119636992, 534045184, 401297664, 104065408, 450135360, 610427296, 461312784, 494504344, 444569156, 217443106, 842106437 - ], - [ - 536870912, 805306368, 939524096, 872415232, 167772160, 50331648, 964689920, 272629760, 354418688, 479199232, 187170816, 630980608, 161873920, 944832512, 113541120, 853655552, 687005696, 202493952, 300787712, 561116160, 609411584, 818008832, 937798528, 746452800, 752673440, 772592432, 17246232, 915224132, 399148018, 208454393 - ], - [ - 536870912, 268435456, 671088640, 335544320, 570425344, 788529152, 411041792, 734003200, 568328192, 667942912, 994574336, 237240320, 205127680, 664600576, 266633216, 114671616, 314646528, 610496512, 328284160, 1038685184, 31359488, 508084480, 765829760, 494317888, 45095456, 291137264, 830978952, 105240508, 27337374, 57897533 - ], - [ - 536870912, 805306368, 939524096, 201326592, 704643072, 352321536, 679477248, 725614592, 589299712, 944766976, 198705152, 856948736, 419037184, 860422144, 522944512, 710066176, 316596224, 832253952, 649558016, 955198464, 204831232, 44183296, 429717888, 582873024, 652974880, 1060707984, 355172776, 257081380, 39772570, 383463585 - ], - [ - 536870912, 805306368, 134217728, 335544320, 905969664, 16777216, 679477248, 759169024, 320864256, 9437184, 829947904, 503578624, 621674496, 377946112, 944275456, 229490688, 752508928, 182022144, 870029312, 122874880, 136280576, 741695232, 85983872, 831521344, 301466592, 658768208, 3015144, 387384004, 565216186, 1055507165 - ], - [ - 536870912, 268435456, 134217728, 603979776, 570425344, 989855744, 394264576, 96468992, 538968064, 435159040, 609746944, 929824768, 244711424, 985858048, 94732288, 791953408, 939139072, 156241920, 837400576, 64263168, 715495936, 45581568, 624009856, 955994944, 886577824, 724551152, 377323864, 228082412, 290202618, 241374083 - ], - [ - 536870912, 268435456, 402653184, 335544320, 973078528, 654311424, 8388608, 297795584, 1042284544, 225443840, 749207552, 666107904, 604897280, 838926336, 721977344, 780976128, 214867968, 430813184, 473933824, 55520256, 350265856, 98349312, 958343552, 683142464, 947913120, 364905328, 471859592, 1047527516, 371720258, 292815527 - ], - [ - 536870912, 268435456, 134217728, 603979776, 301989888, 754974720, 578813952, 725614592, 778043392, 1018167296, 422051840, 1020526592, 916062208, 477429760, 1015709696, 541343744, 1005002752, 1014763520, 746911744, 675421184, 535667200, 779636992, 25417856, 181276224, 882989856, 1986512, 1027373224, 333929972, 142213446, 914686555 - ], - [ - 536870912, 268435456, 134217728, 738197504, 503316480, 654311424, 1048576000, 633339904, 895483904, 1032847360, 691535872, 63700992, 644218880, 957939712, 435453952, 824328192, 665870336, 1040699392, 923576320, 915307520, 164121088, 728493312, 445940352, 397558720, 638083424, 319541424, 76196360, 818379820, 853854910, 30780549 - ], - [ - 536870912, 268435456, 671088640, 738197504, 503316480, 889192448, 729808896, 549453824, 698351616, 357564416, 469237760, 506200064, 329121792, 56164352, 317751296, 61652992, 710057984, 528240640, 309303296, 443620352, 31799808, 1051806976, 441229440, 15029184, 524229472, 361618832, 97491288, 706813020, 429734050, 744311961 - ], - [ - 536870912, 805306368, 939524096, 67108864, 570425344, 486539264, 1065353216, 557842432, 413138944, 745537536, 734527488, 174850048, 194904064, 605618176, 224165888, 704462848, 595910656, 927191040, 531032064, 184171520, 386564608, 780681984, 13001600, 48730176, 878610976, 74755536, 666929656, 342732052, 815532042, 613477767 - ], - [ - 536870912, 268435456, 402653184, 201326592, 905969664, 452984832, 578813952, 666894336, 954204160, 953155584, 999817216, 935067648, 17432576, 528547840, 105414656, 833110016, 301195264, 548376576, 377186304, 719846400, 299493888, 538885376, 335186816, 296054208, 33030368, 950796400, 443678920, 485294860, 182092486, 43335745 - ], - [ - 536870912, 805306368, 402653184, 201326592, 436207616, 1056964608, 578813952, 935329792, 668991488, 540016640, 79167488, 1047789568, 269615104, 861995008, 50298880, 651444224, 117891072, 512102400, 902195200, 350299136, 414476800, 208676608, 991161216, 132147136, 272566816, 481522736, 846520328, 169284428, 207743094, 544302671 - ], - [ - 536870912, 805306368, 671088640, 603979776, 100663296, 989855744, 729808896, 893386752, 308281344, 1039138816, 1008205824, 144965632, 752222208, 9109504, 113541120, 723861504, 228401152, 1022242816, 607848448, 984810496, 191900160, 701904640, 739221632, 302018880, 352496352, 881358320, 416153816, 472843236, 68321566, 883835595 - ], - [ - 536870912, 805306368, 134217728, 67108864, 100663296, 184549376, 343932928, 415236096, 266338304, 1022361600, 756547584, 652476416, 360579072, 576389120, 558137344, 950878208, 928309248, 46895104, 1055557632, 695804928, 677276160, 675460864, 556589696, 807375680, 23890144, 355869936, 930933544, 525399612, 918717238, 820134147 - ], - [ - 536870912, 268435456, 939524096, 201326592, 637534208, 956301312, 645922816, 482344960, 253755392, 974127104, 1073217536, 466354176, 212467712, 509411328, 420642816, 779862016, 746971136, 331845632, 681605120, 207195136, 169286144, 401988864, 801800576, 648528320, 22536672, 110531408, 339277832, 1064259164, 653818010, 759533421 - ], - [ - 536870912, 268435456, 134217728, 738197504, 369098752, 486539264, 679477248, 79691776, 387973120, 747634688, 270008320, 920387584, 251527168, 769982464, 448299008, 168017920, 319283200, 294375424, 373463040, 417364992, 238852608, 281378048, 891558528, 60211136, 530316256, 294743568, 681533800, 974656092, 903707162, 393719189 - ], - [ - 536870912, 268435456, 939524096, 67108864, 436207616, 50331648, 562036736, 62914560, 509607936, 974127104, 875036672, 196345856, 911605760, 411893760, 827097088, 70238208, 599777280, 173977600, 109262848, 676074496, 648372736, 33321216, 401628032, 587031616, 645512096, 423548208, 1008599960, 958988668, 187859910, 320259025 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 234881024, 721420288, 763363328, 566231040, 559939584, 326107136, 941096960, 40108032, 721027072, 869335040, 973635584, 822296576, 747151360, 357535744, 136931328, 358425600, 104974848, 698529536, 579904384, 808161472, 424896864, 273425776, 1051281464, 17954732, 987759438, 363856875 - ], - [ - 536870912, 805306368, 134217728, 335544320, 637534208, 520093696, 696254464, 406847488, 6291456, 1051721728, 264765440, 724303872, 760348672, 71106560, 873299968, 369737728, 386752512, 1032491008, 1045321728, 526519296, 390038016, 394576640, 726196352, 334451008, 200358496, 522558960, 995383448, 322113156, 159384198, 675283371 - ], - [ - 536870912, 268435456, 671088640, 335544320, 301989888, 721420288, 209715200, 71303168, 991952896, 651165696, 930611200, 1022099456, 1061027840, 969342976, 484802560, 791953408, 298115072, 149073920, 1027545088, 986274816, 73792000, 964488448, 31940736, 582873152, 234912672, 1023979504, 495158248, 936330228, 568812026, 851309417 - ], - [ - 536870912, 268435456, 402653184, 335544320, 704643072, 251658240, 964689920, 549453824, 463470592, 395313152, 710410240, 58458112, 1068105728, 899088384, 693207040, 82853888, 980230144, 414355456, 662779904, 365132800, 891861504, 450837760, 993500032, 4631616, 1005396256, 1014141104, 237058232, 424902588, 217102978, 912473733 - ], - [ - 536870912, 268435456, 671088640, 335544320, 436207616, 1056964608, 629145600, 146800640, 379584512, 103809024, 673710080, 158597120, 893517824, 845217792, 916226048, 521322496, 567533568, 779874304, 1020250112, 481180672, 289006080, 430895360, 464603776, 485358912, 299795360, 376685296, 13590744, 313078220, 876357834, 52809619 - ], - [ - 536870912, 268435456, 671088640, 603979776, 905969664, 721420288, 427819008, 423624704, 39845888, 1072693248, 117964800, 461635584, 743047168, 350814208, 155025408, 925024256, 1066557440, 234115072, 168138752, 17595392, 143131136, 969146624, 531235456, 374932032, 978682720, 945210032, 223371672, 467227028, 756160550, 490192895 - ], - [ - 536870912, 268435456, 402653184, 738197504, 1040187392, 687865856, 729808896, 876609536, 287309824, 1047527424, 745013248, 349437952, 1046347776, 93782016, 720732160, 1051410432, 272392192, 508416000, 975464448, 452701184, 916578816, 607293696, 205916544, 757169856, 409995744, 694321040, 22776120, 589184132, 1060268402, 550022839 - ], - [ - 536870912, 805306368, 939524096, 872415232, 100663296, 754974720, 293601280, 356515840, 90177536, 158334976, 446169088, 941883392, 806486016, 434831360, 1034977280, 851230720, 3547136, 637186048, 374884352, 604103680, 235170304, 553932544, 596025728, 1044803648, 971926496, 230380944, 180102008, 875933828, 603638478, 995501699 - ], - [ - 536870912, 268435456, 134217728, 201326592, 167772160, 452984832, 276824064, 557842432, 933232640, 829423616, 795344896, 940834816, 377094144, 770637824, 106201088, 929021952, 752459776, 353505280, 267520000, 53455872, 104800768, 29806848, 250423424, 47807680, 404359840, 108768432, 635773832, 173659092, 1028762458, 936558183 - ], - [ - 536870912, 805306368, 402653184, 67108864, 369098752, 117440512, 629145600, 633339904, 1004535808, 800063488, 1060634624, 510918656, 986841088, 717422592, 846102528, 7553024, 299114496, 88100864, 44378112, 252838912, 959392256, 30738176, 759933824, 513886016, 488311520, 673535792, 592871608, 755450220, 8790278, 155406487 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 637534208, 1056964608, 964689920, 432013312, 836763648, 407896064, 692584448, 380370944, 1039269888, 53936128, 257785856, 482983936, 560947200, 252899328, 82655232, 13775872, 34046464, 486720256, 344514688, 88093632, 145611360, 922617840, 548952472, 261867164, 732248478, 427701573 - ], - [ - 536870912, 268435456, 939524096, 738197504, 234881024, 721420288, 964689920, 926941184, 10485760, 103809024, 587726848, 1032060928, 760086528, 162201600, 447971328, 113426432, 870998016, 479449088, 741550080, 34475008, 889717248, 713294080, 583926656, 971702976, 764641504, 481477296, 700605336, 275239796, 584394762, 806423651 - ], - [ - 536870912, 268435456, 671088640, 603979776, 436207616, 251658240, 109051904, 180355072, 1059061760, 923795456, 657981440, 111935488, 56492032, 517668864, 814972928, 108216320, 919429120, 958566400, 773535744, 280488960, 535714304, 1060732160, 447438976, 357929792, 802601760, 589278896, 87079880, 94940508, 1004354330, 17886365 - ], - [ - 536870912, 268435456, 402653184, 469762048, 503316480, 117440512, 511705088, 490733568, 547356672, 1051721728, 414711808, 331087872, 188350464, 226295808, 760905728, 162217984, 791994368, 528461824, 743806976, 204157952, 854956544, 630928640, 751672192, 929510592, 425171552, 61486256, 842341256, 83719524, 916191618, 676316815 - ], - [ - 536870912, 268435456, 134217728, 872415232, 33554432, 117440512, 511705088, 289406976, 492830720, 433061888, 870842368, 278134784, 311033856, 1061748736, 610435072, 912048128, 959389696, 87134208, 435877888, 424879104, 61153792, 511217920, 932739200, 470804288, 638190112, 218694000, 763527528, 231522900, 187113974, 439718381 - ], - [ - 536870912, 268435456, 134217728, 738197504, 100663296, 385875968, 914358272, 767557632, 429916160, 686817280, 565706752, 819724288, 34471936, 755826688, 797474816, 542064640, 82436096, 194187264, 644397056, 340993024, 181287424, 924935424, 557275776, 303118272, 153092832, 36700848, 110625672, 434897260, 1008075410, 572588323 - ], - [ - 536870912, 268435456, 134217728, 469762048, 369098752, 654311424, 713031680, 71303168, 673185792, 883949568, 139984896, 965476352, 885391360, 358940672, 219316224, 69484544, 985096192, 995209216, 419436544, 25469952, 818149888, 392451328, 538837632, 531169472, 863273440, 1035027376, 31318984, 357167668, 900298794, 310122255 - ], - [ - 536870912, 805306368, 671088640, 738197504, 369098752, 587202560, 343932928, 121634816, 895483904, 435159040, 314048512, 30670848, 321781760, 958201856, 697073664, 751452160, 413294592, 618082304, 1017391104, 786314240, 564701696, 894727936, 610977920, 611534272, 477553120, 679048176, 980437672, 594543748, 49676670, 842596571 - ], - [ - 536870912, 268435456, 402653184, 335544320, 771751936, 16777216, 595591168, 792723456, 429916160, 118489088, 189267968, 1067712512, 169213952, 315424768, 1072660480, 825638912, 420864000, 38555648, 270804992, 526001152, 611287552, 443957504, 917889408, 274485568, 384576224, 247342096, 341409848, 552289268, 464674842, 433983793 - ], - [ - 536870912, 805306368, 134217728, 738197504, 704643072, 687865856, 25165824, 1027604480, 954204160, 110100480, 732430336, 671350784, 470155264, 570490880, 84246528, 730152960, 340074496, 962605056, 1003988992, 323951616, 781505024, 933983488, 167772288, 419430592, 159383584, 289407152, 316670120, 797966500, 707264518, 356778229 - ], - [ - 536870912, 805306368, 134217728, 67108864, 570425344, 989855744, 427819008, 1027604480, 564133888, 854589440, 391643136, 317980672, 660471808, 452263936, 593395712, 955334656, 408543232, 561147904, 622741504, 14042112, 401085952, 395095808, 85870720, 819348672, 535303712, 327986960, 656295944, 198591532, 107484742, 785166309 - ], - [ - 536870912, 268435456, 402653184, 67108864, 905969664, 553648128, 830472192, 901775360, 773849088, 401604608, 680001536, 925106176, 846331904, 860553216, 1006927872, 570736640, 252125184, 344371200, 843085824, 987882496, 139775488, 180070656, 831463552, 312651840, 699562080, 946529296, 745557720, 508520836, 662700102, 79691927 - ], - [ - 536870912, 268435456, 134217728, 603979776, 100663296, 285212672, 243269632, 12582912, 106954752, 26214400, 284688384, 185860096, 104464384, 343212032, 758022144, 38649856, 827891712, 191238144, 890615808, 725376000, 821185024, 518775552, 498055296, 797531200, 331139616, 959849360, 974067864, 1056656388, 773026330, 113213331 - ], - [ - 536870912, 268435456, 671088640, 67108864, 234881024, 922746880, 394264576, 171966464, 60817408, 600834048, 978845696, 105119744, 430047232, 852819968, 517505024, 361086976, 658825216, 86503424, 219269120, 708424704, 460757504, 336575232, 660111488, 952483904, 459595936, 683143184, 988399672, 950908124, 789355102, 719239977 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 167772160, 352321536, 209715200, 767557632, 463470592, 458227712, 566755328, 720633856, 530448384, 532611072, 615350272, 293617664, 893394944, 409227264, 603052032, 689505280, 1064952320, 260662528, 756152448, 439178432, 624966240, 811885040, 133569192, 521875860, 545014482, 369718663 - ], - [ - 536870912, 268435456, 134217728, 872415232, 436207616, 822083584, 411041792, 994050048, 174063616, 30408704, 375914496, 755236864, 646053888, 406913024, 400982016, 940785664, 374218752, 1043795968, 175990784, 692866048, 498121216, 280661248, 887619712, 927203392, 1013055520, 382795984, 300843112, 633815236, 1042554978, 808587501 - ], - [ - 536870912, 268435456, 402653184, 872415232, 973078528, 721420288, 746586112, 205520896, 1059061760, 986710016, 815267840, 158597120, 369754112, 516882432, 296255488, 39469056, 756473856, 696078336, 1036134400, 719639552, 741499392, 179179264, 652134528, 223773760, 408472160, 370187216, 502942312, 92658668, 801385042, 1038273441 - ], - [ - 536870912, 268435456, 402653184, 603979776, 704643072, 419430400, 276824064, 390070272, 593494016, 279969792, 142082048, 343670784, 176029696, 561840128, 217677824, 557629440, 203415552, 793636864, 549918720, 531067904, 286745088, 846032128, 194470528, 741174592, 544695008, 266169808, 560947784, 303132084, 870933002, 810577385 - ], - [ - 536870912, 268435456, 671088640, 603979776, 301989888, 117440512, 562036736, 918552576, 127926272, 424673280, 171442176, 787742720, 728367104, 684261376, 865763328, 379666432, 1037262848, 847245312, 437581824, 291267584, 989864448, 797301504, 801609856, 388207680, 454351520, 500809616, 659012296, 157699932, 317932198, 627714827 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 771751936, 16777216, 645922816, 188743680, 622854144, 657457152, 182976512, 83623936, 1059454976, 607584256, 728399872, 339623936, 432267264, 744747008, 85407744, 912231424, 231842304, 347818752, 1065712256, 700921664, 342089760, 286519472, 610220056, 584289524, 859808290, 306203433 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 771751936, 654311424, 1031798784, 356515840, 543162368, 860880896, 322437120, 660340736, 235536384, 271908864, 1072594944, 270614528, 800104448, 732532736, 784496640, 639816704, 78851584, 2633984, 545492608, 365011392, 94500448, 250836272, 566941912, 681002156, 26957486, 741336377 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 436207616, 553648128, 998244352, 289406976, 773849088, 942669824, 35127296, 176422912, 46530560, 459472896, 806846464, 19611648, 303570944, 579170304, 650586112, 1029784576, 185845248, 464462592, 954073216, 501678272, 819036256, 122175728, 59744360, 334377092, 561973486, 915682373 - ], - [ - 536870912, 268435456, 134217728, 67108864, 234881024, 1056964608, 343932928, 616562688, 920649728, 691011584, 492306432, 383516672, 916324352, 750714880, 930054144, 218513408, 965058560, 222638080, 866166784, 513209344, 231346688, 605182208, 101454464, 242309440, 268276384, 734533968, 253211288, 344680876, 296925898, 597208383 - ], - [ - 536870912, 268435456, 671088640, 335544320, 637534208, 956301312, 830472192, 1010827264, 966787072, 1064304640, 434634752, 656670720, 867303424, 294453248, 800489472, 864993280, 414588928, 789491712, 863127552, 334009344, 69475840, 154342656, 55320704, 584560704, 949930144, 1003443280, 387366552, 25060836, 253675590, 781145265 - ], - [ - 536870912, 805306368, 939524096, 67108864, 838860800, 721420288, 729808896, 247463936, 262144000, 577765376, 232259584, 664535040, 259653632, 1064108032, 820346880, 68665344, 93102080, 468897792, 404326400, 1002126336, 667652608, 253139200, 504107648, 758143424, 331297376, 734546384, 18324136, 51012988, 531832838, 502796359 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 771751936, 318767104, 511705088, 482344960, 207618048, 529530880, 220725248, 520355840, 142737408, 465895424, 15171584, 1045807104, 214589440, 47697920, 352950272, 389057536, 450785792, 935159040, 463995008, 801374272, 48365728, 726991088, 1028620472, 781303884, 380133498, 440586355 - ], - [ - 536870912, 805306368, 939524096, 469762048, 167772160, 1056964608, 461373440, 322961408, 903872512, 84934656, 878182400, 977010688, 476708864, 634716160, 117080064, 617201664, 69672960, 87347200, 392853504, 542204928, 79484416, 598672640, 1022490240, 860804544, 358682208, 735474096, 536541256, 843949132, 803305126, 840046017 - ], - [ - 536870912, 268435456, 939524096, 201326592, 838860800, 318767104, 260046848, 79691776, 39845888, 456130560, 436731904, 422838272, 554303488, 582156288, 466321408, 30752768, 477749248, 278704128, 65894400, 684129280, 543497728, 808598784, 428701824, 804715584, 812457696, 906378544, 84375624, 444988428, 642162398, 673414435 - ], - [ - 536870912, 805306368, 671088640, 469762048, 234881024, 318767104, 645922816, 1002438656, 127926272, 829423616, 1048051712, 230424576, 639238144, 829358080, 1343488, 623460352, 737222656, 1002106880, 823724032, 770227200, 986952192, 420252928, 348598912, 522571200, 834015776, 56573360, 151984664, 214401532, 723822722, 599198739 - ], - [ - 536870912, 805306368, 134217728, 469762048, 973078528, 251658240, 729808896, 272629760, 241172480, 519045120, 26738688, 718536704, 638451712, 171769856, 989954048, 1031815168, 759390208, 920760320, 523544576, 280845312, 297838080, 690353920, 789989504, 690793664, 271543840, 917314416, 376194664, 97060860, 806879246, 93585649 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 436207616, 754974720, 411041792, 759169024, 870318080, 640679936, 761790464, 774635520, 114163712, 662372352, 785678336, 484163584, 260071424, 146829312, 774199296, 76735488, 582959616, 141762304, 487309952, 584638272, 1015259680, 860139440, 283179592, 900811524, 799881258, 84841649 - ], - [ - 536870912, 805306368, 402653184, 335544320, 637534208, 956301312, 696254464, 826277888, 400556032, 384827392, 717750272, 1029963776, 758513664, 921370624, 800489472, 19578880, 26222592, 217690112, 1024321536, 591748096, 954609152, 511037696, 638460032, 1036431552, 354773088, 592485456, 157191832, 110731748, 213608486, 1064279045 - ], - [ - 536870912, 268435456, 402653184, 67108864, 905969664, 251658240, 125829120, 88080384, 228589568, 344981504, 196608000, 994836480, 218497024, 914423808, 298024960, 1030111232, 628563968, 436801536, 648304640, 890444800, 435693056, 896492800, 718724736, 1067329856, 966263008, 1050411088, 622723256, 308084780, 654147782, 988495913 - ], - [ - 536870912, 268435456, 402653184, 738197504, 771751936, 553648128, 729808896, 524288000, 157286400, 1048576, 180879360, 663486464, 703463424, 394067968, 728793088, 366559232, 1069768704, 379785216, 112490496, 343806976, 536245760, 404602624, 778499712, 781516608, 604870368, 313257968, 69201496, 140835700, 999758070, 227345417 - ], - [ - 536870912, 268435456, 134217728, 335544320, 234881024, 385875968, 998244352, 96468992, 232783872, 646971392, 921174016, 13369344, 616431616, 323420160, 983662592, 171065344, 937009152, 378556416, 787425280, 483095552, 1052333568, 172323584, 371291776, 880239424, 1073741472, 1038108432, 1050116248, 719929420, 449716470, 1035538459 - ], - [ - 536870912, 805306368, 134217728, 201326592, 369098752, 654311424, 780140544, 121634816, 710934528, 781189120, 916979712, 915144704, 368705536, 117637120, 512131072, 256000000, 644325376, 949219328, 296343552, 403469312, 314209792, 761613056, 806573696, 971570112, 284110496, 761823216, 380109048, 109838444, 502923458, 184746161 - ], - [ - 536870912, 805306368, 939524096, 67108864, 503316480, 50331648, 981467136, 88080384, 52428800, 554696704, 314048512, 610009088, 371851264, 589627392, 286359552, 716980224, 543105024, 137293824, 539138048, 731257856, 804826624, 595144960, 691801728, 849248704, 264779360, 970337744, 6234136, 942600412, 404920434, 798366729 - ], - [ - 536870912, 805306368, 134217728, 469762048, 503316480, 184549376, 880803840, 113246208, 719323136, 877658112, 586678272, 174850048, 863109120, 953090048, 302415872, 755384320, 730046464, 809791488, 958760960, 557114368, 619529728, 79039744, 665734784, 487893440, 39364768, 102421680, 221867608, 822712668, 912261162, 512753911 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 771751936, 620756992, 444596224, 448790528, 400556032, 753926144, 554172416, 115081216, 230817792, 912326656, 833650688, 178929664, 151871488, 853405696, 667224064, 23536640, 540156416, 804216576, 514509440, 319802304, 1037598816, 172376112, 170352728, 311488612, 348096722, 510682367 - ], - [ - 536870912, 805306368, 939524096, 738197504, 905969664, 16777216, 176160768, 742391808, 736100352, 986710016, 36175872, 473694208, 850526208, 976814080, 1001816064, 616382464, 234217472, 945483776, 1017190400, 481514496, 658159104, 1060321024, 637480576, 445916096, 802093152, 535602288, 371142200, 1011098548, 602339442, 785425525 - ], - [ - 536870912, 805306368, 134217728, 872415232, 503316480, 553648128, 142606336, 138412032, 383778816, 667942912, 1006108672, 510918656, 793640960, 547160064, 526680064, 387235840, 760979456, 457199616, 761325568, 605481984, 651846144, 277048064, 71813248, 887520448, 752298528, 209508304, 1069007608, 963263300, 435003522, 363417649 - ], - [ - 536870912, 805306368, 671088640, 335544320, 771751936, 352321536, 109051904, 641728512, 513802240, 1034944512, 628621312, 270794752, 1073086464, 1037893632, 748060672, 839630848, 515612672, 188764160, 337774592, 167179264, 349709824, 269682432, 793616512, 329076928, 372541600, 163394640, 985892536, 870537044, 412592282, 739222617 - ], - [ - 536870912, 268435456, 402653184, 201326592, 905969664, 687865856, 528482304, 817889280, 966787072, 384827392, 198705152, 334757888, 844759040, 305594368, 410746880, 33669120, 50765824, 411447296, 172144640, 551683072, 915531264, 990756608, 1041938560, 332792896, 627828320, 868925232, 465123416, 723764452, 196560414, 163287027 - ], - [ - 536870912, 805306368, 671088640, 335544320, 838860800, 352321536, 226492416, 482344960, 853540864, 464519168, 285736960, 351535104, 338558976, 723582976, 1020559360, 712720384, 287055872, 1013837824, 914765824, 306605056, 748760576, 957488384, 454867072, 627846336, 889294496, 1031843152, 885039176, 652390548, 699668630, 67804195 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 771751936, 50331648, 780140544, 205520896, 312475648, 558891008, 620232704, 776732672, 952500224, 669319168, 879788032, 912932864, 399613952, 79671296, 720328704, 647126016, 60734976, 360469760, 847824512, 489158976, 110526560, 329203888, 762912856, 243921148, 857798658, 93645885 - ], - [ - 536870912, 805306368, 134217728, 872415232, 704643072, 385875968, 713031680, 826277888, 1033895936, 789577728, 943194112, 861143040, 1966080, 998572032, 717258752, 660881408, 7626752, 206049280, 353945600, 33612800, 319080960, 143078144, 306202752, 1025549504, 156674592, 790504400, 755367976, 92340380, 667320458, 317014037 - ], - [ - 536870912, 805306368, 939524096, 335544320, 503316480, 50331648, 528482304, 348127232, 480247808, 533725184, 609746944, 689700864, 108658688, 1015873536, 80183296, 346046464, 869670912, 777703424, 874432512, 452500480, 936117760, 211942656, 399607424, 140295616, 588785248, 460991888, 537579032, 260399516, 482836582, 815808719 - ], - [ - 536870912, 805306368, 134217728, 469762048, 503316480, 922746880, 998244352, 675282944, 819986432, 430964736, 333971456, 57933824, 936247296, 837091328, 959807488, 371900416, 819027968, 991604736, 620685312, 583592960, 325516800, 368443648, 688744576, 801320128, 916725280, 374829424, 769220856, 652128284, 861464782, 605678801 - ], - [ - 536870912, 805306368, 939524096, 738197504, 369098752, 486539264, 226492416, 281018368, 65011712, 617611264, 941096960, 239337472, 530972672, 343343104, 1055752192, 183418880, 15310848, 871149568, 258643968, 69876736, 168655360, 549409536, 749961344, 420331712, 742007008, 535916720, 992524376, 277826676, 251380278, 51584835 - ], - [ - 536870912, 805306368, 671088640, 67108864, 973078528, 352321536, 713031680, 188743680, 778043392, 124780544, 176685056, 653524992, 877527040, 340852736, 949911552, 109985792, 686825472, 860426240, 802310144, 593058816, 917333504, 727837952, 905201792, 768367808, 915793568, 473607440, 559736936, 1068371092, 401018378, 364224829 - ], - [ - 536870912, 805306368, 134217728, 469762048, 1040187392, 83886080, 109051904, 415236096, 929038336, 783286272, 608698368, 69468160, 731250688, 324599808, 549421056, 500023296, 90415104, 766791680, 869160960, 946211840, 1060398592, 151970048, 872554624, 302289088, 855930912, 528915568, 541466360, 715226388, 525581978, 305933731 - ], - [ - 536870912, 268435456, 402653184, 335544320, 1040187392, 822083584, 612368384, 339738624, 1012924416, 705691648, 601358336, 167510016, 210632704, 583335936, 589529088, 636895232, 470507520, 411136000, 910309376, 1063425024, 361940480, 471430400, 878323328, 708724032, 53182176, 527540496, 692944920, 409157844, 470867978, 517681349 - ], - [ - 536870912, 805306368, 402653184, 67108864, 973078528, 117440512, 595591168, 658505728, 887095296, 785383424, 778567680, 1025245184, 474087424, 426049536, 747864064, 974110720, 755736576, 646877184, 499750912, 388756480, 83723776, 236336896, 936132224, 942445504, 997949664, 391364816, 1042915464, 846958604, 298981478, 971519105 - ], - [ - 536870912, 268435456, 939524096, 872415232, 771751936, 218103808, 260046848, 968884224, 689963008, 45088768, 364380160, 1066139648, 393609216, 916258816, 641564672, 877477888, 290807808, 749457408, 650545152, 430111744, 469230080, 500893952, 23030400, 303625536, 24840288, 154123408, 335708760, 1040243172, 889315846, 998640019 - ], - [ - 536870912, 805306368, 134217728, 603979776, 503316480, 822083584, 880803840, 272629760, 320864256, 1001390080, 162004992, 390856704, 119144448, 73596928, 957579264, 14565376, 142958592, 306540544, 270776320, 70417408, 40688128, 296617728, 189282944, 890910656, 258433696, 579894096, 354345176, 1063727252, 714397834, 823659541 - ], - [ - 536870912, 268435456, 134217728, 872415232, 570425344, 150994944, 931135488, 247463936, 375390208, 74448896, 260571136, 1062469632, 559546368, 600637440, 376471552, 512704512, 886218752, 966668288, 514439168, 746953728, 675341824, 321144064, 181508224, 916057152, 170622496, 683715024, 627205640, 116524388, 550090878, 217423019 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 301989888, 553648128, 763363328, 423624704, 362807296, 420478976, 781713408, 581173248, 194379776, 828047360, 516128768, 568606720, 725032960, 868888576, 639461376, 140809216, 745771520, 225082112, 261038208, 4075712, 590571616, 667653360, 270406216, 123812740, 854949942, 414138533 - ], - [ - 536870912, 805306368, 671088640, 201326592, 369098752, 1056964608, 1048576000, 171966464, 958398464, 311427072, 752353280, 785645568, 452853760, 717291520, 812089344, 725073920, 118382592, 329846784, 335325184, 457700352, 748788224, 341114624, 985344128, 316683456, 796392096, 623505200, 632914136, 476495932, 221372506, 269144089 - ], - [ - 536870912, 268435456, 402653184, 201326592, 503316480, 721420288, 562036736, 809500672, 916455424, 649068544, 954728448, 373555200, 27394048, 20119552, 799637504, 526893056, 1012359168, 788475904, 790333440, 277550080, 227849728, 941337856, 654934144, 47693888, 1027563616, 83570736, 102336632, 470291628, 995440262, 24669633 - ], - [ - 536870912, 268435456, 134217728, 603979776, 838860800, 117440512, 528482304, 490733568, 916455424, 347078656, 145227776, 845938688, 630063104, 429850624, 344162304, 79806464, 383983616, 512872448, 752809984, 371354624, 712382976, 1028652800, 24877696, 319897408, 647707296, 922824656, 126280296, 826446796, 547749910, 565379257 - ], - [ - 536870912, 805306368, 402653184, 469762048, 771751936, 83886080, 75497472, 297795584, 945815552, 969932800, 789053440, 769392640, 726794240, 399310848, 658276352, 440680448, 706764800, 670085120, 586999808, 941904896, 1022756352, 997946112, 828567168, 995305408, 1070524640, 590959792, 675448536, 19084132, 644910634, 935237523 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 503316480, 553648128, 394264576, 1069547520, 849346560, 210763776, 501743616, 1043070976, 42860544, 387514368, 561414144, 1050230784, 800284672, 599298048, 551675904, 317914112, 861801984, 437527296, 631803520, 189621056, 12316256, 409334704, 598869528, 364580660, 98699334, 662056139 - ], - [ - 536870912, 268435456, 402653184, 872415232, 301989888, 855638016, 629145600, 549453824, 987758592, 9437184, 864550912, 417595392, 999424000, 973799424, 505577472, 544227328, 740122624, 686698496, 581982208, 771243008, 570237440, 402172160, 788357248, 209596480, 456677472, 840711376, 770646600, 1043573196, 801103894, 207515843 - ], - [ - 536870912, 805306368, 671088640, 603979776, 637534208, 989855744, 746586112, 532676608, 387973120, 938475520, 675807232, 278134784, 131989504, 768147456, 651591680, 348110848, 1012588544, 747622400, 456611840, 133141504, 916575744, 666187008, 2963584, 763528384, 306507424, 895725968, 714593816, 651703596, 273528978, 747652143 - ], - [ - 536870912, 268435456, 134217728, 469762048, 838860800, 452984832, 8388608, 37748736, 346030080, 66060288, 246939648, 281804800, 968228864, 505085952, 893288448, 34324480, 659693568, 357298176, 175151104, 125729792, 246077952, 816255232, 905200256, 868117824, 625875104, 309705776, 326695656, 548200732, 430234186, 779096357 - ], - [ - 536870912, 805306368, 671088640, 738197504, 234881024, 117440512, 125829120, 549453824, 44040192, 1007681536, 515375104, 925106176, 232128512, 412942336, 242319360, 940556288, 294248448, 105869312, 728422400, 465187840, 161755648, 93351680, 293593216, 503476416, 520312992, 58848432, 46387768, 195436316, 1016248478, 972719171 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 637534208, 989855744, 8388608, 390070272, 509607936, 999292928, 760741888, 58458112, 805961728, 579272704, 776241152, 400965632, 223617024, 972795904, 172595200, 795030528, 1041585664, 362517760, 282982016, 532309440, 296373792, 741728560, 15335608, 962003164, 335315002, 1061830721 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 167772160, 553648128, 125829120, 29360128, 262144000, 240123904, 133693440, 121896960, 434241536, 674562048, 974094336, 82657280, 945430528, 823390208, 169392128, 427176960, 149498368, 173829888, 68518016, 1000095808, 867672224, 566997232, 38606888, 227050628, 1026273822, 603564807 - ], - [ - 536870912, 268435456, 671088640, 603979776, 100663296, 922746880, 310378496, 851443712, 488636416, 34603008, 22544384, 58982400, 121765888, 358940672, 167018496, 409518080, 936042496, 387731456, 593844224, 116401152, 115933696, 655264512, 993656960, 82903104, 669941920, 713670800, 1065115672, 756125916, 266025034, 994358475 - ], - [ - 536870912, 268435456, 134217728, 469762048, 1040187392, 251658240, 847249408, 633339904, 249561088, 808452096, 525860864, 989593600, 267255808, 694616064, 309362688, 603799552, 1047109632, 136736768, 709888000, 296334336, 1002643968, 299897088, 179569280, 647766336, 169683616, 819897648, 79667288, 223178764, 586582034, 658502875 - ], - [ - 536870912, 805306368, 671088640, 872415232, 704643072, 251658240, 1015021568, 146800640, 836763648, 999292928, 910688256, 820248576, 974520320, 286064640, 725778432, 497238016, 515170304, 574164992, 406345728, 255712256, 801104384, 964579584, 765255808, 630001856, 663115936, 776264912, 505635496, 49549628, 790397042, 944390371 - ], - [ - 536870912, 268435456, 939524096, 201326592, 234881024, 1056964608, 142606336, 138412032, 375390208, 506462208, 271056896, 213647360, 243662848, 323289088, 619085824, 728776704, 1070473216, 759885824, 135141376, 535479296, 840534528, 982549248, 154743424, 390461248, 249954400, 779419760, 172916952, 478953676, 564666394, 394260701 - ], - [ - 536870912, 268435456, 939524096, 738197504, 1040187392, 285212672, 780140544, 482344960, 375390208, 309329920, 273154048, 252968960, 129630208, 370868224, 797671424, 150388736, 243965952, 242520064, 105510912, 168950784, 993633792, 635063552, 107698304, 683764800, 341991136, 91533744, 63667832, 55763204, 471475930, 1015582083 - ], - [ - 536870912, 268435456, 402653184, 201326592, 973078528, 553648128, 41943040, 155189248, 576716800, 340787200, 486014976, 104595456, 664666112, 216858624, 270827520, 95928320, 459923456, 1038528512, 764418048, 47846400, 76168704, 1031090432, 399031936, 773058880, 421256928, 934248816, 122070536, 627369460, 366305282, 977105105 - ], - [ - 536870912, 268435456, 671088640, 335544320, 33554432, 285212672, 461373440, 213909504, 698351616, 529530880, 915931136, 236716032, 811466752, 851116032, 508133376, 232898560, 544727040, 1072599040, 376834048, 1022344192, 888606208, 1068137728, 328273536, 412974400, 555650592, 752598288, 922676776, 833613140, 748062278, 740229479 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 100663296, 285212672, 8388608, 12582912, 979369984, 519045120, 444071936, 884736000, 735969280, 397213696, 638746624, 1062092800, 455237632, 752316416, 438953984, 811000832, 216947200, 53667072, 782031488, 529311040, 826718944, 707253680, 1011962616, 49033716, 909478138, 337417463 - ], - [ - 536870912, 805306368, 939524096, 469762048, 234881024, 218103808, 327155712, 994050048, 849346560, 131072000, 768081920, 257687552, 355598336, 708378624, 998277120, 793001984, 413622272, 416305152, 1028446208, 714906624, 257351168, 604711680, 591038080, 168032192, 788740192, 679775408, 969369304, 342026052, 53608694, 188284953 - ], - [ - 536870912, 805306368, 134217728, 738197504, 234881024, 452984832, 729808896, 4194304, 564133888, 11534336, 590872576, 645660672, 257556480, 2818048, 553025536, 849035264, 784998400, 6311936, 676386816, 883862528, 422648320, 243068160, 325032576, 103525824, 402111136, 387775856, 898359960, 172101916, 681990198, 909503517 - ], - [ - 536870912, 805306368, 134217728, 67108864, 33554432, 956301312, 1031798784, 700448768, 920649728, 688914432, 163053568, 268173312, 299499520, 1068171264, 818118656, 996655104, 148299776, 995643392, 619309056, 560034816, 232158720, 148795648, 842004096, 285389248, 159553184, 599859664, 199728808, 378733876, 427524190, 77316243 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 33554432, 285212672, 192937984, 197132288, 962592768, 743440384, 135790592, 26476544, 242876416, 222494720, 723877888, 938950656, 716021760, 740110336, 798316544, 628841472, 734032384, 694415104, 340842624, 874257472, 60150496, 528146416, 113737864, 551567364, 244457678, 117010655 - ], - [ - 536870912, 268435456, 402653184, 872415232, 1040187392, 620756992, 679477248, 784334848, 559939584, 206569472, 427294720, 99876864, 894042112, 509542400, 369131520, 419872768, 981540864, 29642752, 317110272, 789945344, 1046036992, 101112576, 17242240, 243731520, 1069996640, 937629648, 127066744, 278612948, 660602946, 223346731 - ], - [ - 536870912, 805306368, 402653184, 201326592, 234881024, 1023410176, 1065353216, 926941184, 719323136, 663748608, 948436992, 402391040, 199360512, 1041563648, 650805248, 10240000, 674521088, 788353024, 510105600, 777384960, 212651520, 483275520, 262092416, 1018599360, 389832928, 843141360, 694523992, 114357444, 594431686, 32404265 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 973078528, 285212672, 562036736, 171966464, 379584512, 844103680, 129499136, 954466304, 452067328, 183304192, 165380096, 584138752, 1014833152, 201502720, 33785856, 84063232, 663214592, 558026496, 640065664, 429125696, 459188384, 470811888, 790385384, 901020484, 734755334, 851984233 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 100663296, 117440512, 343932928, 817889280, 564133888, 17825792, 756547584, 532414464, 2752512, 351469568, 90734592, 638730240, 161062912, 662679552, 495577088, 333675520, 796028416, 757949696, 963890816, 305059264, 435168928, 418294064, 961726648, 176000044, 806004330, 77850927 - ], - [ - 536870912, 805306368, 671088640, 67108864, 570425344, 385875968, 310378496, 289406976, 996147200, 867172352, 285736960, 240386048, 167641088, 523829248, 10125312, 596328448, 789929984, 446533632, 680331264, 865147904, 987475456, 879645952, 350644352, 326470848, 598484640, 79956240, 547399176, 898779548, 1071203946, 434739605 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 838860800, 855638016, 947912704, 557842432, 1042284544, 70254592, 616038400, 1047789568, 371064832, 755171328, 830570496, 784416768, 702668800, 441536512, 355092480, 121426944, 330739200, 1064981248, 705939584, 680105152, 516509408, 644350960, 974651464, 386138124, 109445122, 407306357 - ], - [ - 536870912, 268435456, 402653184, 469762048, 234881024, 956301312, 461373440, 222298112, 383778816, 403701760, 175636480, 1072431104, 232128512, 693698560, 349995008, 882655232, 872144896, 229298176, 1035311104, 898569216, 838913536, 654832896, 981685888, 180478272, 363272416, 938890288, 166309464, 953443732, 618639062, 1016948113 - ], - [ - 536870912, 268435456, 671088640, 335544320, 33554432, 553648128, 1048576000, 37748736, 354418688, 972029952, 221773824, 280231936, 60424192, 1065418752, 750813184, 1063600128, 953589760, 919572480, 1015572480, 766211072, 1046246912, 107119360, 709945472, 176829504, 514381472, 165155664, 782368904, 1060438212, 123371610, 350503001 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 905969664, 721420288, 1031798784, 264241152, 119537664, 214958080, 676855808, 9699328, 666501120, 685834240, 469073920, 210485248, 349102080, 288321536, 610244608, 244569088, 415113728, 526438144, 154146944, 489231424, 710754976, 831553520, 792420440, 228897004, 412186710, 599565519 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 905969664, 654311424, 293601280, 138412032, 396361728, 625999872, 817364992, 392429568, 406192128, 160104448, 812351488, 228376576, 771088384, 141078528, 27215872, 66409472, 325696000, 639192832, 749756544, 357265600, 185542752, 195962096, 662606552, 595815324, 356577990, 254221281 - ], - [ - 536870912, 805306368, 134217728, 469762048, 1040187392, 184549376, 360710144, 960495616, 685768704, 617611264, 301465600, 283901952, 3276800, 858718208, 504791040, 660226048, 1062969344, 458903552, 827938816, 408671232, 953972224, 522169600, 456765056, 776812992, 864221344, 373392560, 392507096, 882145628, 429774894, 335451145 - ], - [ - 536870912, 805306368, 134217728, 738197504, 503316480, 352321536, 427819008, 851443712, 73400320, 116391936, 1012400128, 676593664, 718143488, 687669248, 432504832, 954515456, 632692736, 654143488, 885209088, 90643456, 628405760, 698146560, 1051891840, 310291648, 998354464, 29799344, 753211128, 531984276, 33521862, 641777851 - ], - [ - 536870912, 805306368, 134217728, 469762048, 704643072, 352321536, 109051904, 197132288, 425721856, 179306496, 297271296, 84672512, 129105920, 859766784, 818839552, 1037352960, 581632, 959770624, 754542592, 531149824, 140610048, 36735232, 830005888, 971521472, 1061251232, 597996720, 726895240, 869239076, 878076466, 273481147 - ], - [ - 536870912, 805306368, 134217728, 335544320, 771751936, 754974720, 830472192, 29360128, 392167424, 680525824, 171442176, 111411200, 133562368, 1051262976, 916357120, 39305216, 635084800, 946974720, 577337344, 411012096, 1057358336, 377851648, 994320512, 505835712, 565434400, 420363344, 49248952, 574227380, 581050950, 569638855 - ], - [ - 536870912, 805306368, 402653184, 335544320, 838860800, 989855744, 1031798784, 843055104, 341835776, 1060110336, 887619584, 854327296, 199884800, 359202816, 246120448, 445497344, 182099968, 1015353344, 147281920, 631493632, 68628992, 725298944, 234304128, 374026176, 897528544, 261566352, 947728936, 319958908, 12366558, 783740853 - ], - [ - 536870912, 268435456, 134217728, 738197504, 33554432, 822083584, 964689920, 163577856, 127926272, 458227712, 639107072, 188481536, 19791872, 416743424, 719224832, 320389120, 213770240, 871256064, 1005758464, 63454208, 174343680, 586255616, 105883264, 161799488, 945131168, 647963120, 394045608, 223296564, 891471566, 773147987 - ], - [ - 536870912, 268435456, 134217728, 67108864, 33554432, 83886080, 629145600, 826277888, 467664896, 904921088, 857210880, 633602048, 354549760, 374407168, 1049133056, 359415808, 949919744, 126070784, 608544768, 912440320, 11984384, 721040128, 355631232, 62472256, 47456288, 810479632, 919308296, 889801748, 925882006, 167395269 - ], - [ - 536870912, 805306368, 134217728, 335544320, 503316480, 419430400, 159383552, 524288000, 660602880, 632291328, 794296320, 460062720, 124911616, 964624384, 146767872, 270221312, 202104832, 717459456, 35952640, 232023040, 241895936, 1022846208, 1027445376, 895222208, 610867360, 200287376, 633301592, 933213492, 38464222, 271054297 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 436207616, 654311424, 276824064, 641728512, 1012924416, 791674880, 145227776, 949747712, 78774272, 342556672, 767459328, 996589568, 263495680, 116158464, 956176384, 830923776, 1002936832, 94415616, 428966528, 666521536, 73668640, 187819056, 111876808, 966617964, 691249834, 95223749 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 838860800, 721420288, 964689920, 457179136, 836763648, 212860928, 911736832, 837550080, 238157824, 1016922112, 1061715968, 1029947392, 527835136, 712953856, 544839680, 125596672, 352123392, 415073536, 584934016, 506327488, 538155232, 101545008, 260471464, 239289692, 157532846, 963698945 - ], - [ - 536870912, 805306368, 671088640, 201326592, 704643072, 889192448, 998244352, 775946240, 929038336, 347078656, 876085248, 58982400, 977666048, 962920448, 129073152, 280838144, 591568896, 417427456, 888195072, 274689024, 867423744, 784213760, 407240832, 811925696, 1043431584, 134037552, 94544040, 387018964, 203999470, 690711737 - ], - [ - 536870912, 805306368, 671088640, 335544320, 838860800, 385875968, 8388608, 406847488, 694157312, 600834048, 722993152, 994312192, 736493568, 76873728, 385515520, 852639744, 1050468352, 478220288, 239568896, 610692096, 542382592, 31142656, 492994688, 567689408, 337305760, 801378384, 27592904, 988818524, 900659714, 26157921 - ], - [ - 536870912, 805306368, 402653184, 872415232, 33554432, 150994944, 427819008, 322961408, 329252864, 812646400, 1011351552, 673447936, 439746560, 778764288, 1058177024, 937312256, 1061036032, 15708160, 584263680, 163107840, 690814464, 514851072, 380117120, 787787968, 965322848, 574788816, 237297160, 959754532, 317294822, 64103565 - ], - [ - 536870912, 805306368, 671088640, 872415232, 637534208, 687865856, 327155712, 373293056, 492830720, 590348288, 735576064, 454295552, 219021312, 825819136, 946110464, 985120768, 782147584, 787755008, 620570624, 726006784, 417619456, 880140032, 289343616, 140643520, 313644704, 446239696, 150273560, 234418020, 952541294, 245379145 - ], - [ - 536870912, 805306368, 134217728, 738197504, 838860800, 419430400, 41943040, 37748736, 878706688, 967835648, 866648064, 991166464, 188612608, 619511808, 267878400, 566837248, 228827136, 1024823296, 876357632, 694975488, 137588224, 1047302400, 431360128, 61713600, 856909344, 657997232, 384626248, 384946596, 592160938, 266681465 - ], - [ - 536870912, 268435456, 134217728, 738197504, 838860800, 553648128, 58720256, 180355072, 950009856, 158334976, 964165632, 209977344, 37879808, 887160832, 647331840, 292438016, 648552448, 932081664, 826169344, 761631744, 827452928, 273272576, 672792704, 131399744, 521109536, 763052208, 176660680, 893726852, 140638222, 1020568619 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 1040187392, 553648128, 1048576000, 4194304, 1067450368, 560988160, 127401984, 133955584, 938344448, 115539968, 609255424, 212680704, 482369536, 820391936, 693565440, 607104000, 25170432, 264571136, 694612608, 579959104, 659483168, 1484208, 151576792, 917991476, 720935074, 258645109 - ], - [ - 536870912, 805306368, 939524096, 201326592, 301989888, 486539264, 478150656, 809500672, 102760448, 219152384, 941096960, 48496640, 1064697856, 355401728, 887980032, 369639424, 427728896, 878120960, 213698560, 145990656, 214716928, 605584128, 417669248, 376459456, 397404384, 195884080, 296630856, 950849396, 976075506, 91197185 - ], - [ - 536870912, 268435456, 134217728, 872415232, 100663296, 285212672, 125829120, 146800640, 383778816, 753926144, 4718592, 800849920, 796262400, 378208256, 341540864, 905986048, 151117824, 998592512, 986163200, 31532032, 980783616, 252477184, 832191104, 358701888, 976332960, 1001006224, 919474744, 821837716, 961796742, 412617511 - ], - [ - 536870912, 268435456, 134217728, 738197504, 436207616, 419430400, 595591168, 88080384, 383778816, 68157440, 677904384, 569638912, 251265024, 190644224, 179011584, 341065728, 386768896, 833073152, 1073170432, 838847488, 601815552, 426658048, 1047718016, 431782976, 683389472, 926451120, 545100520, 60519716, 1041201710, 170330597 - ], - [ - 536870912, 268435456, 134217728, 738197504, 1040187392, 654311424, 159383552, 213909504, 866123776, 361758720, 629669888, 617349120, 430833664, 782172160, 469925888, 637616128, 50831360, 461869056, 365135872, 488782848, 282357248, 451538688, 49868416, 699903808, 803065504, 560037872, 288482904, 832099180, 562036862, 817889375 - ], - [ - 536870912, 805306368, 939524096, 603979776, 234881024, 1056964608, 243269632, 390070272, 60817408, 846200832, 1018691584, 722731008, 246284288, 943390720, 1029079040, 76070912, 931684352, 453939200, 558483456, 963625984, 601699840, 973253376, 956377216, 763794624, 868490976, 635453328, 5453496, 386509628, 55552090, 342512653 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 1040187392, 788529152, 645922816, 37748736, 127926272, 854589440, 448266240, 114556928, 831127552, 906952704, 902397952, 850051072, 129982464, 961646592, 508356608, 393118720, 333014528, 348134144, 232884352, 290722880, 709758560, 225402864, 1054609016, 591683580, 103255674, 842375097 - ], - [ - 536870912, 805306368, 671088640, 738197504, 301989888, 989855744, 159383552, 281018368, 207618048, 814743552, 1065877504, 774635520, 777650176, 956760064, 713457664, 490913792, 580952064, 368316416, 1033652224, 149332992, 483624448, 732786432, 480093824, 644333504, 1066618400, 537791344, 1005060200, 45875356, 735183054, 2818079 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 1040187392, 721420288, 1048576000, 1002438656, 924844032, 691011584, 385351680, 156499968, 1043202048, 3735552, 267747328, 945602560, 857989120, 858886144, 402184192, 517460992, 778849792, 425665280, 346077312, 192120000, 849016480, 998352880, 910282360, 644342636, 668293338, 502207711 - ], - [ - 536870912, 805306368, 402653184, 738197504, 973078528, 452984832, 998244352, 37748736, 685768704, 827326464, 105381888, 314310656, 281149440, 237305856, 779517952, 280674304, 398467072, 396496896, 456407040, 970511360, 1070626304, 42697472, 983232128, 129468352, 303857888, 980664432, 918331528, 784453852, 455120902, 418710629 - ], - [ - 536870912, 268435456, 939524096, 201326592, 771751936, 654311424, 847249408, 163577856, 320864256, 472907776, 860356608, 395575296, 196739072, 947585024, 1046446080, 569163776, 48521216, 320278528, 964597760, 265851904, 11259392, 486966528, 662763648, 172262464, 56809184, 441897264, 312301112, 424284636, 982595242, 70844759 - ], - [ - 536870912, 805306368, 134217728, 469762048, 234881024, 721420288, 293601280, 20971520, 962592768, 110100480, 606601216, 477364224, 922615808, 868024320, 551124992, 390774784, 468049920, 844591104, 101582848, 445004800, 549480960, 807784704, 603318400, 750537920, 325050912, 990719344, 67527352, 705162604, 822313702, 679517621 - ], - [ - 536870912, 268435456, 939524096, 201326592, 167772160, 989855744, 360710144, 398458880, 56623104, 376438784, 355991552, 1000603648, 378667008, 495910912, 259883008, 856113152, 830627840, 700723200, 1046624256, 855002112, 746528256, 981921536, 340254848, 497512512, 932337888, 185433136, 20489768, 765715436, 529571542, 1057926943 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 369098752, 922746880, 394264576, 406847488, 929038336, 26214400, 746061824, 850132992, 909508608, 961085440, 1046511616, 353845248, 297738240, 9408512, 910505984, 744621056, 403746304, 1060893952, 72160896, 417509696, 903125216, 354407600, 943470136, 466100524, 614932614, 682856701 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 167772160, 889192448, 1065353216, 985661440, 106954752, 258998272, 930611200, 452722688, 289275904, 920322048, 7110656, 838189056, 339697664, 828280832, 783206400, 26510336, 609200640, 211854592, 823241344, 738960704, 461711904, 885155248, 761547272, 871888228, 222167798, 752529807 - ], - [ - 536870912, 268435456, 939524096, 469762048, 167772160, 855638016, 796917760, 725614592, 262144000, 1007681536, 547880960, 308019200, 575012864, 992280576, 483688448, 306888704, 418062336, 578654208, 219256832, 136977408, 949990912, 597767936, 504467072, 934050624, 735871072, 805748784, 671424712, 604278972, 369301654, 956685409 - ], - [ - 536870912, 268435456, 134217728, 738197504, 973078528, 754974720, 830472192, 46137344, 765460480, 590348288, 58195968, 751042560, 245497856, 565248000, 188579840, 623067136, 511156224, 522137600, 684840960, 178844672, 1038927360, 344841984, 85819520, 366166080, 858759200, 321597616, 53205224, 187561140, 657147590, 489398027 - ], - [ - 536870912, 268435456, 671088640, 201326592, 301989888, 889192448, 243269632, 750780416, 165675008, 948961280, 816316416, 29097984, 911605760, 877592576, 329809920, 876462080, 454549504, 652865536, 312379392, 740803584, 368320000, 905932544, 678729344, 79407936, 14026784, 1015678064, 72089320, 732602340, 272375538, 85159719 - ], - [ - 536870912, 805306368, 939524096, 603979776, 1040187392, 587202560, 662700032, 390070272, 39845888, 80740352, 15204352, 1002700800, 514195456, 871825408, 1063026688, 91996160, 911106048, 607252480, 67069952, 260574208, 865450496, 848186624, 118653056, 977846464, 909435104, 50147472, 286099704, 508705932, 590131870, 828617053 - ], - [ - 536870912, 268435456, 939524096, 872415232, 234881024, 922746880, 461373440, 1027604480, 702545920, 70254592, 592969728, 354680832, 965869568, 437190656, 545947648, 357548032, 745529344, 1073541120, 619833344, 486120448, 561075712, 784012032, 655843456, 432812096, 447514848, 324971728, 1025859128, 898990044, 537878254, 428769205 - ], - [ - 536870912, 268435456, 939524096, 335544320, 301989888, 855638016, 595591168, 171966464, 1054867456, 87031808, 430440448, 564396032, 693239808, 1046413312, 992903168, 727990272, 108224512, 466219008, 190154752, 626654208, 883537408, 656575744, 429252736, 242856000, 993847520, 811273296, 640204360, 98841036, 447985166, 770280809 - ], - [ - 536870912, 805306368, 134217728, 469762048, 234881024, 822083584, 562036736, 566231040, 534773760, 254803968, 996671488, 316932096, 280363008, 598278144, 814186496, 810008576, 908533760, 215461888, 979236864, 411687936, 601347584, 316429568, 214900864, 267628736, 1024194592, 672193648, 641226296, 25138628, 199098374, 21823559 - ], - [ - 536870912, 805306368, 402653184, 201326592, 570425344, 16777216, 763363328, 88080384, 1021313024, 449839104, 745013248, 1029963776, 227934208, 160104448, 104169472, 112869376, 151986176, 1022767104, 639232000, 247020544, 755575296, 183518464, 152641664, 4010176, 80504928, 517176368, 711854728, 174224644, 253151286, 38735061 - ], - [ - 536870912, 805306368, 671088640, 201326592, 503316480, 385875968, 713031680, 440401920, 2097152, 737148928, 16252928, 157024256, 409600000, 804716544, 586842112, 677068800, 703242240, 20148224, 798914560, 688741376, 413438464, 145888512, 358363776, 510289344, 485673504, 444299760, 991852632, 340614316, 436507250, 889328901 - ], - [ - 536870912, 805306368, 402653184, 603979776, 369098752, 822083584, 864026624, 406847488, 618659840, 644874240, 81264640, 818675712, 128057344, 34930688, 913276928, 775045120, 138076160, 717180928, 830208000, 366760960, 860615168, 132474112, 49343104, 102719936, 468541664, 191959120, 895162424, 394921044, 96832150, 430076325 - ], - [ - 536870912, 268435456, 671088640, 335544320, 100663296, 822083584, 125829120, 742391808, 874512384, 760217600, 112721920, 218890240, 1023803392, 763822080, 658997248, 279068672, 831971328, 677302272, 1069119488, 244124672, 1061170688, 1017183488, 194393728, 190472512, 255328288, 340525072, 547750072, 160891028, 341803014, 767443061 - ], - [ - 536870912, 805306368, 402653184, 738197504, 570425344, 553648128, 578813952, 952107008, 794820608, 927989760, 1027080192, 852754432, 545128448, 821493760, 218857472, 213598208, 563322880, 559747072, 503429120, 721845248, 931303936, 340245248, 346536064, 464878784, 271520352, 407894960, 177838088, 450899012, 839944938, 320657235 - ], - [ - 536870912, 268435456, 939524096, 872415232, 838860800, 721420288, 612368384, 624951296, 782237696, 831520768, 491257856, 287047680, 699793408, 849149952, 1047887872, 410697728, 448798720, 124088320, 913405952, 75144192, 616904192, 711348992, 200789632, 784011072, 195516512, 269675664, 160026152, 326766460, 776263898, 438643833 - ], - [ - 536870912, 805306368, 134217728, 738197504, 167772160, 922746880, 813694976, 994050048, 90177536, 13631488, 554172416, 29097984, 870449152, 915865600, 736919552, 648593408, 651010048, 94105600, 156760064, 197919744, 975148544, 647105280, 334352000, 44695488, 13607072, 949809264, 248739848, 574572, 70792938, 589495089 - ], - [ - 536870912, 268435456, 939524096, 335544320, 167772160, 754974720, 41943040, 29360128, 463470592, 938475520, 462946304, 775159808, 70909952, 734199808, 648052736, 225853440, 241115136, 1066733568, 516921344, 853025792, 156386816, 317474560, 309270656, 44983360, 1032677088, 951670608, 486572200, 713441524, 768024810, 94441559 - ], - [ - 536870912, 805306368, 671088640, 469762048, 570425344, 754974720, 696254464, 583008256, 371195904, 581959680, 108527616, 146014208, 125698048, 724631552, 347963392, 915750912, 969416704, 256405504, 822638592, 409777152, 809053696, 232258304, 623409280, 668775616, 935407264, 1000602480, 376862728, 56472692, 210021894, 658684923 - ], - [ - 536870912, 268435456, 671088640, 201326592, 33554432, 587202560, 864026624, 339738624, 308281344, 1028653056, 968359936, 149159936, 630325248, 639434752, 479559680, 43663360, 492134400, 700313600, 551798784, 697674752, 605854208, 1066688256, 824139904, 152367168, 1004292256, 498527280, 271481352, 754904972, 436488270, 386067473 - ], - [ - 536870912, 805306368, 671088640, 872415232, 637534208, 352321536, 1065353216, 163577856, 954204160, 699400192, 821559296, 519307264, 677249024, 996212736, 40927232, 320454656, 700456960, 149237760, 28743680, 83782656, 955567616, 1029546752, 81795200, 196259008, 737832608, 7361488, 941498392, 524562580, 749082718, 60271863 - ], - [ - 536870912, 268435456, 402653184, 335544320, 905969664, 218103808, 25165824, 524288000, 853540864, 1064304640, 992477184, 336330752, 241041408, 136642560, 752058368, 935280640, 869392384, 87904256, 739604480, 186450944, 96705024, 824702720, 190315136, 1039984448, 347529952, 319484688, 685531192, 568791076, 804722878, 535761945 - ], - [ - 536870912, 805306368, 134217728, 201326592, 33554432, 419430400, 964689920, 163577856, 576716800, 131072000, 214433792, 815005696, 1039007744, 946143232, 718766080, 860438528, 777428992, 1024028672, 385292288, 876411904, 799834624, 986019072, 1055299712, 1033157824, 845914656, 782517552, 641114248, 534343844, 700389574, 409533463 - ], - [ - 536870912, 805306368, 402653184, 738197504, 301989888, 117440512, 830472192, 281018368, 568328192, 63963136, 936902656, 577503232, 262275072, 125108224, 590249984, 243515392, 1027907584, 992333824, 154249216, 395076608, 40936960, 1034858752, 466071168, 845284800, 202383584, 197070960, 595167272, 513766572, 390803086, 194299231 - ], - [ - 536870912, 805306368, 134217728, 67108864, 234881024, 150994944, 729808896, 1010827264, 52428800, 227540992, 109576192, 670302208, 297664512, 464322560, 459440128, 817283072, 169385984, 251146240, 67987456, 3617792, 652003840, 287014144, 511658112, 416138432, 399966752, 950630672, 132410040, 645090788, 452599822, 839839777 - ], - [ - 536870912, 268435456, 939524096, 335544320, 100663296, 318767104, 1031798784, 272629760, 815792128, 806354944, 434634752, 400818176, 322043904, 113180672, 288260096, 830914560, 306667520, 497168384, 177227776, 841790464, 604492288, 772048128, 1057087616, 796979264, 88418528, 505513040, 500242968, 957018444, 391336566, 986268929 - ], - [ - 536870912, 268435456, 671088640, 738197504, 1040187392, 620756992, 427819008, 163577856, 115343360, 674234368, 438829056, 927727616, 498991104, 368246784, 919240704, 8077312, 688971776, 704598016, 416425984, 723162112, 585531904, 708218624, 690512512, 667606848, 871942688, 1071057904, 26781912, 1000461412, 43409982, 725212931 - ], - [ - 536870912, 268435456, 939524096, 469762048, 503316480, 721420288, 545259520, 499122176, 975175680, 1003487232, 264765440, 1039400960, 974782464, 557514752, 997031936, 417513472, 192143360, 953896960, 26908672, 880538624, 948744704, 454268160, 174684288, 23110720, 993405664, 146301296, 590203640, 210186732, 734352098, 891536711 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 503316480, 385875968, 142606336, 826277888, 425721856, 363855872, 756547584, 761528320, 665976832, 203227136, 249790464, 7454720, 859824128, 179474432, 161474560, 706792448, 366355968, 254626560, 96460928, 1022529600, 813688992, 852544752, 1068377720, 553208668, 127262882, 751538309 - ], - [ - 536870912, 268435456, 402653184, 67108864, 570425344, 989855744, 243269632, 759169024, 782237696, 661651456, 80216064, 72613888, 343539712, 964624384, 654213120, 574177280, 156950528, 885526528, 206768128, 142517248, 528233984, 1073517824, 398190720, 714978368, 925613664, 92565776, 734248456, 534802860, 802275034, 985362917 - ], - [ - 536870912, 805306368, 939524096, 603979776, 503316480, 352321536, 947912704, 46137344, 983564288, 550502400, 292028416, 827588608, 556662784, 976420864, 853180416, 801685504, 1065623552, 491114496, 400652288, 255263744, 979182080, 353159424, 556234880, 596640960, 327787232, 115804560, 431085816, 362353812, 858454530, 489872795 - ], - [ - 536870912, 805306368, 939524096, 603979776, 1040187392, 587202560, 276824064, 1010827264, 106954752, 328204288, 307757056, 304873472, 136445952, 619773952, 273383424, 364331008, 766353408, 921006080, 534190080, 742360064, 633232896, 612362496, 366929536, 149429696, 218505312, 998387792, 818067480, 539423772, 150161082, 843935101 - ], - [ - 536870912, 268435456, 939524096, 67108864, 503316480, 956301312, 880803840, 843055104, 824180736, 326107136, 728236032, 548667392, 780795904, 732102656, 808615936, 315408384, 461611008, 331829248, 367421440, 856699904, 448783872, 661154048, 313976960, 898364480, 1009043168, 301005072, 472490232, 1058295972, 683468850, 1013511385 - ], - [ - 536870912, 268435456, 939524096, 201326592, 838860800, 721420288, 796917760, 901775360, 652214272, 17825792, 396886016, 97255424, 916324352, 101777408, 439123968, 588038144, 872194048, 13094912, 6465536, 139940864, 654894592, 637328128, 767706752, 988154688, 185757280, 816619376, 407546024, 677074140, 259450518, 788388683 - ], - [ - 536870912, 805306368, 402653184, 201326592, 973078528, 50331648, 343932928, 423624704, 509607936, 164626432, 553123840, 729546752, 884604928, 614006784, 296255488, 415744000, 446930944, 24588288, 915347456, 1064391680, 730672640, 116412672, 323956352, 743788992, 171814624, 383488496, 256806408, 1045914108, 490223194, 878183833 - ], - [ - 536870912, 268435456, 402653184, 738197504, 167772160, 889192448, 209715200, 62914560, 618659840, 313524224, 491257856, 697565184, 689569792, 661585920, 927170560, 455098368, 609230848, 385699840, 844863488, 911059968, 639024640, 22793472, 365443200, 72399936, 117245536, 710619568, 441261736, 739433876, 878280914, 424624383 - ], - [ - 536870912, 805306368, 939524096, 469762048, 704643072, 318767104, 1031798784, 683671552, 572522496, 519045120, 861405184, 1065091072, 881459200, 995426304, 510296064, 931512320, 197304320, 665292800, 708003840, 997960704, 848093696, 978600192, 753812096, 147050944, 304417376, 653557168, 794552520, 360267004, 663562942, 114699679 - ], - [ - 536870912, 268435456, 134217728, 335544320, 704643072, 419430400, 1065353216, 708837376, 996147200, 386924544, 271056896, 875298816, 103677952, 53411840, 44924928, 468238336, 101441536, 81530880, 97605632, 495596544, 480171520, 1001902848, 186570368, 368563008, 310302368, 266851088, 399955464, 143381364, 353949430, 922014685 - ], - [ - 536870912, 805306368, 939524096, 469762048, 33554432, 822083584, 209715200, 138412032, 119537664, 1045430272, 45613056, 362545152, 600440832, 91553792, 250249216, 505462784, 651419648, 754511872, 1035548672, 572144640, 839714304, 412117248, 215934592, 409508288, 191356512, 393389488, 938137704, 916638836, 815021786, 416961941 - ], - [ - 536870912, 268435456, 671088640, 469762048, 369098752, 889192448, 192937984, 239075328, 421527552, 529530880, 1042808832, 467402752, 214302720, 451346432, 368476160, 790183936, 572547072, 85315584, 435009536, 868051968, 586421760, 194877184, 753356416, 821062464, 211320864, 811745328, 170975480, 863735972, 101931126, 929955053 - ], - [ - 536870912, 268435456, 671088640, 67108864, 838860800, 855638016, 595591168, 876609536, 1050673152, 521142272, 631767040, 926679040, 467009536, 483328000, 180977664, 466141184, 592125952, 814321664, 141506560, 450558976, 65267200, 624037632, 930799232, 796390208, 483964960, 987839568, 431441512, 381444060, 613893830, 770465629 - ], - [ - 536870912, 268435456, 671088640, 201326592, 637534208, 419430400, 897581056, 641728512, 2097152, 829423616, 211288064, 557580288, 34471936, 213057536, 805208064, 736903168, 211836928, 850808832, 50190336, 476789760, 434307584, 940910848, 961372800, 51411264, 802044448, 131532144, 690837688, 54819860, 732291822, 708000205 - ], - [ - 536870912, 268435456, 671088640, 469762048, 838860800, 117440512, 343932928, 926941184, 1050673152, 768606208, 697827328, 793509888, 408289280, 861863936, 791314432, 870563840, 410099712, 181202944, 714455040, 792566784, 916004352, 533295360, 689219200, 620293440, 595310624, 1052679216, 710778472, 917090668, 589399578, 722787713 - ], - [ - 536870912, 805306368, 134217728, 603979776, 570425344, 788529152, 125829120, 826277888, 295698432, 976224256, 988282880, 619446272, 904527872, 325779456, 212828160, 650887168, 345907200, 858181632, 938801152, 931712000, 893028864, 18306816, 689605248, 828856256, 802327200, 368793424, 351308328, 101472236, 24971830, 472946473 - ], - [ - 536870912, 805306368, 671088640, 872415232, 436207616, 822083584, 998244352, 432013312, 111149056, 93323264, 1055391744, 874250240, 297926656, 44236800, 932413440, 1005436928, 362373120, 956518400, 1065830400, 734030848, 61187584, 605163264, 371723904, 154989504, 227770400, 988659728, 102326472, 348344340, 589777030, 525364387 - ], - [ - 536870912, 805306368, 671088640, 67108864, 838860800, 520093696, 847249408, 767557632, 882900992, 791674880, 410517504, 353107968, 563216384, 474677248, 636583936, 39370752, 167550976, 609169408, 972204032, 475745280, 553312768, 1003254016, 968084096, 934870464, 380504096, 941915344, 468732520, 458964332, 1048258690, 537889803 - ], - [ - 536870912, 805306368, 939524096, 469762048, 301989888, 218103808, 528482304, 549453824, 752877568, 691011584, 148373504, 10223616, 171573248, 112001024, 677806080, 628146176, 1014980608, 722440192, 712378368, 653972480, 810537472, 676755712, 1009472128, 52935104, 525382240, 984213936, 174414376, 275869060, 1073569878, 432967687 - ], - [ - 536870912, 268435456, 134217728, 469762048, 503316480, 318767104, 528482304, 926941184, 828375040, 630194176, 78118912, 914096128, 330694656, 140181504, 54951936, 593641472, 546349056, 338300928, 12244992, 110404608, 53112320, 356273920, 550909568, 550153024, 191690912, 1037890608, 889198168, 142801724, 583434374, 388120785 - ], - [ - 536870912, 805306368, 939524096, 201326592, 838860800, 721420288, 1065353216, 364904448, 908066816, 907018240, 445120512, 436469760, 788922368, 965148672, 12681216, 279330816, 928342016, 116387840, 267827200, 901301248, 253608448, 793301248, 471859328, 554696896, 789053664, 683933744, 346423496, 827785388, 334070014, 695353431 - ], - [ - 536870912, 268435456, 134217728, 872415232, 838860800, 50331648, 1048576000, 373293056, 681574400, 986710016, 144179200, 285999104, 649461760, 447414272, 853770240, 208846848, 1062150144, 571813888, 779704320, 1065008128, 318578176, 842907904, 954189440, 413777216, 702806176, 251022480, 789112552, 1001426396, 690790578, 522711061 - ], - [ - 536870912, 268435456, 671088640, 469762048, 771751936, 520093696, 41943040, 20971520, 551550976, 516947968, 586678272, 937164800, 867041280, 937623552, 273973248, 633028608, 339320832, 33058816, 190355456, 99410944, 159559168, 566311168, 950111872, 1068566848, 300693024, 729996592, 952213656, 958689356, 309762066, 793764873 - ], - [ - 536870912, 268435456, 402653184, 67108864, 301989888, 251658240, 1031798784, 381681664, 715128832, 466616320, 845676544, 173801472, 411435008, 809566208, 199458816, 749912064, 748396544, 975327232, 932669440, 797740032, 1005235712, 110720768, 556000896, 1338176, 843972832, 1053622352, 76382248, 74432556, 123609278, 838963303 - ], - [ - 536870912, 805306368, 671088640, 335544320, 369098752, 385875968, 360710144, 289406976, 23068672, 588251136, 43515904, 1054605312, 658112512, 1039073280, 802521088, 918241280, 581672960, 95555584, 36419584, 812766208, 948606464, 46601472, 522655360, 200299968, 852407840, 1008813456, 947031672, 478728652, 1019492398, 472224905 - ], - [ - 536870912, 268435456, 134217728, 738197504, 838860800, 687865856, 847249408, 826277888, 425721856, 825229312, 798490624, 154402816, 463077376, 523567104, 748650496, 917716992, 106602496, 739577856, 525109248, 735984640, 148286976, 384683776, 88901760, 1054751808, 5680672, 581816240, 481069128, 397294820, 70168298, 736743285 - ], - [ - 536870912, 268435456, 671088640, 335544320, 1040187392, 251658240, 964689920, 859832320, 631242752, 30408704, 631767040, 746323968, 232128512, 934215680, 561741824, 290668544, 208216064, 18698240, 1071781888, 1056177152, 750640640, 976525056, 224380544, 466053952, 811735072, 112458768, 647880280, 329553772, 181913246, 170617777 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 637534208, 150994944, 461373440, 792723456, 710934528, 881852416, 153616384, 22806528, 36044800, 946929664, 192708608, 509034496, 688906240, 976048128, 635377664, 669082624, 450133504, 483165952, 9078400, 242070336, 523985120, 884347056, 576649464, 1050752212, 565307126, 266052505 - ], - [ - 536870912, 268435456, 134217728, 603979776, 100663296, 654311424, 796917760, 289406976, 484442112, 279969792, 765984768, 416546816, 970588160, 903675904, 131760128, 786415616, 39804928, 983478272, 272467968, 870960128, 531787264, 908742912, 126937216, 641629248, 217015840, 472997264, 91186840, 980508124, 1041196574, 528571797 - ], - [ - 536870912, 805306368, 939524096, 201326592, 33554432, 989855744, 394264576, 440401920, 195035136, 328204288, 538443776, 54788096, 388366336, 643235840, 1039761408, 427048960, 531193856, 311029760, 869844992, 597963776, 395678208, 370684672, 910262400, 966803648, 278356192, 1000009776, 453462024, 663188716, 574976606, 128287593 - ], - [ - 536870912, 805306368, 939524096, 469762048, 234881024, 620756992, 713031680, 633339904, 115343360, 61865984, 698875904, 558104576, 908460032, 399966208, 333152256, 901120, 836149248, 584863744, 9189376, 588291072, 633083392, 696009984, 52265088, 610975936, 866459872, 529895536, 159160376, 857459860, 476819114, 799086999 - ], - [ - 536870912, 805306368, 939524096, 738197504, 771751936, 452984832, 159383552, 415236096, 488636416, 422576128, 426246144, 927727616, 66715648, 945094656, 188514304, 762527744, 101523456, 907841536, 71747584, 660950016, 760379904, 700112640, 70736512, 803884992, 470520416, 521798512, 12937432, 19110940, 255267454, 778650559 - ], - [ - 536870912, 268435456, 939524096, 67108864, 973078528, 855638016, 58720256, 4194304, 195035136, 175112192, 120061952, 987496448, 800456704, 298647552, 160137216, 371834880, 509091840, 779587584, 757774336, 836492288, 674753024, 730723072, 824922752, 534458176, 423049312, 521083984, 149703176, 658482140, 459786854, 303457165 - ], - [ - 536870912, 268435456, 134217728, 335544320, 905969664, 553648128, 645922816, 675282944, 807403520, 785383424, 242745344, 156499968, 280625152, 422903808, 440958976, 261865472, 1012965376, 821104640, 497723392, 61510656, 648819200, 1042823936, 594061440, 63673408, 610185760, 1015479120, 859867224, 497108164, 588561082, 664633329 - ], - [ - 536870912, 805306368, 939524096, 872415232, 704643072, 587202560, 914358272, 29360128, 836763648, 353370112, 329777152, 226754560, 860225536, 572981248, 871792640, 440221696, 1021861888, 967102464, 95500288, 866106368, 828203520, 104420608, 720240768, 1017315520, 238059744, 232407248, 352247976, 361336972, 477190362, 109014023 - ], - [ - 536870912, 805306368, 939524096, 67108864, 234881024, 16777216, 41943040, 297795584, 639631360, 495976448, 580386816, 908853248, 983695360, 89194496, 977240064, 813514752, 823910400, 762146816, 826796032, 887536640, 170989056, 659476736, 785718912, 628694464, 899276896, 28078288, 534800600, 934804500, 218691122, 531800387 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 704643072, 83886080, 864026624, 1019215872, 199229440, 36700160, 446169088, 189005824, 958529536, 315686912, 942637056, 832126976, 868655104, 761622528, 91297792, 297516032, 680633856, 613384960, 814579840, 914899008, 294199328, 453783792, 1045412008, 208325652, 909819598, 307314675 - ], - [ - 536870912, 805306368, 939524096, 469762048, 503316480, 855638016, 125829120, 1027604480, 1038090240, 858783744, 484966400, 829685760, 814612480, 671285248, 335904768, 973389824, 822468608, 713240576, 163694592, 120015872, 865193472, 305930496, 514607232, 488082624, 704261856, 210506096, 100663544, 520093708, 562036990, 306184325 - ], - [ - 536870912, 805306368, 939524096, 738197504, 100663296, 419430400, 260046848, 1052770304, 165675008, 705691648, 212336640, 348913664, 85590016, 836042752, 80510976, 220086272, 634675200, 785059840, 303794176, 860902400, 529090048, 624540416, 279389824, 959949760, 1029189216, 24493936, 234817656, 138548244, 145172166, 624405295 - ], - [ - 536870912, 805306368, 134217728, 738197504, 637534208, 520093696, 1015021568, 1027604480, 257949696, 258998272, 268959744, 819200000, 176291840, 440598528, 400588800, 942850048, 644505600, 472248320, 457820160, 414503936, 494040576, 1024014080, 290971776, 507657536, 769785888, 154337328, 703102984, 1004978220, 912810022, 606531615 - ], - [ - 536870912, 805306368, 939524096, 603979776, 369098752, 486539264, 729808896, 641728512, 983564288, 460324864, 102236160, 596377600, 313393152, 530382848, 455507968, 131645440, 91201536, 612331520, 108349440, 947055616, 479749632, 609116416, 558688384, 516901952, 378357920, 355286128, 870219928, 243732564, 1009337998, 330694985 - ], - [ - 536870912, 268435456, 939524096, 469762048, 704643072, 754974720, 142606336, 96468992, 924844032, 179306496, 663224320, 914096128, 724434944, 230096896, 489717760, 197869568, 505208832, 578793472, 892336128, 783713280, 246605312, 25847040, 159355264, 313429056, 720636320, 47249488, 1054603160, 920955212, 78247986, 583894049 - ], - [ - 536870912, 805306368, 671088640, 335544320, 905969664, 419430400, 1065353216, 994050048, 845152256, 877658112, 527958016, 659816448, 678297600, 903413760, 136675328, 908443648, 187113472, 715485184, 484747264, 654699520, 823435776, 596617984, 197840512, 247388352, 677637280, 391164912, 871891464, 412490532, 835503774, 774603981 - ], - [ - 536870912, 268435456, 671088640, 67108864, 33554432, 452984832, 411041792, 725614592, 455081984, 890241024, 138936320, 915668992, 192806912, 45809664, 892305408, 30457856, 514416640, 115806208, 679901184, 599006208, 862926336, 594717440, 796557696, 541921216, 40032160, 221492432, 165260808, 329148180, 1070280618, 1062693087 - ], - [ - 536870912, 268435456, 134217728, 201326592, 369098752, 352321536, 260046848, 205520896, 597688320, 862978048, 992477184, 823918592, 5111808, 89587712, 826507264, 807485440, 556867584, 25751552, 468502528, 573008896, 409536000, 238831872, 771555200, 303903808, 181344160, 244688976, 312564136, 921947484, 1013678142, 71122953 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 704643072, 150994944, 92274688, 968884224, 656408576, 124780544, 395837440, 175374336, 485359616, 119078912, 741769216, 319569920, 516448256, 790409216, 549488640, 178365440, 447897088, 649661696, 772041344, 133603520, 825111712, 775663088, 876895800, 571739404, 570223282, 680780021 - ], - [ - 536870912, 805306368, 134217728, 67108864, 100663296, 620756992, 109051904, 448790528, 530579456, 781189120, 603455488, 967049216, 413007872, 43581440, 1050116096, 955695104, 440737792, 57651200, 408156160, 240804864, 1010214400, 484903680, 561914496, 107629504, 232719520, 863731952, 1046742568, 230587188, 885586574, 567255009 - ], - [ - 536870912, 805306368, 671088640, 872415232, 771751936, 50331648, 260046848, 331350016, 10485760, 552599552, 892862464, 446431232, 485621760, 523960320, 530481152, 611401728, 762961920, 268349440, 195147776, 728816640, 553302528, 759019264, 495095680, 985830336, 169981984, 196140080, 131775016, 705541940, 102404014, 61772739 - ], - [ - 536870912, 268435456, 402653184, 335544320, 1040187392, 1023410176, 880803840, 314572800, 341835776, 380633088, 642252800, 3932160, 83492864, 141885440, 566722560, 739131392, 91316224, 615124992, 189556736, 357719040, 1002126848, 206921472, 14026368, 370533056, 611800608, 466027280, 923613336, 418430420, 1021923486, 820961773 - ], - [ - 536870912, 805306368, 134217728, 201326592, 436207616, 218103808, 897581056, 272629760, 559939584, 948961280, 653787136, 221511680, 985006080, 334823424, 420839424, 717570048, 266133504, 314060800, 173369344, 488991744, 26016256, 736310016, 743586944, 811114432, 92552352, 708681712, 501857448, 478994428, 644046002, 940699633 - ], - [ - 536870912, 805306368, 134217728, 872415232, 637534208, 989855744, 595591168, 121634816, 1025507328, 233832448, 9961472, 797704192, 565575680, 1015611392, 478642176, 275890176, 819601408, 724389888, 33867776, 1068575744, 557553152, 683603200, 340755072, 643167040, 202912928, 491738736, 685047336, 467290372, 816676014, 960936527 - ], - [ - 536870912, 268435456, 939524096, 335544320, 234881024, 184549376, 41943040, 188743680, 912261120, 516947968, 181927936, 117702656, 254672896, 96665600, 925007872, 364036096, 160014336, 169627648, 1040881664, 551394304, 766136832, 422497024, 180363392, 60829120, 32754336, 862579408, 344752152, 3260420, 843784246, 507416607 - ], - [ - 536870912, 268435456, 402653184, 469762048, 369098752, 16777216, 461373440, 415236096, 333447168, 101711872, 563609600, 529793024, 832962560, 491716608, 890404864, 555302912, 332734464, 1007071232, 503302144, 414884864, 291785216, 45085440, 1023473280, 495176128, 29400736, 342007248, 147864760, 863664844, 34064430, 150905869 - ], - [ - 536870912, 805306368, 671088640, 872415232, 167772160, 83886080, 1048576000, 641728512, 694157312, 896532480, 8912896, 255590400, 622460928, 587661312, 957120512, 41041920, 386473984, 33394688, 289015808, 244683776, 288730624, 1013226240, 125819520, 460956352, 838108704, 524787504, 225377448, 360836596, 264327850, 681735925 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 838860800, 855638016, 92274688, 113246208, 710934528, 9437184, 591921152, 205783040, 1013579776, 762773504, 693338112, 245940224, 555130880, 214102016, 358643712, 789765120, 713637376, 296174848, 154772096, 568300864, 591797792, 1005221168, 11860632, 984840572, 989591570, 457055235 - ], - [ - 536870912, 268435456, 134217728, 603979776, 33554432, 419430400, 545259520, 759169024, 551550976, 378535936, 16252928, 165937152, 733347840, 376373248, 213614592, 898088960, 1046798336, 158658560, 676083712, 168332288, 214774272, 893960960, 1026527360, 660214976, 311830688, 392059088, 254966440, 747285492, 713994794, 606798637 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 503316480, 1023410176, 494927872, 222298112, 748683264, 846200832, 543686656, 293339136, 566362112, 711000064, 177307648, 20692992, 757456896, 485871616, 946788352, 12211200, 778406400, 357992192, 731707008, 865107904, 784039968, 459718672, 752246808, 81727548, 1009956894, 1011369021 - ], - [ - 536870912, 805306368, 134217728, 201326592, 33554432, 721420288, 243269632, 88080384, 668991488, 1045430272, 277348352, 752091136, 629538816, 26017792, 119111680, 100614144, 375545856, 59854848, 522909696, 518441984, 698147328, 988970752, 473693056, 764163264, 890831776, 654244080, 350478760, 80840700, 331979306, 775353111 - ], - [ - 536870912, 805306368, 939524096, 603979776, 301989888, 520093696, 830472192, 666894336, 702545920, 567279616, 429391872, 504102912, 740163584, 107282432, 985300992, 146718720, 974577664, 735285248, 312166400, 93148160, 819894784, 201797376, 598307456, 155566144, 570997408, 934696048, 723566744, 179497812, 537590282, 548830987 - ], - [ - 536870912, 805306368, 402653184, 201326592, 301989888, 184549376, 427819008, 465567744, 455081984, 344981504, 592969728, 79429632, 583925760, 891617280, 131104768, 356139008, 256663552, 15159296, 502335488, 522851328, 1012192768, 263890688, 688676480, 101031744, 121747104, 677550960, 317720760, 816412796, 714573866, 404313143 - ], - [ - 536870912, 805306368, 939524096, 872415232, 704643072, 587202560, 981467136, 1052770304, 392167424, 78643200, 1057488896, 823394304, 979501056, 1060306944, 340492288, 1010253824, 510697472, 174665728, 446965760, 569027584, 971298304, 550238976, 66328704, 479452480, 345546784, 84750384, 447621176, 1014869044, 944068138, 253475619 - ], - [ - 536870912, 268435456, 939524096, 335544320, 637534208, 251658240, 947912704, 843055104, 106954752, 154140672, 837287936, 902037504, 808845312, 721354752, 283672576, 1044889600, 821469184, 601673728, 238655488, 56597504, 947546624, 456982784, 709587840, 877972928, 583822240, 981701072, 859840920, 501317828, 837970494, 751370507 - ], - [ - 536870912, 805306368, 939524096, 67108864, 973078528, 855638016, 494927872, 675282944, 1033895936, 972029952, 873988096, 803995648, 119668736, 1043529728, 788234240, 138166272, 730439680, 920924160, 168056832, 282575872, 285145600, 451571456, 209058176, 193800896, 489922592, 997929008, 478009400, 673743876, 102029882, 278798131 - ], - [ - 536870912, 805306368, 134217728, 872415232, 1040187392, 285212672, 276824064, 591396864, 677380096, 315621376, 490209280, 1039400960, 380764160, 1038811136, 869040128, 549797888, 932896768, 75927552, 444123136, 328569856, 694351360, 978416896, 41521024, 529874240, 727853088, 559088688, 1039810056, 1028972852, 818117054, 950028369 - ], - [ - 536870912, 268435456, 671088640, 67108864, 838860800, 352321536, 595591168, 541065216, 601882624, 30408704, 634912768, 600571904, 298188800, 550699008, 207323136, 982433792, 665149440, 641822720, 1021372416, 458423296, 270227968, 124539648, 91695232, 119233856, 166501024, 716567120, 850978824, 215940116, 943544858, 930042641 - ], - [ - 536870912, 805306368, 671088640, 738197504, 1040187392, 654311424, 998244352, 1027604480, 253755392, 1028653056, 1050148864, 885260288, 1063911424, 374276096, 739540992, 733200384, 1042964480, 1064185856, 843356160, 1017857024, 783071744, 329644288, 530116480, 474250048, 61358624, 288329008, 1021595048, 163120748, 1033271198, 1005600599 - ], - [ - 536870912, 805306368, 939524096, 469762048, 1040187392, 16777216, 494927872, 650117120, 673185792, 1062207488, 285736960, 878444544, 915013632, 27197440, 69828608, 412008448, 943874048, 476237824, 355579904, 557562880, 719632896, 95389952, 814959232, 816471232, 936294944, 748718384, 672320184, 434674908, 1043257886, 995186993 - ], - [ - 536870912, 268435456, 402653184, 201326592, 301989888, 855638016, 914358272, 801112064, 60817408, 1039138816, 310902784, 939261952, 364511232, 760545280, 1073184768, 260554752, 273653760, 366047232, 523896832, 412462080, 458719744, 452418304, 201668224, 604982976, 775031328, 187250448, 755963032, 800089548, 342406322, 745346531 - ], - [ - 536870912, 805306368, 134217728, 67108864, 570425344, 520093696, 914358272, 339738624, 467664896, 550502400, 284688384, 323747840, 210370560, 403111936, 246317056, 559497216, 696098816, 992161792, 7473152, 357176320, 858220032, 920387840, 940639616, 1012559808, 821972512, 299918640, 198429576, 209210052, 470590850, 65626095 - ], - [ - 536870912, 805306368, 939524096, 872415232, 570425344, 352321536, 713031680, 641728512, 65011712, 462422016, 366477312, 975962112, 997326848, 600506368, 238518272, 981286912, 76226560, 894816256, 715941888, 204604416, 279694848, 317096192, 617017728, 376932544, 849299488, 245093424, 793617976, 681805108, 921747362, 839600597 - ], - [ - 536870912, 268435456, 671088640, 738197504, 905969664, 1056964608, 864026624, 188743680, 10485760, 217055232, 167247872, 744751104, 1024589824, 480837632, 233734144, 206356480, 809263104, 520515584, 729839616, 524456960, 849402368, 703702784, 863732608, 732344384, 91396128, 465052688, 138723880, 622936876, 682697142, 316179327 - ], - [ - 536870912, 805306368, 671088640, 469762048, 637534208, 654311424, 159383552, 230686720, 748683264, 512753664, 956825600, 120324096, 837156864, 526974976, 211648512, 868040704, 300851200, 46632960, 54044672, 213279744, 29574656, 312568576, 227585408, 176872512, 200174496, 868677488, 95970824, 351779628, 111191438, 127019131 - ], - [ - 536870912, 268435456, 671088640, 335544320, 1040187392, 486539264, 696254464, 1002438656, 98566144, 193986560, 829947904, 431226880, 599654400, 90374144, 936607744, 979091456, 709271552, 479473664, 894191616, 801678336, 373105152, 77776640, 959569536, 289973440, 931009696, 637728720, 822124552, 730017796, 214026262, 257975305 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 570425344, 150994944, 813694976, 985661440, 123731968, 87031808, 382205952, 516161536, 891944960, 255262720, 125992960, 289456128, 203595776, 873680896, 207169536, 56572928, 144014848, 148045568, 607820416, 703528768, 52289056, 808890160, 268513928, 939590524, 872546306, 503513145 - ], - [ - 536870912, 268435456, 134217728, 201326592, 33554432, 385875968, 243269632, 490733568, 488636416, 927989760, 849870848, 1025245184, 561643520, 435486720, 96894976, 161464320, 1060872192, 206843904, 920029184, 1033323520, 834136576, 291797248, 621585536, 32682688, 423322144, 89537808, 626380424, 894766028, 1029072546, 827703239 - ], - [ - 536870912, 805306368, 671088640, 872415232, 1040187392, 654311424, 494927872, 373293056, 983564288, 208666624, 361234432, 443809792, 415891456, 123142144, 871923712, 654065664, 272588800, 542912512, 642627584, 81253376, 851005952, 702477056, 1041070720, 829819968, 390713888, 337031984, 970463912, 944585844, 332720670, 121186071 - ], - [ - 536870912, 805306368, 402653184, 67108864, 637534208, 150994944, 998244352, 641728512, 824180736, 242221056, 894959616, 898891776, 745144320, 1047461888, 265256960, 461193216, 398909440, 583028736, 232986624, 1049711616, 239737344, 278907648, 274140032, 252211264, 1061061152, 971497264, 103936408, 561572676, 979702150, 343128953 - ], - [ - 536870912, 268435456, 939524096, 67108864, 100663296, 83886080, 880803840, 1002438656, 723517440, 126877696, 35127296, 151257088, 458358784, 247005184, 1020755968, 959070208, 382558208, 204328960, 261883904, 26696704, 46801408, 939364608, 82210176, 392305216, 250841120, 501816336, 510476856, 1073561860, 686286214, 761398853 - ], - [ - 536870912, 805306368, 402653184, 335544320, 100663296, 721420288, 327155712, 876609536, 119537664, 651165696, 3670016, 1027866624, 179437568, 72024064, 485326848, 930037760, 657285120, 1041117184, 668792832, 845603840, 274948608, 242369792, 413691776, 56511040, 799283232, 33788976, 83950104, 880906516, 901936518, 509717355 - ], - [ - 536870912, 805306368, 134217728, 67108864, 503316480, 587202560, 58720256, 767557632, 870318080, 860880896, 812122112, 28049408, 1058406400, 806420480, 919306240, 593281024, 940548096, 1013370880, 734758912, 870130688, 508477952, 642161408, 897211264, 333711424, 738791840, 893302640, 161351720, 644670516, 167043606, 801213223 - ], - [ - 536870912, 805306368, 671088640, 872415232, 905969664, 788529152, 327155712, 549453824, 291504128, 491782144, 45613056, 590086144, 249692160, 663945216, 383418368, 16728064, 639197184, 161345536, 659142656, 153504768, 493286912, 994403584, 162919296, 473829056, 91971616, 634318896, 762525736, 793316404, 220698166, 56923439 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 234881024, 654311424, 75497472, 952107008, 463470592, 753926144, 868745216, 73138176, 983433216, 305987584, 273448960, 239550464, 1010540544, 823644160, 922916864, 746689536, 482438656, 698417408, 99839360, 273281088, 941616544, 436121712, 627854776, 259350604, 969987510, 49935467 - ], - [ - 536870912, 805306368, 939524096, 335544320, 838860800, 318767104, 998244352, 381681664, 274726912, 338690048, 628621312, 621019136, 320733184, 296288256, 487358464, 532725760, 618749952, 661753856, 383502336, 1003877376, 471292416, 754384128, 965015680, 1012842944, 1007338144, 920497392, 172749336, 671062308, 1054534282, 668207303 - ], - [ - 536870912, 805306368, 134217728, 335544320, 167772160, 150994944, 411041792, 62914560, 979369984, 617611264, 804782080, 200015872, 997851136, 774832128, 505053184, 92160000, 698490880, 649252864, 388605952, 974515200, 865373696, 81256704, 729108864, 583405504, 846106144, 70836528, 361746824, 497569748, 483700266, 125186361 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 503316480, 587202560, 713031680, 96468992, 761266176, 904921088, 594018304, 1055653888, 452329472, 783482880, 30048256, 528236544, 669786112, 561303552, 82843648, 485209088, 917449216, 987207936, 249762176, 867408960, 407511968, 138195280, 860657688, 669316140, 829000230, 737085727 - ], - [ - 536870912, 268435456, 671088640, 67108864, 704643072, 117440512, 109051904, 406847488, 811597824, 951058432, 526909440, 159121408, 704512000, 146735104, 995983360, 506314752, 99049472, 453709824, 600668160, 496499712, 692288000, 669004032, 661792640, 415948864, 845948832, 663085136, 146384776, 337911892, 564709282, 828125267 - ], - [ - 536870912, 805306368, 402653184, 67108864, 637534208, 486539264, 1031798784, 692060160, 203423744, 63963136, 961019904, 660340736, 456785920, 478609408, 353337344, 20004864, 284745728, 258215936, 188741632, 659039232, 240929280, 414888192, 751100544, 45005504, 916541984, 403801392, 44617880, 627929028, 524360326, 958504685 - ], - [ - 536870912, 805306368, 402653184, 201326592, 369098752, 788529152, 159383552, 650117120, 127926272, 198180864, 141033472, 6553600, 75890688, 137691136, 992772096, 1030766592, 20652032, 625922048, 276940800, 809657344, 820116992, 649261824, 303779200, 752793536, 84602272, 706029552, 809272760, 96064508, 252679086, 425956563 - ], - [ - 536870912, 268435456, 939524096, 603979776, 234881024, 1023410176, 377487360, 692060160, 1000341504, 766509056, 515375104, 530317312, 942800896, 880345088, 134184960, 761282560, 265412608, 15224832, 733423616, 249852928, 491743744, 106640128, 714063744, 414802880, 782051360, 1018262544, 171633208, 434008868, 34856846, 352875517 - ], - [ - 536870912, 805306368, 939524096, 201326592, 167772160, 956301312, 578813952, 817889280, 106954752, 1072693248, 582483968, 319553536, 432668672, 41353216, 790986752, 973979648, 860495872, 112709632, 793233408, 922614784, 175373824, 133761792, 2918784, 219698624, 941504032, 205780784, 966981560, 269524684, 973774762, 798454473 - ], - [ - 536870912, 268435456, 671088640, 201326592, 369098752, 1023410176, 914358272, 834666496, 333447168, 179306496, 820510720, 593231872, 735182848, 26804224, 56000512, 96387072, 199385088, 1051742208, 48834560, 73317376, 911314432, 1004081920, 401996416, 758044608, 576276512, 666364944, 982394408, 222916364, 525210774, 1017877757 - ], - [ - 536870912, 268435456, 939524096, 201326592, 838860800, 184549376, 880803840, 1035993088, 740294656, 328204288, 814219264, 1011089408, 107872256, 259719168, 423526400, 139542528, 967499776, 441716736, 950351872, 610055168, 371273216, 1016263424, 34180480, 881155776, 667698080, 514375120, 215381528, 912529180, 822082442, 175196615 - ], - [ - 536870912, 268435456, 939524096, 469762048, 436207616, 150994944, 209715200, 4194304, 1042284544, 594542592, 275251200, 122421248, 547487744, 506527744, 483098624, 729661440, 292265984, 1070436352, 518080512, 789627904, 540656128, 1054304000, 616984192, 41935040, 233414688, 126652432, 1019398200, 375456796, 961569306, 891025161 - ], - [ - 536870912, 805306368, 134217728, 738197504, 905969664, 184549376, 226492416, 1010827264, 891289600, 774897664, 73924608, 320077824, 168165376, 157089792, 178356224, 863059968, 164175872, 736432128, 1015875584, 907717632, 308268544, 1059206400, 724785024, 652788928, 953647008, 1046968560, 349026728, 289137116, 762257438, 197660695 - ], - [ - 536870912, 805306368, 402653184, 738197504, 973078528, 352321536, 696254464, 406847488, 555745280, 384827392, 608698368, 661913600, 854458368, 539033600, 426934272, 185286656, 383082496, 803008512, 671795200, 542481408, 320787968, 350952704, 902257536, 361151424, 681977248, 475319024, 18702392, 904458268, 172279842, 583310393 - ], - [ - 536870912, 805306368, 134217728, 201326592, 704643072, 956301312, 192937984, 29360128, 899678208, 709885952, 67633152, 444858368, 252313600, 470220800, 726302720, 929546240, 741875712, 712790016, 223647744, 566381568, 94552576, 575760640, 134857344, 814096704, 906674720, 394619184, 713802376, 46473548, 107627018, 779462921 - ], - [ - 536870912, 805306368, 134217728, 738197504, 167772160, 520093696, 75497472, 692060160, 161480704, 537919488, 616038400, 871104512, 532021248, 434700288, 16220160, 1028145152, 526737408, 305385472, 426276864, 1068956672, 703282688, 150303488, 290041472, 358901568, 221278368, 501908592, 385140264, 541839132, 686289026, 905102451 - ], - [ - 536870912, 268435456, 939524096, 603979776, 369098752, 285212672, 998244352, 650117120, 60817408, 326107136, 236453888, 619970560, 748290048, 901054464, 66682880, 107429888, 571531264, 550129664, 882726912, 267860992, 471458304, 871680768, 1041802112, 217527360, 815522336, 129354512, 83567544, 753235044, 1062371894, 94952193 - ], - [ - 536870912, 268435456, 134217728, 201326592, 301989888, 452984832, 394264576, 457179136, 627048448, 288358400, 421003264, 141295616, 901120000, 536543232, 69042176, 80625664, 338092032, 762515456, 570001408, 488483840, 5091840, 350596352, 22183552, 246074688, 45370528, 175775824, 207442472, 976076060, 206993050, 168370519 - ], - [ - 536870912, 268435456, 402653184, 67108864, 570425344, 285212672, 1031798784, 499122176, 727711744, 779091968, 206045184, 509870080, 960888832, 261554176, 701399040, 521322496, 658169856, 363786240, 803383296, 36713472, 82321920, 745936128, 368929152, 754672576, 97454496, 823153616, 138002872, 522999764, 1017228186, 403736261 - ], - [ - 536870912, 805306368, 939524096, 67108864, 167772160, 184549376, 176160768, 364904448, 123731968, 619708416, 311951360, 915668992, 461242368, 590413824, 720928768, 719831040, 321314816, 306515968, 196515840, 380580864, 1048267264, 908519680, 700849792, 670491840, 177065120, 36321776, 204347416, 599323700, 222669362, 53999887 - ], - [ - 536870912, 268435456, 402653184, 335544320, 100663296, 50331648, 679477248, 884998144, 832569344, 407896064, 434634752, 613679104, 150339584, 143065088, 142508032, 266584064, 271687680, 395874304, 728733696, 904631296, 647491072, 368368384, 923143552, 306161856, 159460768, 289470672, 585176504, 665910468, 31056830, 1057977287 - ], - [ - 536870912, 805306368, 671088640, 67108864, 704643072, 150994944, 461373440, 834666496, 513802240, 865075200, 875036672, 826015744, 467271680, 581369856, 723288064, 1024016384, 762257408, 978341888, 914905088, 78621696, 150110720, 723008768, 327656576, 726546624, 444693024, 507674928, 761290408, 540211652, 909804682, 1037396217 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 33554432, 419430400, 545259520, 650117120, 585105408, 68157440, 876085248, 440139776, 253886464, 661848064, 40402944, 338149376, 686694400, 569937920, 224233472, 124988416, 845860352, 472215808, 351083392, 603514816, 341745696, 670257200, 346662920, 1053080636, 285066754, 398630169 - ], - [ - 536870912, 805306368, 134217728, 201326592, 838860800, 1023410176, 679477248, 734003200, 249561088, 309329920, 554172416, 825491456, 991297536, 33882112, 977108992, 52510720, 663773184, 284733440, 276740096, 142787584, 465570304, 115440896, 510764416, 319548096, 204752288, 328604400, 700751272, 886927100, 290566042, 110794689 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 301989888, 50331648, 528482304, 1002438656, 962592768, 271581184, 1060634624, 813957120, 608043008, 293273600, 891781120, 351223808, 682745856, 226136064, 925140992, 1072604160, 187841024, 616094976, 222688384, 811348416, 264883872, 761261264, 961264136, 505191724, 174822586, 495837695 - ], - [ - 536870912, 268435456, 939524096, 335544320, 167772160, 788529152, 494927872, 574619648, 1038090240, 122683392, 379060224, 422838272, 71958528, 300744704, 110985216, 603340800, 963125248, 748498944, 485865472, 485110784, 450811392, 722843904, 884714368, 298110016, 274820640, 219319568, 125369784, 6763860, 936568234, 979071359 - ], - [ - 536870912, 268435456, 134217728, 603979776, 570425344, 721420288, 25165824, 901775360, 828375040, 533725184, 421003264, 420741120, 1071251456, 368377856, 466255872, 277823488, 361537536, 688910336, 474855424, 376187904, 782036480, 133689600, 684445568, 1024227392, 642674208, 292335888, 689794952, 993429604, 858347010, 379575611 - ], - [ - 536870912, 268435456, 402653184, 872415232, 838860800, 754974720, 41943040, 440401920, 828375040, 556793856, 818413568, 714342400, 354287616, 678100992, 738492416, 482656256, 199712768, 95907840, 1062156288, 949185536, 853049856, 638459136, 678437760, 942395328, 342106528, 359994064, 946692664, 784510244, 1008925610, 332403673 - ], - [ - 536870912, 268435456, 939524096, 67108864, 167772160, 352321536, 142606336, 641728512, 178257920, 523239424, 2621440, 743702528, 481165312, 650313728, 14843904, 596885504, 68739072, 1006497792, 188471296, 504359936, 368266752, 919083264, 348574080, 255186880, 654059424, 800592592, 239894552, 72400916, 1048207410, 791556113 - ], - [ - 536870912, 805306368, 402653184, 469762048, 167772160, 150994944, 931135488, 910163968, 543162368, 617611264, 374865920, 794558464, 866779136, 1027014656, 683638784, 154714112, 252583936, 892522496, 801708032, 602330112, 803614208, 233304320, 14948224, 560236224, 338073120, 180827440, 802619800, 799831004, 71317418, 90265337 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 167772160, 318767104, 931135488, 759169024, 627048448, 393216000, 661127168, 424411136, 948043776, 549650432, 589529088, 965984256, 391684096, 138752000, 20805632, 309056512, 1070519808, 893597440, 694294144, 628327616, 141164576, 617545776, 113344568, 841007164, 420683786, 1000009747 - ], - [ - 536870912, 268435456, 134217728, 335544320, 167772160, 1023410176, 511705088, 314572800, 383778816, 263192576, 258473984, 626262016, 603062272, 457768960, 872710144, 925581312, 997564416, 262230016, 286369792, 116984832, 443547136, 318747392, 1027934848, 562647872, 652683296, 983256080, 488562184, 1047896852, 488702602, 366022525 - ], - [ - 536870912, 268435456, 939524096, 469762048, 570425344, 889192448, 981467136, 247463936, 769654784, 458227712, 967311360, 655622144, 674627584, 344391680, 662470656, 1027686400, 731996160, 896741376, 698030080, 690893824, 778619392, 980758272, 749051264, 72106176, 49839520, 247345360, 924976536, 548615372, 301586362, 792473593 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 369098752, 721420288, 796917760, 792723456, 484442112, 1039138816, 443023360, 444858368, 175505408, 211615744, 47939584, 286146560, 25305088, 541265920, 828614656, 330398720, 336110080, 213275904, 205475712, 407381440, 869590944, 546134512, 163726728, 757206220, 886082078, 750348583 - ], - [ - 536870912, 268435456, 402653184, 67108864, 704643072, 184549376, 545259520, 255852544, 555745280, 196083712, 695730176, 810287104, 26345472, 306774016, 242581504, 352206848, 845783040, 1044656128, 172345344, 675615744, 1061585408, 834978560, 528747392, 354759360, 827615264, 911025168, 747719192, 264820484, 79104426, 991932875 - ], - [ - 536870912, 805306368, 134217728, 738197504, 1040187392, 889192448, 142606336, 247463936, 85983232, 349175808, 755499008, 760479744, 1019346944, 1042481152, 558923776, 122339328, 414703616, 405884928, 259753984, 801926144, 335319552, 243772672, 709361792, 70720832, 217088032, 760922160, 950001672, 229986348, 548505662, 163277877 - ], - [ - 536870912, 268435456, 402653184, 67108864, 100663296, 452984832, 293601280, 977272832, 65011712, 439353344, 1061683200, 356777984, 230817792, 849412096, 273776640, 456671232, 804020224, 431468544, 296359936, 234300416, 88866304, 474252032, 423732352, 107002944, 1047756832, 598294544, 418766872, 332132356, 897873926, 1038193691 - ], - [ - 536870912, 805306368, 402653184, 738197504, 973078528, 385875968, 612368384, 113246208, 765460480, 846200832, 543686656, 760479744, 1042415616, 540213248, 319389696, 512147456, 372875264, 974024704, 620611584, 106408960, 144833024, 99751680, 203992704, 121022784, 678666272, 124350512, 299255832, 350383148, 932305466, 914007831 - ], - [ - 536870912, 805306368, 939524096, 201326592, 436207616, 117440512, 159383552, 775946240, 429916160, 219152384, 856162304, 189005824, 940703744, 965410816, 42434560, 519225344, 968531968, 476049408, 417224704, 807289856, 981428736, 378407168, 741749888, 401260096, 813062176, 222970928, 451242552, 16845068, 478393498, 348356167 - ], - [ - 536870912, 268435456, 939524096, 872415232, 704643072, 587202560, 327155712, 46137344, 526385152, 498073600, 283639808, 734265344, 848166912, 563806208, 89030656, 947568640, 213704704, 464588800, 1038698496, 155464704, 885959168, 95991040, 643582336, 968998080, 685802400, 225630672, 411656728, 267796772, 61211538, 112990679 - ], - [ - 536870912, 805306368, 671088640, 603979776, 704643072, 251658240, 343932928, 910163968, 23068672, 602931200, 405274624, 765722624, 851836928, 741670912, 597655552, 586792960, 35479552, 389582848, 767449088, 233372672, 839354880, 1451264, 395280256, 73472448, 141696928, 317295088, 1048856456, 978679252, 418237858, 43143387 - ], - [ - 536870912, 805306368, 402653184, 469762048, 1040187392, 956301312, 1048576000, 4194304, 161480704, 36700160, 980942848, 633602048, 5636096, 689766400, 203456512, 200491008, 740007936, 211136512, 268277760, 70351872, 796521984, 1027931392, 622280320, 540846272, 928056992, 111699184, 195913912, 1058661868, 18194438, 842838037 - ], - [ - 536870912, 268435456, 402653184, 201326592, 771751936, 285212672, 192937984, 339738624, 505413632, 783286272, 651689984, 611057664, 171573248, 758972416, 221478912, 916045824, 5201920, 395038720, 1063737344, 664785920, 1027774976, 161599232, 217309056, 637154752, 794589728, 698539792, 485648280, 1039856076, 593319950, 128111617 - ], - [ - 536870912, 805306368, 671088640, 872415232, 771751936, 889192448, 713031680, 448790528, 677380096, 451936256, 129499136, 994312192, 49676288, 745340928, 335249408, 1072087040, 426057728, 27783168, 784635904, 833917952, 491758080, 187430144, 185502336, 143332544, 354390688, 234897648, 83923080, 42173892, 784474662, 106968369 - ], - [ - 536870912, 805306368, 134217728, 67108864, 637534208, 587202560, 142606336, 381681664, 580911104, 1060110336, 931659776, 14417920, 672792576, 1030160384, 1020166144, 266420224, 1003610112, 819654656, 147236864, 629095424, 162107904, 925734656, 305331840, 671675584, 815716896, 997743408, 242599048, 28729284, 311932550, 988166355 - ], - [ - 536870912, 805306368, 939524096, 738197504, 704643072, 318767104, 494927872, 1044381696, 501219328, 923795456, 227016704, 983302144, 888274944, 530251776, 731348992, 313311232, 1061920768, 868069376, 63084544, 329286656, 317836800, 379148544, 487867520, 493790144, 921253920, 172831792, 618354232, 452320556, 25135786, 182516435 - ], - [ - 536870912, 268435456, 402653184, 603979776, 436207616, 318767104, 25165824, 910163968, 417333248, 680525824, 125304832, 578551808, 189923328, 1004077056, 1024294912, 456671232, 563912704, 507686912, 887314432, 244532224, 712703488, 721367296, 797975424, 351973824, 993843232, 741475344, 738975256, 806732068, 639097754, 51856851 - ], - [ - 536870912, 268435456, 939524096, 603979776, 503316480, 687865856, 897581056, 1027604480, 346030080, 628097024, 411566080, 1038876672, 1966080, 509018112, 458784768, 991215616, 1006247936, 946089984, 779200512, 772365312, 976201216, 293476608, 960966016, 641844544, 438338976, 112433488, 401187736, 872300660, 142880262, 35878173 - ], - [ - 536870912, 805306368, 134217728, 738197504, 905969664, 553648128, 226492416, 499122176, 702545920, 955252736, 571998208, 30146560, 755630080, 640090112, 1029603328, 438550528, 605085696, 90722304, 85293056, 531016704, 43865600, 12782336, 710943616, 540028352, 477679136, 872281904, 175115656, 257526508, 107985814, 752472529 - ], - [ - 536870912, 268435456, 939524096, 67108864, 637534208, 822083584, 629145600, 364904448, 786432000, 684720128, 655884288, 648282112, 872022016, 225771520, 509706240, 781271040, 356114432, 18305024, 267532288, 321604608, 107951616, 583373056, 241827712, 718108480, 506910240, 1069728016, 367249336, 642923332, 73129990, 788942881 - ], - [ - 536870912, 268435456, 402653184, 603979776, 1040187392, 687865856, 243269632, 1010827264, 467664896, 617611264, 449314816, 659816448, 597557248, 1036713984, 148144128, 761118720, 6987776, 551940096, 885504000, 255167488, 59607552, 362892032, 70380928, 463147968, 1012688800, 988436688, 983927352, 572869428, 459795878, 201593805 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 234881024, 553648128, 595591168, 859832320, 987758592, 53477376, 251133952, 452198400, 585236480, 120651776, 351961088, 167231488, 778231808, 921899008, 1054390272, 56947712, 424234496, 567223040, 137779072, 1010981696, 677568544, 1005785104, 995670056, 757396540, 237587982, 817832737 - ], - [ - 536870912, 268435456, 402653184, 335544320, 570425344, 855638016, 478150656, 666894336, 471859200, 472907776, 702021632, 11272192, 793116672, 825425920, 945324032, 653049856, 220553216, 459411456, 433223680, 885748736, 751099392, 745738496, 179873408, 494707520, 562954400, 989120080, 715814968, 949449732, 284876346, 18616615 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 369098752, 218103808, 411041792, 46137344, 165675008, 569376768, 955777024, 1021575168, 354025472, 253165568, 48398336, 208715776, 381280256, 499585024, 638248960, 60816384, 482317824, 783086336, 614986112, 154878272, 747009568, 816571184, 231545224, 412401020, 262266934, 215158845 - ], - [ - 536870912, 805306368, 939524096, 603979776, 234881024, 318767104, 75497472, 356515840, 157286400, 963641344, 881328128, 528220160, 548274176, 712310784, 689078272, 612024320, 288694272, 57774080, 562731008, 352300032, 460179968, 727168256, 243530112, 943956032, 652263840, 213015664, 648557464, 1013781844, 702003222, 348273671 - ], - [ - 536870912, 268435456, 402653184, 201326592, 1040187392, 285212672, 864026624, 130023424, 379584512, 498073600, 913833984, 983826432, 210108416, 41353216, 334397440, 605700096, 1027055616, 437104640, 541722624, 387789824, 109084160, 239195392, 710990464, 462591168, 814316192, 1060906192, 158593720, 878203100, 374647942, 706573773 - ], - [ - 536870912, 805306368, 402653184, 67108864, 503316480, 16777216, 1031798784, 297795584, 316669952, 389021696, 718798848, 833880064, 382861312, 862650368, 875397120, 46546944, 321445888, 84840448, 68425728, 138525696, 757227008, 483621632, 74041728, 347003200, 881129504, 252390448, 1012680216, 364758788, 269227934, 261415489 - ], - [ - 536870912, 805306368, 402653184, 469762048, 503316480, 721420288, 696254464, 1069547520, 631242752, 800063488, 786956288, 682885120, 294518784, 415301632, 975339520, 1064321024, 549986304, 231165952, 407250944, 159671296, 522528256, 85319936, 171750784, 740980160, 999627680, 847044848, 88768568, 67387436, 317071366, 230051895 - ], - [ - 536870912, 268435456, 671088640, 335544320, 1040187392, 989855744, 293601280, 213909504, 73400320, 904921088, 412614656, 747896832, 1045823488, 288817152, 491094016, 488423424, 199958528, 995004416, 593528832, 510772224, 962281984, 376716544, 686204032, 973874624, 298001568, 48293328, 716178568, 20608452, 159812790, 897364479 - ], - [ - 536870912, 268435456, 939524096, 603979776, 234881024, 587202560, 1048576000, 767557632, 752877568, 554696704, 858259456, 142868480, 1071775744, 932249600, 48988160, 241582080, 871555072, 423309312, 422340608, 816225280, 160509440, 166371584, 753212032, 875754560, 416997408, 633286672, 281962552, 3644452, 1006284302, 156033315 - ], - [ - 536870912, 805306368, 671088640, 469762048, 503316480, 1023410176, 847249408, 306184192, 769654784, 282066944, 189267968, 358350848, 241827840, 372178944, 235962368, 971685888, 854548480, 464523264, 1004128256, 955544576, 409351680, 768395520, 264387200, 908275904, 351524384, 347674928, 308548264, 583898332, 910379070, 937538573 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 436207616, 184549376, 243269632, 297795584, 840957952, 623902720, 1041760256, 487849984, 697958400, 89587712, 922255360, 881115136, 191963136, 678981632, 1028114432, 760245248, 726231552, 308117248, 902163328, 496123456, 887843360, 338591536, 843017128, 479592060, 148425274, 599117627 - ], - [ - 536870912, 268435456, 671088640, 872415232, 1040187392, 989855744, 763363328, 515899392, 488636416, 737148928, 345505792, 860094464, 386269184, 191299584, 980779008, 79609856, 1053892608, 459837440, 836716544, 725754880, 266581504, 349268224, 241848448, 257891520, 738316448, 839048400, 419655816, 478383332, 910203062, 358873311 - ], - [ - 536870912, 805306368, 939524096, 335544320, 771751936, 687865856, 1048576000, 624951296, 81788928, 967835648, 338165760, 56360960, 201719808, 206635008, 924352512, 607567872, 918134784, 694644736, 589363200, 705952768, 41646592, 54789376, 129094016, 891990848, 299684768, 323390064, 263280664, 422087716, 735937046, 340195645 - ], - [ - 536870912, 805306368, 939524096, 603979776, 637534208, 16777216, 729808896, 373293056, 291504128, 776994816, 276299776, 524550144, 912130048, 726204416, 929857536, 6537216, 231940096, 440004608, 203745280, 1057995776, 296837632, 367643392, 824133248, 430687680, 326960288, 58457840, 466004504, 379553556, 99273886, 958247653 - ], - [ - 536870912, 805306368, 134217728, 469762048, 1040187392, 352321536, 427819008, 884998144, 216006656, 588251136, 369623040, 732692480, 463863808, 17367040, 690978816, 736575488, 1017847808, 203239424, 119506944, 1000207360, 517779968, 989755136, 722347392, 186034240, 791844768, 737730416, 1035252264, 914519852, 574629302, 514041929 - ], - [ - 536870912, 805306368, 402653184, 738197504, 838860800, 452984832, 260046848, 130023424, 748683264, 623902720, 637009920, 963379200, 252837888, 596312064, 544571392, 338477056, 854728704, 559624192, 677361664, 887856128, 870799872, 1004837632, 1071979392, 971407552, 1021810720, 443001904, 153575960, 767870764, 597156274, 268364763 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 905969664, 553648128, 1031798784, 666894336, 1029701632, 894435328, 758644736, 606339072, 220332032, 686882816, 25919488, 437239808, 681402368, 684003328, 28530688, 497761280, 662500864, 181921024, 95124352, 192902720, 81059872, 413913104, 16627768, 34991164, 407424566, 309119265 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 436207616, 251658240, 780140544, 759169024, 1008730112, 542113792, 122159104, 514064384, 442368000, 948109312, 541163520, 698564608, 93478912, 53039104, 592844800, 1048984576, 806229504, 952780544, 744763776, 79527616, 238149536, 767038928, 553517096, 429064236, 153714706, 609697843 - ], - [ - 536870912, 268435456, 402653184, 738197504, 33554432, 117440512, 696254464, 1061158912, 937426944, 907018240, 495452160, 573833216, 512884736, 709427200, 840269824, 547405824, 636559360, 496627712, 381442048, 270914560, 622333440, 964524288, 738684032, 422100288, 835082272, 705221648, 276270616, 871414060, 614059138, 574393671 - ], - [ - 536870912, 268435456, 134217728, 335544320, 100663296, 553648128, 662700032, 943718400, 769654784, 294649856, 308805632, 537657344, 299499520, 643104768, 399409152, 8011776, 338026496, 557174784, 329013248, 1018328064, 484079104, 198526208, 344804480, 958058432, 1031228960, 545104144, 270533256, 993160916, 882494630, 775262193 - ], - [ - 536870912, 268435456, 939524096, 335544320, 33554432, 218103808, 260046848, 1061158912, 111149056, 613416960, 882376704, 786694144, 209846272, 1002504192, 23298048, 200359936, 610803712, 168611840, 995031040, 921498624, 721218048, 933726464, 757246336, 835837504, 322568224, 334823440, 140083256, 285491220, 431071234, 1028165645 - ], - [ - 536870912, 268435456, 134217728, 335544320, 838860800, 956301312, 310378496, 88080384, 354418688, 177209344, 998768640, 671350784, 1032978432, 638124032, 1019510784, 309542912, 477765632, 616501248, 214853632, 1035236352, 965296640, 151339264, 856886400, 88810048, 585525280, 861959184, 808665608, 483934484, 787319986, 715481721 - ], - [ - 536870912, 805306368, 939524096, 872415232, 503316480, 989855744, 343932928, 155189248, 148897792, 277872640, 671612928, 459014144, 758775808, 86441984, 234717184, 1003110400, 704471040, 768176128, 519890944, 323699712, 851326464, 875083008, 1072523904, 495000256, 1019362848, 136364336, 179492024, 867933172, 426085054, 312355531 - ], - [ - 536870912, 268435456, 939524096, 67108864, 167772160, 251658240, 796917760, 515899392, 585105408, 269484032, 491257856, 941359104, 555089920, 766181376, 856588288, 568180736, 7856128, 360239104, 228902912, 592606208, 40555008, 325977856, 864907648, 10276672, 72819616, 596117584, 184365592, 151443220, 887208370, 18004811 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 100663296, 1056964608, 444596224, 482344960, 1067450368, 244318208, 823656448, 313262080, 206438400, 1061093376, 836075520, 642924544, 616046592, 222220288, 618133504, 768668672, 570158592, 853423872, 908357248, 930723904, 270519968, 579217488, 426481288, 80039020, 705306766, 502734675 - ], - [ - 536870912, 805306368, 939524096, 335544320, 771751936, 419430400, 914358272, 515899392, 429916160, 617611264, 429391872, 1069809664, 779747328, 427229184, 1041334272, 641351680, 773152768, 996331520, 259164160, 642513920, 870298112, 251609344, 535597952, 844388672, 570511904, 318820656, 964885432, 625161556, 534972430, 984726569 - ], - [ - 536870912, 268435456, 939524096, 335544320, 503316480, 285212672, 528482304, 390070272, 18874368, 108003328, 246939648, 386138112, 270401536, 480968704, 770605056, 860930048, 113876992, 817852416, 211527680, 99904512, 560330240, 122670336, 744528000, 542333376, 709545632, 461169872, 511278616, 90444036, 827287206, 291735749 - ], - [ - 536870912, 805306368, 402653184, 335544320, 1040187392, 385875968, 125829120, 1010827264, 543162368, 781189120, 11010048, 554958848, 70123520, 537985024, 476741632, 582270976, 580689920, 273387520, 71796736, 10845184, 469131776, 142540544, 874130304, 474843072, 713277856, 985793776, 10586168, 523271204, 454746662, 1070546691 - ], - [ - 536870912, 805306368, 134217728, 67108864, 637534208, 486539264, 947912704, 130023424, 610271232, 250609664, 691535872, 152305664, 891158528, 726728704, 782991360, 509394944, 384835584, 356036608, 588699648, 169718784, 684808704, 216594688, 92091520, 1000496832, 378615456, 231461872, 523073576, 1065993268, 1007657518, 517602585 - ], - [ - 536870912, 268435456, 402653184, 469762048, 503316480, 1023410176, 612368384, 281018368, 585105408, 506462208, 279445504, 871104512, 149028864, 691077120, 321486848, 950910976, 1027858432, 480432128, 185845760, 939052032, 708300288, 275200, 447496832, 239121088, 488890400, 592629776, 467388440, 736414748, 706596382, 690565949 - ], - [ - 536870912, 805306368, 402653184, 872415232, 838860800, 318767104, 645922816, 532676608, 195035136, 200278016, 250085376, 202113024, 280363008, 983629824, 376602624, 464175104, 510418944, 837029888, 171595776, 768939008, 326206976, 875259136, 405782912, 84293184, 883457952, 384587632, 589586488, 840437764, 1046763562, 1014502439 - ], - [ - 536870912, 268435456, 402653184, 738197504, 905969664, 553648128, 1048576000, 952107008, 383778816, 892338176, 14155776, 33816576, 566624256, 245825536, 81166336, 950812672, 398139392, 880226304, 868210688, 749786112, 798554624, 648481024, 550892672, 984607936, 750482592, 502770896, 352212152, 1007918332, 881396878, 95160541 - ], - [ - 536870912, 805306368, 402653184, 603979776, 973078528, 1023410176, 176160768, 20971520, 262144000, 569376768, 505937920, 219938816, 34734080, 318439424, 260407296, 8667136, 990289920, 919031808, 455501824, 955610112, 837700096, 649594624, 111537792, 641017792, 160253984, 397042736, 836534808, 594617124, 325602490, 79435005 - ], - [ - 536870912, 268435456, 402653184, 603979776, 33554432, 822083584, 864026624, 834666496, 106954752, 32505856, 640155648, 436994048, 596246528, 614268928, 198410240, 259735552, 120954880, 186601472, 202381312, 572034048, 541367808, 762798848, 280900736, 897783744, 314752544, 484668176, 666078360, 327732196, 748435490, 936483873 - ], - [ - 536870912, 268435456, 134217728, 201326592, 100663296, 218103808, 746586112, 230686720, 958398464, 363855872, 58195968, 298057728, 199622656, 601292800, 267354112, 734740480, 641540096, 333639680, 454277120, 847913984, 115185152, 1030929664, 182186624, 129346240, 817812128, 220420816, 129198760, 209354460, 977763502, 564429777 - ], - [ - 536870912, 805306368, 402653184, 335544320, 1040187392, 956301312, 478150656, 197132288, 887095296, 821035008, 301465600, 65798144, 435814400, 1072627712, 737902592, 753811456, 813195264, 44945408, 333031424, 226323456, 103998976, 798647040, 232651136, 174284224, 3335712, 848978736, 928905624, 748903892, 374531614, 816472841 - ], - [ - 536870912, 268435456, 939524096, 67108864, 838860800, 855638016, 260046848, 1019215872, 270532608, 36700160, 588775424, 1002700800, 14548992, 790298624, 633765888, 1037942784, 630743040, 394694656, 767428608, 80434176, 441212416, 661858560, 519784064, 760533952, 381098144, 690485968, 1070358040, 1018374420, 190531210, 614781943 - ], - [ - 536870912, 805306368, 134217728, 335544320, 838860800, 989855744, 796917760, 314572800, 912261120, 439353344, 954728448, 104071168, 215351296, 262471680, 703430656, 747159552, 520478720, 129978368, 1028794368, 442024960, 765379072, 859926784, 161740672, 47243456, 815273888, 134131952, 259112872, 944485604, 275193242, 17651167 - ], - [ - 536870912, 805306368, 939524096, 67108864, 1040187392, 520093696, 360710144, 734003200, 996147200, 881852416, 1017643008, 161218560, 753532928, 239009792, 177831936, 398934016, 634281984, 211857408, 99760128, 288918528, 1001737728, 624289024, 762696832, 517387456, 1051119136, 1012770096, 948581560, 388842692, 435197470, 456825135 - ], - [ - 536870912, 805306368, 671088640, 738197504, 369098752, 587202560, 796917760, 624951296, 648019968, 97517568, 844627968, 644612096, 318111744, 293142528, 738033664, 244203520, 33988608, 1034997760, 376145920, 105221120, 898870784, 678993664, 25126016, 256853312, 40323744, 763402864, 608374280, 941707036, 370240702, 725125455 - ], - [ - 536870912, 268435456, 939524096, 872415232, 771751936, 352321536, 578813952, 616562688, 278921216, 458227712, 105381888, 940834816, 617742336, 470351872, 779583488, 539049984, 412344320, 57331712, 704997376, 259697664, 1017993728, 22945024, 759588992, 664333120, 1050634272, 443001872, 42523192, 951475508, 125962414, 776174421 - ], - [ - 536870912, 268435456, 134217728, 67108864, 838860800, 788529152, 998244352, 440401920, 882900992, 632291328, 354942976, 28573696, 614858752, 1044316160, 161710080, 556908544, 1022091264, 727027712, 129263616, 564653056, 650040832, 509834496, 315794304, 964297408, 973941664, 1036549840, 363304360, 213706708, 1029955610, 525439035 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 704643072, 654311424, 209715200, 20971520, 769654784, 405798912, 618135552, 1050935296, 546701312, 827129856, 275349504, 725368832, 1003741184, 904400896, 805083136, 586378240, 1023123968, 1043708160, 664541312, 1040421056, 16810144, 159448304, 381887144, 169952716, 328284674, 495703339 - ], - [ - 536870912, 805306368, 939524096, 201326592, 1040187392, 486539264, 142606336, 1035993088, 589299712, 573571072, 336068608, 26476544, 170786816, 787546112, 833126400, 996622336, 965025792, 244789248, 296736768, 1051792384, 734678528, 968188160, 832510848, 834223552, 870092192, 953698544, 479156248, 159536188, 54619654, 937644305 - ], - [ - 536870912, 805306368, 134217728, 335544320, 637534208, 117440512, 92274688, 432013312, 48234496, 598736896, 186122240, 18087936, 441319424, 175702016, 208109568, 506970112, 622731264, 970166272, 837478400, 1034839040, 893968896, 4152576, 864140928, 650316480, 459332768, 141727728, 687391272, 539348260, 219469486, 273592019 - ], - [ - 536870912, 805306368, 671088640, 603979776, 973078528, 855638016, 444596224, 457179136, 115343360, 594542592, 247988224, 796655616, 362938368, 831717376, 1069187072, 917913600, 442343424, 208809984, 306718720, 826110976, 616795648, 438413056, 89191552, 1033415616, 1072111648, 969175088, 982878248, 34554916, 174827066, 996987699 - ], - [ - 536870912, 805306368, 671088640, 469762048, 369098752, 654311424, 964689920, 742391808, 320864256, 47185920, 946339840, 859570176, 694812672, 499056640, 346587136, 1054785536, 324657152, 593801216, 562984960, 359691264, 108677632, 515365120, 342330496, 1034944, 221399584, 526113072, 761629864, 848087772, 653314614, 456792343 - ], - [ - 536870912, 268435456, 939524096, 738197504, 1040187392, 520093696, 377487360, 750780416, 18874368, 776994816, 379060224, 205783040, 560070656, 649134080, 443252736, 63881216, 568188928, 27717632, 504489984, 645565440, 750170624, 283653376, 957288832, 738136128, 729047072, 88682512, 580880440, 432454700, 220248638, 5327135 - ], - [ - 536870912, 805306368, 402653184, 872415232, 704643072, 251658240, 478150656, 817889280, 790626304, 680525824, 684195840, 1025769472, 199098368, 635502592, 548569088, 819642368, 992862208, 1020809216, 355350528, 31015936, 850247168, 127490816, 575452544, 480884416, 315937696, 644151792, 213868600, 546476036, 885774386, 992285755 - ], - [ - 536870912, 268435456, 402653184, 201326592, 838860800, 318767104, 578813952, 281018368, 136314880, 812646400, 629669888, 787218432, 83755008, 434569216, 852656128, 20463616, 625369088, 929091584, 990984192, 614175744, 225928704, 353085696, 1026420096, 912136512, 894842272, 762977616, 212110264, 649244764, 279533578, 85738511 - ], - [ - 536870912, 805306368, 939524096, 201326592, 167772160, 922746880, 713031680, 1027604480, 962592768, 571473920, 105381888, 697040896, 193069056, 583204864, 765689856, 179355648, 494444544, 691499008, 294955008, 44487680, 907875840, 705192192, 929858688, 827328704, 103415840, 673120304, 722042936, 418365452, 496050186, 579383351 - ], - [ - 536870912, 805306368, 939524096, 335544320, 301989888, 318767104, 293601280, 339738624, 505413632, 204472320, 1017643008, 968622080, 859963392, 369164288, 151093248, 780255232, 62955520, 190877696, 277911552, 894995456, 259301888, 418312448, 366698880, 437609792, 763334112, 134478352, 396361736, 1013973004, 143130638, 848035845 - ], - [ - 536870912, 268435456, 402653184, 201326592, 369098752, 218103808, 1015021568, 465567744, 236978176, 867172352, 594018304, 163315712, 58589184, 866582528, 158564352, 464601088, 661135360, 196874240, 343848960, 338050048, 590533120, 852495104, 20517504, 356837312, 219837216, 1032679760, 441850152, 192628308, 543021486, 552577687 - ], - [ - 536870912, 268435456, 402653184, 603979776, 704643072, 721420288, 427819008, 624951296, 815792128, 934281216, 344457216, 1066663936, 775553024, 662241280, 960266240, 48152576, 740958208, 213962752, 501291008, 990981120, 758733312, 706579712, 590227840, 897729088, 195351456, 1022560592, 231522824, 200696068, 9393030, 800202569 - ], - [ - 536870912, 805306368, 402653184, 603979776, 905969664, 687865856, 125829120, 566231040, 731906048, 521142272, 556269568, 181141504, 191234048, 19988480, 821657600, 918863872, 486219776, 387887104, 649447424, 887323648, 556527104, 286739712, 304627840, 508304704, 237450336, 936431664, 1023993864, 740084748, 636462598, 585953545 - ], - [ - 536870912, 805306368, 671088640, 335544320, 570425344, 654311424, 327155712, 943718400, 421527552, 544210944, 465043456, 123469824, 706084864, 339542016, 742883328, 7618560, 1055072256, 824135680, 339286016, 958221312, 506927616, 348972288, 1044343168, 21622976, 1042630496, 648730224, 1035717000, 877846732, 88571754, 452250229 - ], - [ - 536870912, 805306368, 402653184, 335544320, 1040187392, 654311424, 947912704, 398458880, 916455424, 521142272, 382205952, 87818240, 813039616, 149356544, 359563264, 389169152, 1039458304, 977932288, 202483712, 541600768, 771584512, 710366976, 1043777408, 302448064, 899569184, 210483856, 20053544, 907581084, 693373998, 5931417 - ], - [ - 536870912, 805306368, 939524096, 603979776, 1040187392, 520093696, 360710144, 12582912, 182452224, 751828992, 1049100288, 921960448, 855506944, 20512768, 913145856, 224641024, 962732032, 258174976, 207861760, 65195008, 572757504, 574832384, 466788992, 796538432, 1069425312, 521757808, 375131656, 607879948, 446631054, 346555721 - ], - [ - 536870912, 268435456, 402653184, 67108864, 570425344, 285212672, 75497472, 1027604480, 94371840, 508559360, 452460544, 315883520, 280363008, 853213184, 312049664, 509886464, 482271232, 103165952, 71440384, 1056828416, 198946304, 437860096, 489023360, 773806400, 804661088, 914055184, 273280744, 1037913684, 701156878, 432031493 - ], - [ - 536870912, 268435456, 134217728, 469762048, 637534208, 1056964608, 226492416, 1010827264, 748683264, 149946368, 508035072, 947650560, 170786816, 139395072, 232751104, 59228160, 501424128, 520622080, 73197568, 1042154496, 241608192, 959685376, 1030788224, 638090944, 651976992, 132016720, 42385704, 996325972, 348686634, 230452819 - ], - [ - 536870912, 805306368, 671088640, 469762048, 167772160, 419430400, 394264576, 473956352, 799014912, 233832448, 455606272, 1033633792, 866516992, 761331712, 831619072, 288964608, 316989440, 199380992, 921946112, 420101120, 227484160, 1031560448, 796270464, 410575168, 952412384, 928127792, 66805768, 640028684, 69249034, 732965895 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 369098752, 587202560, 511705088, 859832320, 970981376, 347078656, 179830784, 371458048, 851836928, 756088832, 560562176, 795688960, 1035722752, 675524608, 159881216, 418460672, 198752768, 987094784, 589229440, 180619712, 66537248, 510228272, 401471496, 100385804, 857915914, 947280655 - ], - [ - 536870912, 268435456, 402653184, 335544320, 100663296, 721420288, 562036736, 264241152, 102760448, 164626432, 955777024, 354680832, 66453504, 693567488, 902266880, 1029652480, 1011605504, 246796288, 686786560, 310576128, 530135552, 982805248, 473838976, 955996736, 821921632, 914561744, 295200616, 496356052, 801009518, 440045265 - ], - [ - 536870912, 268435456, 671088640, 335544320, 838860800, 150994944, 109051904, 843055104, 824180736, 768606208, 275251200, 156499968, 243138560, 134152192, 406814720, 1021231104, 15622144, 204992512, 16496640, 1021938688, 504700416, 937301760, 930036096, 83335872, 630915168, 454663056, 741146728, 438475668, 858030178, 294083473 - ], - [ - 536870912, 805306368, 939524096, 872415232, 838860800, 654311424, 92274688, 1010827264, 736100352, 714080256, 769130496, 917766144, 925761536, 15269888, 303923200, 181649408, 715825152, 107941888, 227047424, 189647872, 598348288, 720328448, 759779456, 946723008, 236668064, 411525360, 244664840, 689851148, 599890574, 211833805 - ], - [ - 536870912, 805306368, 939524096, 469762048, 100663296, 1023410176, 411041792, 851443712, 312475648, 600834048, 159907840, 355205120, 160563200, 504430592, 749305856, 62767104, 536535040, 722284544, 176318464, 439878656, 634713600, 317154560, 287774336, 352729152, 488085344, 79674768, 998500360, 213500940, 236197390, 46617863 - ], - [ - 536870912, 268435456, 402653184, 469762048, 100663296, 989855744, 494927872, 1010827264, 937426944, 19922944, 481820672, 278134784, 15335424, 26673152, 455180288, 605044736, 262676480, 482136064, 119007232, 719336448, 934383104, 628661504, 120936064, 809163840, 656324960, 177074160, 137341416, 959728308, 121348110, 614436867 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 570425344, 889192448, 176160768, 666894336, 891289600, 982515712, 77070336, 873725952, 916586496, 293404672, 132087808, 648200192, 427646976, 64966656, 950175744, 243016704, 1012909568, 367228160, 480038528, 871254976, 736821536, 739336016, 827941000, 204835532, 984768942, 270849439 - ], - [ - 536870912, 268435456, 671088640, 469762048, 771751936, 385875968, 914358272, 700448768, 60817408, 590348288, 832045056, 379846656, 480378880, 693043200, 402751488, 604094464, 436314112, 620859392, 260163584, 138480640, 484506112, 156324608, 285803648, 67933504, 1000290784, 592007216, 770518888, 357485172, 637534210, 452984835 - ], - [ - 536870912, 805306368, 402653184, 872415232, 503316480, 587202560, 679477248, 171966464, 106954752, 439353344, 946339840, 82575360, 607780864, 233242624, 389316608, 796868608, 110125056, 712560640, 651503616, 361757696, 601417216, 323287296, 1064789632, 592306368, 715826976, 1000279856, 65071528, 871437308, 818456718, 956163521 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 838860800, 687865856, 411041792, 79691776, 627048448, 89128960, 326631424, 610009088, 581042176, 739835904, 1007517696, 526106624, 730128384, 944640000, 55805952, 1037149184, 666498560, 960250624, 468885120, 224486848, 827327968, 628628880, 56432136, 555897612, 425268878, 86819279 - ], - [ - 536870912, 268435456, 134217728, 738197504, 436207616, 285212672, 1048576000, 1035993088, 589299712, 709885952, 950534144, 73662464, 486146048, 318701568, 867532800, 169000960, 620371968, 654192640, 230004736, 756210688, 293267968, 884887296, 768878464, 430155200, 547493216, 572774768, 233018088, 331582644, 487833482, 159021519 - ], - [ - 536870912, 805306368, 939524096, 67108864, 234881024, 788529152, 343932928, 1027604480, 224395264, 504365056, 996671488, 272367616, 700055552, 426442752, 178421760, 112148480, 571301888, 1000476672, 892332032, 936184832, 25298432, 123649280, 691340672, 51897024, 251198752, 177502704, 900175144, 698430972, 397439782, 484038909 - ], - [ - 536870912, 805306368, 402653184, 603979776, 369098752, 352321536, 377487360, 658505728, 442499072, 449839104, 483917824, 214171648, 178913280, 460259328, 189038592, 493568000, 726589440, 963973120, 706959360, 875756544, 860528128, 8368384, 851278208, 891252288, 837652960, 654719728, 831055976, 534598844, 307198350, 905211461 - ], - [ - 536870912, 805306368, 402653184, 872415232, 838860800, 788529152, 444596224, 448790528, 547356672, 179306496, 845676544, 764149760, 480903168, 428277760, 329023488, 645087232, 828530688, 205172736, 194947072, 886590464, 702902784, 874928896, 78498944, 945466560, 546258976, 662830000, 524348584, 954328956, 80807054, 712528065 - ], - [ - 536870912, 805306368, 671088640, 872415232, 1040187392, 889192448, 377487360, 1027604480, 786432000, 418381824, 1004011520, 623116288, 124649472, 114753536, 155353088, 781565952, 1062690816, 830607360, 45447168, 679881728, 168498688, 165214464, 35963520, 116363840, 303447648, 123898256, 105138280, 425681052, 607089378, 758587089 - ], - [ - 536870912, 805306368, 671088640, 603979776, 1040187392, 520093696, 310378496, 549453824, 312475648, 428867584, 986185728, 145489920, 858128384, 540344320, 660832256, 837697536, 345612288, 642068480, 349870080, 8078336, 988450304, 547567872, 231718528, 533288256, 187495648, 912752624, 617883784, 848521292, 521561194, 770515897 - ], - [ - 536870912, 268435456, 134217728, 603979776, 905969664, 788529152, 8388608, 381681664, 245366784, 466616320, 904396800, 617873408, 983695360, 835911680, 82542592, 727171072, 685826048, 464539648, 211396608, 418245632, 849246720, 2408192, 433756544, 101642944, 304906848, 910094960, 787860072, 296963700, 765073514, 527310205 - ], - [ - 536870912, 268435456, 939524096, 738197504, 33554432, 16777216, 461373440, 1010827264, 362807296, 227540992, 653787136, 161218560, 833224704, 923598848, 634552320, 223395840, 328851456, 560844800, 128149504, 614059008, 99445248, 459518208, 1006235264, 941427392, 418113632, 388761232, 386041480, 612943556, 810844782, 534689691 - ], - [ - 536870912, 268435456, 671088640, 201326592, 369098752, 721420288, 562036736, 792723456, 1054867456, 632291328, 134742016, 1055129600, 611188736, 542310400, 606175232, 370262016, 173613056, 64802816, 558098432, 569988096, 898430464, 779865344, 366328448, 682057152, 437694304, 496908368, 54209512, 573844628, 899063810, 769527815 - ], - [ - 536870912, 268435456, 134217728, 603979776, 704643072, 922746880, 645922816, 725614592, 635437056, 1009778688, 585629696, 798228480, 1008336896, 97845248, 511344640, 86327296, 766746624, 597692416, 273684480, 1058546688, 232636928, 392121088, 915800960, 454200384, 108005152, 143145104, 191136648, 634637380, 340895522, 85534873 - ], - [ - 536870912, 268435456, 134217728, 67108864, 100663296, 150994944, 343932928, 264241152, 383778816, 636485632, 881328128, 657719296, 540672000, 501678080, 584679424, 980205568, 504782848, 256970752, 30996480, 904702976, 39254528, 267516160, 797528192, 884240320, 914015200, 373800816, 386468200, 695482804, 664527370, 708281605 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 503316480, 687865856, 478150656, 624951296, 861929472, 890241024, 506986496, 163315712, 814350336, 801439744, 483885056, 471842816, 164323328, 849653760, 415754240, 581317632, 993522176, 407799552, 512921216, 84538560, 502549600, 337590800, 499842184, 145011660, 331850470, 153583327 - ], - [ - 536870912, 268435456, 402653184, 603979776, 301989888, 889192448, 729808896, 188743680, 132120576, 500170752, 192413696, 654049280, 1041629184, 109379584, 946503680, 55820288, 449748992, 650760192, 487901184, 728902656, 960446976, 960617216, 585105536, 777028288, 607652960, 857490160, 382157448, 645749188, 366349542, 983941177 - ], - [ - 536870912, 805306368, 939524096, 335544320, 100663296, 956301312, 1015021568, 373293056, 501219328, 166723584, 361234432, 1052508160, 125435904, 878641152, 870350848, 753942528, 50946048, 66883584, 421263360, 779037696, 290051584, 270277888, 99336320, 359101376, 112468384, 252158512, 310685480, 951021820, 15294470, 386699273 - ], - [ - 536870912, 268435456, 671088640, 738197504, 838860800, 117440512, 998244352, 331350016, 119537664, 898629632, 566755328, 693895168, 142213120, 693567488, 81100800, 1002946560, 245178368, 693792768, 768075776, 127730688, 266015232, 780648192, 452802944, 699028672, 108968352, 876124080, 778356776, 1000241012, 805940098, 293415887 - ], - [ - 536870912, 805306368, 134217728, 201326592, 973078528, 251658240, 310378496, 1069547520, 190840832, 907018240, 1073217536, 698613760, 332005376, 784531456, 416186368, 91799552, 711303168, 715911168, 466798592, 263699456, 471716352, 542019840, 230221184, 931421248, 360349280, 441081520, 226673768, 493847484, 327793642, 1003303679 - ], - [ - 536870912, 268435456, 671088640, 469762048, 1040187392, 452984832, 914358272, 994050048, 656408576, 143654912, 146276352, 97779712, 395968512, 912326656, 112230400, 1000947712, 128770048, 112193536, 772528128, 559428608, 61086208, 30578944, 767317120, 123203008, 33489568, 265532112, 247226376, 97955844, 415184906, 234079239 - ], - [ - 536870912, 805306368, 939524096, 67108864, 503316480, 117440512, 159383552, 29360128, 639631360, 667942912, 577241088, 338427904, 212992000, 1058340864, 45580288, 946520064, 887136256, 510701568, 1064949760, 65313792, 663668224, 963527936, 102759552, 870804544, 641978080, 556652624, 271770248, 307541324, 836203630, 685453585 - ], - [ - 536870912, 805306368, 939524096, 335544320, 301989888, 251658240, 931135488, 549453824, 392167424, 313524224, 272105472, 238288896, 640811008, 698023936, 570851328, 615071744, 370991104, 1030746112, 5588992, 369284096, 232915456, 705831168, 982186112, 317667136, 76851680, 727896048, 72582120, 531335932, 461263206, 339605689 - ], - [ - 536870912, 805306368, 134217728, 201326592, 301989888, 285212672, 411041792, 37748736, 295698432, 324009984, 225968128, 764674048, 827981824, 912982016, 404914176, 905887744, 578330624, 102051840, 848967680, 822852608, 177360384, 729158400, 155476352, 367222336, 161360096, 1028139824, 475803880, 155674428, 697067242, 897464383 - ], - [ - 536870912, 268435456, 402653184, 67108864, 570425344, 587202560, 847249408, 138412032, 1063256064, 384827392, 457703424, 946601984, 560332800, 809304064, 1031700480, 147439616, 833396736, 1019727872, 367802368, 765854720, 505190912, 24039168, 498083200, 111712576, 1054683360, 21932912, 1017134472, 609324356, 840544998, 636842097 - ], - [ - 536870912, 805306368, 671088640, 469762048, 570425344, 218103808, 142606336, 952107008, 698351616, 783286272, 919076864, 404488192, 100007936, 654114816, 329744384, 761544704, 329474048, 735531008, 84674560, 344953856, 380177920, 93157632, 5147520, 889796416, 977053536, 470170352, 416574344, 518727500, 747261802, 337362679 - ], - [ - 536870912, 805306368, 134217728, 738197504, 33554432, 922746880, 343932928, 113246208, 681574400, 328204288, 303562752, 745275392, 1057882112, 207290368, 937984000, 289783808, 887824384, 337670144, 156248064, 817454080, 620622336, 999777024, 301425024, 885401664, 139396512, 968523280, 983086632, 279725404, 78543370, 625708807 - ], - [ - 536870912, 268435456, 671088640, 738197504, 905969664, 587202560, 494927872, 4194304, 467664896, 902823936, 299368448, 437518336, 5373952, 851247104, 439255040, 498221056, 476897280, 309751808, 501626880, 316652544, 731539968, 198216448, 249057408, 429185984, 252871968, 47998160, 213803656, 168549572, 870868906, 404551707 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 771751936, 922746880, 864026624, 289406976, 123731968, 1034944512, 1036517376, 395051008, 934412288, 124059648, 1064206336, 49168384, 883843072, 676311040, 952014848, 739757056, 824926720, 147869440, 158864256, 113552192, 1056920800, 150428496, 903582088, 242816068, 222674794, 1002343455 - ], - [ - 536870912, 805306368, 134217728, 738197504, 973078528, 318767104, 1065353216, 759169024, 350224384, 829423616, 755499008, 246153216, 360054784, 69140480, 251822080, 802996224, 8298496, 783544320, 208971776, 46363648, 603729408, 330236160, 900353664, 165724352, 871370912, 852083600, 227319464, 187052700, 222754858, 469124695 - ], - [ - 536870912, 268435456, 402653184, 469762048, 234881024, 587202560, 1031798784, 130023424, 991952896, 877658112, 769130496, 533987328, 580255744, 735117312, 253263872, 1047838720, 1049026560, 401174528, 20813824, 1059793920, 465296896, 717367552, 797440640, 392766144, 8130720, 575374768, 487299080, 728378372, 341532166, 3336455 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 838860800, 822083584, 343932928, 826277888, 752877568, 544210944, 459800576, 43778048, 1035075584, 636157952, 838828032, 304136192, 475013120, 339292160, 455473152, 1062648832, 891135488, 963823872, 80457344, 808378304, 936942624, 349473328, 620708392, 815808308, 974219938, 324606459 - ], - [ - 536870912, 805306368, 939524096, 335544320, 570425344, 16777216, 796917760, 708837376, 509607936, 212860928, 601358336, 130809856, 49414144, 481886208, 352157696, 862699520, 286629888, 952012800, 218810368, 765811712, 593887744, 516332288, 223750528, 1054741696, 632969568, 343714832, 833331720, 297011980, 984539534, 465717445 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 301989888, 318767104, 327155712, 490733568, 178257920, 611319808, 491257856, 821821440, 929693696, 94437376, 904953856, 722059264, 366862336, 475697152, 21600256, 855383040, 476785152, 706786560, 984691584, 849982016, 573373408, 475251024, 991289352, 568758276, 75733006, 791485455 - ], - [ - 536870912, 805306368, 134217728, 872415232, 905969664, 251658240, 763363328, 784334848, 828375040, 986710016, 182976512, 302252032, 507379712, 56557568, 59670528, 208060416, 1055088640, 446484480, 618899456, 798770176, 207876608, 568137984, 121773952, 640475328, 89896160, 464647952, 137942248, 619521820, 238779626, 610362129 - ], - [ - 536870912, 268435456, 402653184, 603979776, 301989888, 989855744, 1048576000, 1061158912, 375390208, 34603008, 115867648, 197918720, 417202176, 519766016, 996769792, 1040990208, 1006624768, 361410560, 319866880, 929590272, 912896, 788461824, 638249856, 1003588544, 466102048, 364654992, 52896424, 1063207764, 742125070, 281671949 - ], - [ - 536870912, 268435456, 134217728, 872415232, 1040187392, 1023410176, 763363328, 876609536, 10485760, 999292928, 749207552, 509870080, 331481088, 508231680, 503283712, 490061824, 1007378432, 73338880, 1025783808, 769897472, 152815104, 473373440, 841065344, 89217216, 1053332704, 898963312, 597308136, 519445620, 708847978, 765538489 - ], - [ - 536870912, 805306368, 402653184, 201326592, 100663296, 654311424, 394264576, 230686720, 748683264, 303038464, 295174144, 747372544, 924975104, 1022820352, 846757888, 360529920, 994746368, 236146688, 448759808, 936231936, 381940224, 432896, 479206784, 282650688, 74228384, 793983600, 39832872, 935070012, 611045902, 63146767 - ], - [ - 536870912, 805306368, 402653184, 201326592, 100663296, 352321536, 645922816, 884998144, 257949696, 261095424, 946339840, 356253696, 635043840, 660537344, 997228544, 28917760, 83140608, 789991424, 16619520, 909777920, 386880000, 871972096, 257259392, 937932736, 990187168, 493828400, 854078248, 402518012, 666581006, 38751247 - ], - [ - 536870912, 268435456, 939524096, 67108864, 33554432, 117440512, 75497472, 247463936, 622854144, 592445440, 426246144, 207355904, 679608320, 841285632, 1062633472, 755679232, 344563712, 523063296, 691787776, 693179392, 845733376, 920450304, 658729088, 377783360, 289859936, 453145040, 275050120, 683058500, 763002862, 733057169 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 436207616, 822083584, 260046848, 71303168, 861929472, 842006528, 137887744, 1040973824, 129368064, 637337600, 766410752, 992034816, 55664640, 1057525760, 531916800, 385526784, 799713792, 832726784, 697725824, 120453824, 31953376, 863339632, 492477320, 540743364, 353033186, 833762175 - ], - [ - 536870912, 805306368, 671088640, 335544320, 100663296, 855638016, 612368384, 717225984, 304087040, 95420416, 1041760256, 1042546688, 770310144, 373227520, 707559424, 522633216, 780722176, 386732032, 471263232, 659627008, 948552192, 1007492864, 77019264, 529644352, 531138784, 775739376, 886036584, 425046204, 634581634, 61581385 - ], - [ - 536870912, 805306368, 939524096, 738197504, 905969664, 486539264, 662700032, 398458880, 987758592, 1005584384, 446169088, 356253696, 959315968, 212402176, 776306688, 358858752, 861822976, 754003968, 504932352, 746429440, 697200128, 830050048, 256740224, 292984512, 687186144, 224129520, 615728648, 341299980, 233145742, 238168523 - ], - [ - 536870912, 268435456, 402653184, 872415232, 838860800, 520093696, 696254464, 750780416, 1033895936, 464519168, 113770496, 409206784, 978714624, 318308352, 258768896, 823312384, 39755776, 943460352, 520796160, 1038298112, 452384256, 935970048, 551848320, 1041689664, 857309216, 20727344, 193621512, 1067706628, 370597766, 253356365 - ], - [ - 536870912, 268435456, 939524096, 469762048, 100663296, 452984832, 276824064, 121634816, 631242752, 265289728, 315097088, 797179904, 623771648, 695533568, 695631872, 312000512, 546070528, 223080448, 833304576, 215692288, 1061331456, 38734080, 1002755200, 604959552, 65359520, 522160432, 1062046856, 464205636, 970609838, 281244727 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 33554432, 620756992, 914358272, 71303168, 664797184, 883949568, 182976512, 1021575168, 825360384, 27852800, 80052224, 1027751936, 832626688, 531730432, 325675008, 388256768, 642920960, 871961856, 733843840, 1002321216, 289290784, 662617104, 769634824, 334451980, 524775810, 553821519 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 167772160, 989855744, 125829120, 4194304, 392167424, 632291328, 272105472, 275513344, 790233088, 917831680, 864518144, 913719296, 19881984, 485724160, 533854208, 856247296, 345319936, 332852992, 557816704, 484138176, 664071136, 408374672, 58708360, 213590988, 262473834, 858725727 - ], - [ - 536870912, 268435456, 402653184, 872415232, 167772160, 251658240, 478150656, 708837376, 530579456, 187695104, 1062731776, 624689152, 45481984, 530513920, 685473792, 857817088, 695328768, 217657344, 269322240, 955173888, 690146816, 481086208, 425703040, 356204096, 196147872, 588820112, 329006248, 604498324, 319202350, 730213593 - ], - [ - 536870912, 268435456, 671088640, 872415232, 436207616, 721420288, 998244352, 884998144, 333447168, 709885952, 974651392, 815529984, 802291712, 735772672, 100630528, 197181440, 576741376, 495988736, 645408768, 873223168, 757801472, 177726720, 620096384, 57138496, 572319392, 127064752, 830106792, 227453876, 48842018, 653616121 - ], - [ - 536870912, 268435456, 134217728, 469762048, 838860800, 922746880, 612368384, 197132288, 148897792, 164626432, 864550912, 608960512, 1029308416, 83558400, 319520768, 640925696, 963059712, 366522368, 444860416, 624405504, 1094144, 342463744, 488409984, 722603968, 760641952, 872506736, 1040243112, 218174836, 260075946, 490850675 - ], - [ - 536870912, 268435456, 402653184, 335544320, 637534208, 83886080, 679477248, 717225984, 740294656, 1028653056, 722993152, 146014208, 939917312, 237961216, 255033344, 124338176, 847044608, 258691072, 62699520, 181066752, 44956160, 909333248, 367603072, 935189312, 1019888608, 531366736, 179462632, 422091860, 513633902, 689625105 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 33554432, 822083584, 713031680, 297795584, 933232640, 311427072, 362283008, 428081152, 940441600, 928710656, 1026392064, 142786560, 944283648, 209547264, 62642176, 769408000, 237718016, 700840704, 569318784, 522970688, 323237344, 942546128, 344682600, 64226964, 481767306, 663703883 - ], - [ - 536870912, 268435456, 134217728, 201326592, 100663296, 956301312, 461373440, 549453824, 639631360, 653262848, 1009254400, 40632320, 852885504, 729088000, 506626048, 931086336, 718921728, 642052096, 884729856, 329485312, 172457472, 198042880, 652627328, 175949376, 305073632, 1036067952, 664820616, 825356100, 881450594, 433977139 - ], - [ - 536870912, 268435456, 134217728, 67108864, 973078528, 150994944, 142606336, 851443712, 912261120, 355467264, 376963072, 857997312, 859701248, 732495872, 632061952, 327303168, 163782656, 492982272, 909346816, 830186496, 774350336, 658361088, 925603200, 200251840, 195149856, 80742768, 101256712, 511524612, 705379202, 520074945 - ], - [ - 536870912, 268435456, 671088640, 335544320, 704643072, 83886080, 562036736, 297795584, 882900992, 506462208, 403177472, 877920256, 652869632, 644153344, 954368000, 19939328, 76029952, 940838912, 1032488960, 603282432, 442115584, 489482496, 861298560, 302675264, 624188192, 913992464, 224188296, 557787460, 676232490, 900104725 - ], - [ - 536870912, 268435456, 939524096, 872415232, 570425344, 150994944, 25165824, 809500672, 446693376, 340787200, 739770368, 15466496, 251527168, 403374080, 991526912, 913129472, 406740992, 745254912, 791205888, 742720512, 201059840, 818996992, 467251072, 957105728, 1016023456, 864237456, 873269288, 923768532, 113503750, 959244041 - ], - [ - 536870912, 805306368, 671088640, 603979776, 973078528, 16777216, 813694976, 834666496, 589299712, 600834048, 383254528, 88342528, 599392256, 849149952, 645890048, 149307392, 331587584, 927469568, 217966592, 290337792, 701396480, 202360064, 1026481280, 1006585280, 665228192, 304256144, 574139016, 45383884, 288509738, 1061212505 - ], - [ - 536870912, 805306368, 402653184, 872415232, 973078528, 16777216, 310378496, 725614592, 1012924416, 164626432, 586678272, 863240192, 347471872, 811663360, 936476672, 33079296, 351641600, 393728000, 641796096, 283186176, 26319360, 957891328, 962961024, 544153536, 606343072, 588152752, 477470728, 221761548, 278988806, 108073997 - ], - [ - 536870912, 805306368, 939524096, 738197504, 301989888, 452984832, 696254464, 675282944, 102760448, 835715072, 1045954560, 914096128, 439484416, 139526144, 504987648, 610123776, 367222784, 1057591296, 451237888, 1068403712, 869474816, 383787264, 825300608, 577248960, 546636256, 510044304, 416765960, 738167820, 130720270, 96329995 - ], - [ - 536870912, 805306368, 134217728, 603979776, 905969664, 687865856, 58720256, 88080384, 216006656, 97517568, 668467200, 83623936, 123076608, 337051648, 32931840, 262586368, 155181056, 924995584, 480581632, 753533952, 748727808, 682625280, 810076032, 558180672, 918214304, 339281936, 464279208, 776980508, 1028372138, 965842965 - ], - [ - 536870912, 805306368, 402653184, 335544320, 436207616, 452984832, 327155712, 339738624, 824180736, 74448896, 906493952, 537657344, 100270080, 389349376, 39813120, 1030995968, 234364928, 1011191808, 232175616, 171961344, 1050814976, 557944064, 329383296, 11545408, 350749408, 454895632, 497217416, 381782604, 98694502, 1049632341 - ], - [ - 536870912, 268435456, 671088640, 67108864, 301989888, 150994944, 1031798784, 390070272, 417333248, 655360000, 749207552, 515112960, 680919040, 887554048, 656375808, 56803328, 898686976, 627666944, 160806912, 732369920, 738102784, 510810368, 339241344, 341688512, 1061396320, 975181008, 1018218344, 693727444, 403468642, 889912789 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 704643072, 150994944, 192937984, 88080384, 459276288, 869269504, 783810560, 971767808, 61997056, 84738048, 656637952, 232079360, 815685632, 111022080, 362752000, 522177536, 769606144, 436139776, 944737408, 782748352, 1018306528, 495844688, 686025864, 611637964, 930002914, 160919903 - ], - [ - 536870912, 268435456, 671088640, 872415232, 100663296, 452984832, 243269632, 952107008, 161480704, 498073600, 645398528, 737935360, 212205568, 18808832, 163807232, 236240896, 265445376, 954060800, 1071106048, 499571712, 84888064, 436932352, 932241024, 780777280, 778391456, 965441552, 584156584, 224966420, 817183522, 384028761 - ], - [ - 536870912, 268435456, 671088640, 335544320, 905969664, 721420288, 645922816, 616562688, 174063616, 355467264, 495452160, 894697472, 55443456, 679936000, 359890944, 174899200, 416505856, 935153664, 715835392, 704748544, 419523072, 327201024, 1027613824, 1042322112, 277975392, 609762192, 422411112, 569592468, 195936226, 590497873 - ], - [ - 536870912, 805306368, 402653184, 67108864, 570425344, 285212672, 511705088, 725614592, 480247808, 275775488, 167247872, 892600320, 541982720, 674824192, 148209664, 564051968, 154214400, 744001536, 667174912, 620155904, 850217472, 929819904, 899659648, 53589440, 559488160, 524675568, 1018612232, 562834700, 316348294, 193455553 - ], - [ - 536870912, 268435456, 671088640, 469762048, 838860800, 788529152, 880803840, 1002438656, 958398464, 831520768, 1042808832, 435421184, 790495232, 938409984, 909606912, 379240448, 954736640, 726970368, 969885696, 388410368, 359862784, 423365376, 475733888, 273242816, 243659616, 528991888, 547560296, 393484948, 937353570, 542100883 - ], - [ - 536870912, 805306368, 671088640, 872415232, 436207616, 251658240, 394264576, 423624704, 144703488, 978321408, 790102016, 1062469632, 900333568, 919273472, 502956032, 315867136, 120479744, 87601152, 885377024, 886240256, 372145664, 800594688, 17127808, 682785088, 849326048, 634425520, 844713960, 99934396, 888825826, 340944049 - ], - [ - 536870912, 268435456, 402653184, 872415232, 167772160, 654311424, 310378496, 843055104, 56623104, 441450496, 8912896, 802947072, 38141952, 970784768, 323387392, 710787072, 713498624, 620597248, 880154624, 495256576, 810781184, 698818304, 1053579392, 774806336, 328296032, 103410032, 489445512, 87989060, 284780134, 317057405 - ], - [ - 536870912, 805306368, 134217728, 201326592, 570425344, 520093696, 494927872, 448790528, 270532608, 984612864, 957874176, 1006895104, 411172864, 254738432, 783319040, 790216704, 84156416, 872640512, 896460800, 651203584, 46791168, 206337792, 462300288, 306246976, 878820576, 131161648, 440961640, 269305980, 586082314, 521180175 - ], - [ - 536870912, 268435456, 939524096, 469762048, 905969664, 452984832, 998244352, 926941184, 606076928, 858783744, 480772096, 214695936, 898236416, 560660480, 658210816, 260194304, 190226432, 804851712, 150259712, 866096128, 296021504, 447131392, 925943424, 648567744, 432927136, 151760880, 464179624, 794558452, 588462502, 328154099 - ], - [ - 536870912, 268435456, 134217728, 335544320, 369098752, 520093696, 75497472, 390070272, 60817408, 621805568, 731381760, 538181632, 991559680, 391708672, 678723584, 384450560, 410099712, 266874880, 1039972352, 132547584, 524225024, 847996160, 796970112, 365004480, 65097120, 909121616, 264866312, 388769028, 983559298, 278591173 - ], - [ - 536870912, 268435456, 134217728, 872415232, 234881024, 855638016, 360710144, 717225984, 111149056, 1049624576, 642252800, 861143040, 181534720, 335216640, 488603648, 768983040, 429088768, 228233216, 741328896, 495748096, 13566464, 234708736, 670457728, 219215808, 461905504, 645202288, 428080232, 680726132, 152767466, 309259705 - ], - [ - 536870912, 268435456, 939524096, 469762048, 771751936, 452984832, 427819008, 683671552, 81788928, 1041235968, 230162432, 43253760, 856031232, 711000064, 156270592, 513392640, 333766656, 493842432, 590206976, 932334592, 644318720, 145835776, 168411264, 186488256, 31148192, 534410800, 752541704, 291139588, 194729998, 981109767 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 369098752, 754974720, 444596224, 515899392, 119537664, 613416960, 566755328, 656146432, 54657024, 670892032, 947027968, 56934400, 604463104, 1021997056, 252774400, 596190208, 738049536, 108248320, 711264896, 344329024, 422248032, 1068612432, 56158856, 332708676, 48141934, 746581855 - ], - [ - 536870912, 268435456, 134217728, 738197504, 301989888, 788529152, 763363328, 289406976, 257949696, 579862528, 935854080, 562298880, 372113408, 629342208, 813268992, 809287680, 716382208, 369160192, 16869376, 411063296, 1069581824, 564158720, 330307456, 934921920, 630995040, 251905616, 817465832, 874353044, 71519754, 1020790031 - ], - [ - 536870912, 268435456, 402653184, 67108864, 369098752, 654311424, 125829120, 884998144, 471859200, 294649856, 344457216, 985399296, 210370560, 1042481152, 672104448, 445464576, 408051712, 582438912, 535308288, 97383424, 716325376, 34007808, 678544256, 700026304, 350521120, 241091312, 329557288, 952072692, 622153390, 673644597 - ], - [ - 536870912, 268435456, 134217728, 335544320, 637534208, 855638016, 612368384, 843055104, 216006656, 1051721728, 359137280, 450625536, 492175360, 995295232, 858882048, 313049088, 503111680, 516395008, 749447168, 261438464, 379221504, 951850240, 145130112, 257603264, 10346912, 364345936, 736279848, 22603156, 183871498, 32128001 - ], - [ - 536870912, 268435456, 939524096, 201326592, 369098752, 184549376, 528482304, 406847488, 362807296, 802160640, 115867648, 892600320, 431882240, 608239616, 731938816, 282181632, 57171968, 812953600, 413030400, 206699520, 547897856, 529886464, 871308928, 669615936, 531984800, 562033136, 740327432, 345096196, 952655886, 413446147 - ], - [ - 536870912, 805306368, 939524096, 872415232, 704643072, 822083584, 964689920, 104857600, 1042284544, 11534336, 133693440, 150208512, 86638592, 458424320, 635863040, 653082624, 152035328, 17838080, 503904256, 732746752, 934270464, 845176576, 1066520192, 113887040, 1028517856, 436138032, 801651176, 13479740, 230651750, 350824561 - ], - [ - 536870912, 805306368, 939524096, 201326592, 167772160, 218103808, 612368384, 943718400, 576716800, 1007681536, 172490752, 342097920, 851050496, 609550336, 696483840, 468238336, 534110208, 71536640, 390662144, 954528768, 1056598528, 3495680, 311685760, 941746496, 393316256, 752457104, 762092168, 658394444, 993985966, 960472723 - ], - [ - 536870912, 268435456, 939524096, 67108864, 637534208, 922746880, 612368384, 373293056, 618659840, 1055916032, 323485696, 254017536, 664403968, 664993792, 705658880, 177225728, 905535488, 864866304, 281978880, 338734080, 904441344, 188051712, 958546560, 961444544, 603008224, 180992944, 283454184, 616261300, 510805606, 647441781 - ], - [ - 536870912, 268435456, 671088640, 201326592, 436207616, 452984832, 830472192, 759169024, 903872512, 667942912, 336068608, 1036255232, 512098304, 362217472, 557809664, 717930496, 294952960, 751792128, 70395904, 958948352, 78982656, 834580736, 1024182144, 280286144, 532630496, 403325648, 741663720, 41936596, 707456482, 583329751 - ], - [ - 536870912, 805306368, 134217728, 738197504, 167772160, 318767104, 92274688, 96468992, 203423744, 420478976, 642252800, 369885184, 900071424, 803667968, 218529792, 968278016, 623878144, 4976640, 745629696, 272122880, 758508032, 957598464, 892691328, 756187584, 456419744, 403851408, 129296808, 190023836, 198560170, 463648919 - ], - [ - 536870912, 805306368, 402653184, 469762048, 637534208, 587202560, 1065353216, 868220928, 811597824, 334495744, 354942976, 639369216, 446562304, 80281600, 153976832, 1045872640, 1038475264, 796569600, 531814400, 882875392, 331935232, 346897152, 345404288, 923074368, 332064736, 918221168, 47386120, 1072597772, 815868806, 873571143 - ], - [ - 536870912, 268435456, 402653184, 872415232, 167772160, 620756992, 494927872, 507510784, 425721856, 487587840, 465043456, 249823232, 261750784, 1018494976, 180518912, 201441280, 771825664, 922783744, 209750016, 163625984, 572643840, 435169024, 417864320, 205264576, 477011872, 681025808, 949097096, 156854980, 515138982, 331486749 - ], - [ - 536870912, 268435456, 402653184, 335544320, 33554432, 251658240, 578813952, 784334848, 1063256064, 770703360, 352845824, 627834880, 512884736, 6225920, 526221312, 192561152, 327376896, 870789120, 270084096, 450202624, 131469824, 485573888, 646539392, 674045376, 884128288, 328150384, 461714088, 634339508, 19251342, 266260929 - ], - [ - 536870912, 805306368, 671088640, 603979776, 100663296, 654311424, 25165824, 381681664, 379584512, 510656512, 258473984, 557056000, 638451712, 130744320, 99385344, 695386112, 121724928, 408981504, 80758784, 857216000, 257722880, 565918464, 914705024, 38256320, 609191904, 1059809872, 830244200, 462143644, 369952898, 1046630853 - ], - [ - 536870912, 805306368, 939524096, 738197504, 704643072, 822083584, 478150656, 1019215872, 908066816, 680525824, 239599616, 620494848, 377356288, 890044416, 566722560, 38322176, 1056759808, 528388096, 93186048, 923153408, 90746368, 183350528, 771109504, 391129920, 166221664, 1043165104, 265730696, 968970060, 480276846, 928104123 - ], - [ - 536870912, 268435456, 939524096, 469762048, 436207616, 788529152, 847249408, 180355072, 698351616, 951058432, 326631424, 600571904, 14811136, 887422976, 973504512, 266518528, 375742464, 147296256, 977491968, 886318080, 884915712, 722436352, 1056421760, 704276672, 700046048, 577629008, 475246984, 563977668, 751463278, 310408855 - ], - [ - 536870912, 268435456, 134217728, 738197504, 637534208, 620756992, 343932928, 297795584, 786432000, 466616320, 1048051712, 710148096, 200146944, 485556224, 1061715968, 234635264, 818110464, 717893632, 135702528, 98919424, 646393344, 482109184, 501425792, 955912128, 373207200, 394916464, 161302536, 1003688964, 617801218, 726872843 - ], - [ - 536870912, 268435456, 402653184, 201326592, 436207616, 620756992, 578813952, 138412032, 559939584, 397410304, 394788864, 208928768, 819068928, 19333120, 775258112, 1018314752, 538419200, 670904320, 782743552, 16096256, 462644736, 633827584, 977562240, 983287744, 938680032, 351696816, 730690664, 613331060, 219277966, 228165575 - ], - [ - 536870912, 268435456, 134217728, 67108864, 33554432, 452984832, 780140544, 960495616, 1038090240, 298844160, 633864192, 184811520, 79560704, 605356032, 139886592, 417415168, 978362368, 654856192, 1009055744, 642737152, 556536320, 493492992, 669123712, 403136832, 820577952, 586494896, 654736520, 208160068, 146093218, 812071089 - ], - [ - 536870912, 805306368, 134217728, 67108864, 369098752, 218103808, 780140544, 507510784, 278921216, 642777088, 246939648, 431751168, 426901504, 558039040, 1045069824, 792641536, 274259968, 390942720, 1033549824, 608603136, 629530112, 881765120, 1066488192, 148381760, 873306016, 196771120, 408375208, 765223228, 107104682, 115070525 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 973078528, 50331648, 1065353216, 180355072, 782237696, 1028653056, 93847552, 636747776, 354287616, 335347712, 97746944, 860241920, 1009344512, 215814144, 121812992, 922668032, 785194496, 1035620608, 729538688, 266059712, 428587040, 529705648, 178767496, 840524492, 590620330, 700339327 - ], - [ - 536870912, 805306368, 939524096, 335544320, 33554432, 922746880, 8388608, 213909504, 1038090240, 219152384, 889716736, 971767808, 802553856, 766705664, 642285568, 340541440, 1038573568, 155955200, 305997824, 205519872, 936247808, 290961664, 141782912, 36281536, 874312992, 206565584, 991402152, 877843740, 291013126, 38074633 - ], - [ - 536870912, 268435456, 671088640, 469762048, 771751936, 989855744, 226492416, 1002438656, 631242752, 9437184, 739770368, 808189952, 275120128, 873398272, 726368256, 300466176, 277159936, 755159040, 352143360, 656294912, 1066543616, 1038483200, 162678656, 95760704, 965450016, 1019827344, 894720808, 251395988, 337764002, 89155027 - ], - [ - 536870912, 805306368, 939524096, 603979776, 436207616, 553648128, 1048576000, 926941184, 396361728, 200278016, 315097088, 20709376, 339607552, 291569664, 647069696, 978960384, 946151424, 400216064, 360318976, 839611392, 713226752, 1017044224, 789639040, 613953088, 17090016, 491395056, 690135048, 359534604, 953722894, 19227657 - ], - [ - 536870912, 805306368, 134217728, 201326592, 100663296, 922746880, 276824064, 633339904, 169869312, 1041235968, 284688384, 1059848192, 95551488, 395771904, 1069580288, 52543488, 495984640, 800608256, 567117824, 369310720, 205433344, 1073086208, 227434880, 559699776, 674934432, 666049776, 446123304, 373299388, 224428042, 619823119 - ], - [ - 536870912, 268435456, 939524096, 738197504, 33554432, 989855744, 25165824, 801112064, 1012924416, 116391936, 1033371648, 574357504, 158203904, 555286528, 830242816, 911196160, 550002688, 557092864, 104470528, 584215552, 62320128, 973372160, 348265344, 329196224, 914479840, 1010890992, 278982152, 387021572, 380148622, 415621835 - ], - [ - 536870912, 268435456, 671088640, 469762048, 570425344, 922746880, 8388608, 675282944, 807403520, 831520768, 688390144, 520880128, 487194624, 161021952, 126124032, 197607424, 91480064, 845975552, 993687552, 297837568, 903885312, 712009984, 1048105088, 183836224, 490701664, 1002955216, 1030900232, 107793668, 87745162, 79722311 - ], - [ - 536870912, 805306368, 671088640, 469762048, 771751936, 486539264, 8388608, 171966464, 106954752, 714080256, 390594560, 181141504, 65667072, 547291136, 392200192, 470859776, 873046016, 1043173376, 272340992, 741862400, 1039980032, 76718336, 850118528, 394198720, 825275424, 108561712, 1018535336, 392079100, 734109698, 312578059 - ], - [ - 536870912, 268435456, 671088640, 469762048, 301989888, 989855744, 645922816, 608174080, 1050673152, 758120448, 46661632, 952369152, 423231488, 275841024, 434667520, 590692352, 252895232, 304451584, 850089984, 193557504, 769999360, 734668032, 467227008, 427635264, 311852064, 876603600, 522967048, 826815492, 50700810, 911914247 - ], - [ - 536870912, 805306368, 134217728, 603979776, 301989888, 1023410176, 880803840, 1019215872, 966787072, 888143872, 376963072, 373555200, 315752448, 419627008, 172654592, 257343488, 670162944, 301494272, 486807552, 674495488, 856832512, 606267136, 175827072, 76472128, 390404960, 676505840, 650306408, 208282876, 484852074, 1030356981 - ], - [ - 536870912, 805306368, 939524096, 335544320, 234881024, 687865856, 260046848, 297795584, 715128832, 105906176, 754450432, 538181632, 1029832704, 255000576, 499810304, 752828416, 171827200, 449744896, 77944832, 564814848, 380570112, 114609920, 960734592, 992192064, 273886432, 121325808, 997618920, 122760444, 1064926950, 332784633 - ], - [ - 536870912, 805306368, 671088640, 469762048, 234881024, 117440512, 729808896, 918552576, 824180736, 47185920, 344457216, 915144704, 600440832, 176750592, 697139200, 1011564544, 776593408, 296611840, 303790080, 662748160, 549471744, 35713280, 995207808, 726229568, 724305248, 1012552912, 434128392, 753987852, 165259914, 113599047 - ], - [ - 536870912, 805306368, 939524096, 201326592, 905969664, 1023410176, 746586112, 482344960, 23068672, 1051721728, 742916096, 203685888, 603324416, 266141696, 689668096, 969850880, 617668608, 192540672, 606881792, 141734912, 419151360, 633210624, 16332672, 795717440, 1012109216, 459976816, 484884872, 574954572, 1053230638, 752097331 - ], - [ - 536870912, 268435456, 134217728, 603979776, 33554432, 922746880, 260046848, 222298112, 434110464, 363855872, 462946304, 94633984, 951975936, 209256448, 286556160, 296108032, 404496384, 814387200, 734984192, 289463296, 669039104, 212866816, 85582208, 845487808, 345974304, 48791152, 194812424, 63604484, 724507010, 443663049 - ], - [ - 536870912, 805306368, 134217728, 469762048, 973078528, 1056964608, 545259520, 658505728, 291504128, 347078656, 74973184, 742129664, 878051328, 482017280, 967081984, 463192064, 905289728, 26390528, 672229376, 568957952, 420851200, 165849344, 348781184, 910541888, 157977888, 292338896, 668975016, 194925724, 746583178, 311352651 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 973078528, 788529152, 394264576, 88080384, 601882624, 829423616, 285736960, 883163136, 672792576, 36110336, 308379648, 825311232, 845684736, 722743296, 632465408, 185779200, 226694656, 335246592, 525808768, 23688128, 378873184, 938660336, 57905128, 62006068, 236068870, 218312715 - ], - [ - 536870912, 805306368, 671088640, 872415232, 234881024, 385875968, 360710144, 104857600, 148897792, 1037041664, 46661632, 418119680, 920780800, 948895744, 598507520, 713211904, 497016832, 4542464, 404621312, 503706624, 218025472, 433388800, 389520768, 62478016, 840186912, 899106288, 612999592, 537727804, 590552450, 239572673 - ], - [ - 536870912, 805306368, 402653184, 738197504, 503316480, 184549376, 1031798784, 4194304, 1059061760, 391118848, 318242816, 585367552, 377356288, 630784000, 244678656, 970375168, 746872832, 311390208, 1022466048, 90770432, 234631680, 321569024, 472819328, 98586048, 1001407008, 701082480, 166580744, 796094732, 937123462, 893792715 - ], - [ - 536870912, 805306368, 671088640, 67108864, 301989888, 184549376, 310378496, 1002438656, 6291456, 32505856, 688390144, 108265472, 908460032, 653066240, 749436928, 95830016, 890544128, 961957888, 170145792, 935306240, 971068928, 414281472, 984126848, 65334592, 215890720, 43020528, 242834312, 784102988, 1060356266, 297424561 - ], - [ - 536870912, 805306368, 671088640, 603979776, 301989888, 218103808, 327155712, 440401920, 329252864, 384827392, 936902656, 61603840, 242876416, 816644096, 385581056, 241975296, 630890496, 285003776, 5425152, 844647424, 921442816, 727437568, 194784640, 985837504, 93343968, 424242192, 241446280, 148811724, 336744682, 49835033 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 771751936, 788529152, 696254464, 364904448, 819986432, 821035008, 940048384, 1024196608, 1018822656, 731316224, 247234560, 538132480, 659169280, 404623360, 1064323072, 382243840, 778940928, 613073152, 201213056, 268459456, 671157536, 604078896, 302115240, 16813820, 109087886, 1010862531 - ], - [ - 536870912, 805306368, 671088640, 67108864, 100663296, 1023410176, 964689920, 339738624, 102760448, 948961280, 400031744, 144441344, 582615040, 983629824, 156336128, 800669696, 153886720, 259141632, 891611136, 144067584, 491971072, 330600704, 240071808, 776943296, 508500192, 911192016, 843980808, 877604876, 156198922, 818809857 - ], - [ - 536870912, 268435456, 402653184, 738197504, 838860800, 587202560, 142606336, 767557632, 547356672, 380633088, 1054343168, 586416128, 779223040, 722141184, 735019008, 1017462784, 452665344, 863449088, 348153856, 790662144, 905024000, 246996736, 224679552, 5970496, 851869408, 1016625648, 823446760, 279156468, 373486190, 353566911 - ], - [ - 536870912, 268435456, 939524096, 738197504, 771751936, 721420288, 578813952, 884998144, 723517440, 317718528, 92798976, 157548544, 506068992, 356843520, 677019648, 453820416, 715120640, 639086592, 418625536, 60302336, 129818112, 217554176, 10713472, 379701568, 380663456, 661231120, 355768712, 823294276, 759811758, 608481819 - ], - [ - 536870912, 805306368, 402653184, 603979776, 503316480, 1023410176, 1031798784, 281018368, 492830720, 103809024, 87556096, 672923648, 709754880, 355139584, 274235392, 573390848, 225959936, 976670720, 613914624, 658916352, 755894784, 327941376, 931701376, 912559168, 250805024, 599042960, 901436328, 45193948, 108653070, 12397829 - ], - [ - 536870912, 805306368, 939524096, 469762048, 301989888, 754974720, 578813952, 423624704, 870318080, 967835648, 845676544, 827588608, 532545536, 112001024, 160661504, 192856064, 730619904, 469946368, 604456960, 501343232, 917598720, 99140352, 378823552, 656358976, 570205216, 550174000, 285456776, 914819404, 1017191854, 424735863 - ], - [ - 536870912, 805306368, 402653184, 469762048, 771751936, 285212672, 578813952, 322961408, 559939584, 797966336, 904396800, 469499904, 700841984, 482934784, 613253120, 629063680, 796778496, 126283776, 690571264, 358380544, 1031219712, 424698624, 407410816, 315456832, 211689696, 816634032, 244271624, 1032082188, 433205382, 670234951 - ], - [ - 536870912, 805306368, 134217728, 335544320, 301989888, 117440512, 931135488, 197132288, 861929472, 204472320, 801636352, 595329024, 24772608, 929366016, 532643840, 218841088, 369893376, 512970752, 185194496, 60558336, 478852608, 953007872, 359830400, 796508992, 116686176, 128424464, 768597384, 627187788, 564134114, 835824213 - ], - [ - 536870912, 268435456, 671088640, 335544320, 234881024, 520093696, 260046848, 977272832, 60817408, 412090368, 26738688, 309592064, 381550592, 810745856, 303661056, 573947904, 740286464, 742641664, 675350528, 379667456, 772820480, 1062805248, 705974656, 684608576, 628765024, 589588816, 616967912, 1522196, 422465026, 977936129 - ], - [ - 536870912, 805306368, 939524096, 738197504, 771751936, 721420288, 914358272, 20971520, 195035136, 1018167296, 134742016, 365690880, 584187904, 432734208, 851345408, 480854016, 771563520, 379310080, 908478464, 891100160, 747283968, 186532608, 488186496, 343249088, 446121888, 890590896, 759597480, 734910908, 30623014, 994776695 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 100663296, 385875968, 192937984, 373293056, 350224384, 554696704, 905445376, 735313920, 736231424, 212271104, 603750400, 602816512, 547430400, 686837760, 912869376, 686621696, 253156864, 334867712, 617771904, 695129408, 576796256, 634485040, 802688488, 971352188, 749430150, 1006320707 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 436207616, 855638016, 931135488, 12582912, 195035136, 483393536, 339214336, 456392704, 830603264, 504430592, 681082880, 1046822912, 813424640, 268816384, 25892864, 145619968, 342320640, 480955648, 1010638464, 247336384, 523167648, 594992400, 817076232, 890813444, 899974666, 408624399 - ], - [ - 536870912, 268435456, 402653184, 738197504, 704643072, 318767104, 260046848, 197132288, 794820608, 321912832, 503840768, 952369152, 85590016, 590807040, 370769920, 425476096, 730308608, 366030848, 804866048, 220996608, 112148992, 914715904, 582744704, 149411264, 1021413472, 988906992, 375951592, 578098484, 701639182, 672342287 - ], - [ - 536870912, 268435456, 134217728, 872415232, 369098752, 150994944, 8388608, 541065216, 811597824, 200278016, 242745344, 994836480, 642121728, 625016832, 182484992, 145768448, 362389504, 259829760, 832456704, 89981952, 957317632, 592757504, 133922688, 838828992, 380482144, 192366128, 974684168, 1052524548, 490708994, 1015918605 - ], - [ - 536870912, 268435456, 134217728, 872415232, 570425344, 184549376, 1031798784, 4194304, 891289600, 324009984, 365428736, 988545024, 798359552, 772734976, 850100224, 848412672, 648634368, 1033695232, 730785792, 518759424, 430978560, 687376128, 1020580224, 665005504, 966634400, 294597008, 703296936, 842011284, 28938794, 1064613977 - ], - [ - 536870912, 805306368, 671088640, 738197504, 436207616, 520093696, 310378496, 985661440, 996147200, 399507456, 846725120, 1033633792, 818020352, 575078400, 633896960, 213172224, 686170112, 905490432, 316516352, 669199360, 37167616, 1040211200, 419519872, 1065457984, 457185568, 153197040, 158353064, 206106044, 586459650, 71811335 - ], - [ - 536870912, 805306368, 939524096, 872415232, 838860800, 486539264, 1031798784, 499122176, 593494016, 529530880, 1006108672, 254541824, 182059008, 225378304, 520650752, 793001984, 873357312, 563687424, 389871616, 1038271488, 446931456, 948102400, 439504768, 469380928, 22952096, 494972080, 767669544, 459364092, 730937862, 167317761 - ], - [ - 536870912, 268435456, 402653184, 738197504, 234881024, 922746880, 260046848, 960495616, 878706688, 66060288, 824705024, 379322368, 458620928, 676790272, 232226816, 966213632, 393617408, 457592832, 533719040, 134452224, 749493760, 350158080, 639328896, 188263360, 872726304, 671348112, 1017954088, 216003988, 169525038, 87618975 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 301989888, 150994944, 746586112, 910163968, 236978176, 839909376, 657981440, 1007419392, 121503744, 948109312, 760578048, 201539584, 924131328, 673443840, 805574656, 832195584, 860390912, 335866624, 261870976, 273265472, 226876576, 123368208, 556347688, 490044500, 607384454, 876472395 - ], - [ - 536870912, 805306368, 402653184, 67108864, 234881024, 1056964608, 411041792, 859832320, 216006656, 657457152, 772276224, 824967168, 887488512, 609943552, 518291456, 996884480, 82698240, 474468352, 185223168, 782081024, 430861824, 26731776, 154356352, 1060641728, 337953312, 189454800, 419209384, 551538204, 251634830, 99598029 - ], - [ - 536870912, 805306368, 402653184, 201326592, 637534208, 50331648, 1048576000, 624951296, 392167424, 495976448, 1041760256, 214171648, 553517056, 805896192, 236814336, 312131584, 373776384, 293449728, 722163712, 442389504, 884537856, 276091648, 848797824, 906329792, 761224992, 272202864, 137732616, 343377676, 374659718, 577138115 - ], - [ - 536870912, 268435456, 671088640, 603979776, 704643072, 889192448, 511705088, 952107008, 1042284544, 567279616, 49807360, 477364224, 706871296, 1063714816, 122519552, 83345408, 894787584, 343076864, 434026496, 215612416, 94740992, 618397440, 756251520, 846178112, 269523296, 341405232, 375765736, 863634804, 998463874, 49780813 - ], - [ - 536870912, 805306368, 134217728, 201326592, 1040187392, 218103808, 260046848, 817889280, 673185792, 523239424, 648544256, 1065091072, 775028736, 321323008, 541622272, 896385024, 271196160, 909283328, 656873472, 440980480, 174873088, 749410048, 74662016, 809937088, 496606368, 466981232, 709756456, 865463996, 841939466, 12863247 - ], - [ - 536870912, 805306368, 939524096, 335544320, 33554432, 218103808, 159383552, 801112064, 736100352, 200278016, 447217664, 1026293760, 897712128, 663158784, 518553600, 67911680, 605249536, 220180480, 277673984, 173171712, 624906752, 647762176, 336279680, 104517312, 141704736, 36658288, 524571816, 63865788, 95801862, 1055346953 - ], - [ - 536870912, 268435456, 671088640, 738197504, 704643072, 620756992, 176160768, 130023424, 413138944, 770703360, 836239360, 758382592, 322306048, 1638400, 43286528, 356990976, 981491712, 1069666304, 480274432, 737227776, 1054436864, 45477120, 511130496, 528003264, 935668896, 158250544, 644738568, 29535492, 261053322, 696082635 - ], - [ - 536870912, 268435456, 671088640, 201326592, 369098752, 822083584, 494927872, 255852544, 455081984, 290455552, 112721920, 527171584, 169738240, 745996288, 1021542400, 733003776, 218734592, 40210432, 544954368, 840704, 720346624, 811470592, 551012736, 770840128, 380202016, 133522000, 732146216, 76593492, 777551266, 802971671 - ], - [ - 536870912, 268435456, 134217728, 201326592, 973078528, 922746880, 864026624, 29360128, 287309824, 462422016, 750256128, 860094464, 390987776, 263651328, 957579264, 611172352, 414359552, 599584768, 770344960, 684241920, 852281856, 753044224, 388268928, 935328832, 746509664, 442413200, 978296680, 456588180, 55721194, 948713431 - ], - [ - 536870912, 268435456, 134217728, 738197504, 771751936, 855638016, 696254464, 281018368, 606076928, 185597952, 184025088, 472121344, 853147648, 376635392, 38764544, 344047616, 440508416, 358633472, 334596096, 197764096, 785142272, 226945792, 676134784, 46640704, 195931744, 108445744, 126219368, 772493108, 455834090, 884710015 - ], - [ - 536870912, 268435456, 939524096, 201326592, 167772160, 855638016, 343932928, 398458880, 207618048, 336592896, 35127296, 299106304, 626917376, 787808256, 49184768, 10272768, 53665792, 252612608, 1053587456, 84653056, 166430208, 473659136, 323196544, 1023897536, 318784544, 75566896, 801240712, 6307780, 504388654, 823716659 - ], - [ - 536870912, 805306368, 402653184, 872415232, 771751936, 754974720, 260046848, 817889280, 350224384, 477102080, 833093632, 122945536, 980549632, 271777792, 1066565632, 834813952, 301719552, 452366336, 196737024, 1036813312, 78545408, 1065739520, 990520960, 169778112, 499984736, 883922672, 663071080, 252368636, 605997422, 818743025 - ], - [ - 536870912, 805306368, 671088640, 67108864, 973078528, 587202560, 729808896, 675282944, 199229440, 336592896, 498597888, 888930304, 899284992, 515047424, 255229952, 712097792, 149479424, 35958784, 313976832, 791712768, 428377600, 854917376, 1026530688, 259834432, 98267808, 961805040, 623320232, 784953340, 882149154, 880700605 - ], - [ - 536870912, 268435456, 671088640, 67108864, 167772160, 989855744, 746586112, 935329792, 962592768, 460324864, 268959744, 777256960, 1029308416, 378208256, 764641280, 859750400, 628678656, 526233600, 747563008, 881970176, 1069142528, 129861888, 834660992, 867794624, 431864416, 683599792, 540553832, 150756276, 488630370, 782872245 - ], - [ - 536870912, 805306368, 402653184, 335544320, 436207616, 654311424, 931135488, 331350016, 14680064, 105906176, 363331584, 884736000, 1042415616, 875233280, 73826304, 194789376, 110354432, 47427584, 569624576, 1061295104, 951777792, 61805824, 775005056, 330902720, 808816672, 1060017328, 879757864, 630813116, 839188910, 311867769 - ], - [ - 536870912, 268435456, 671088640, 469762048, 167772160, 50331648, 411041792, 784334848, 941621248, 1009778688, 175636480, 748945408, 51511296, 78577664, 726237184, 995999744, 955752448, 383627264, 397854720, 867998720, 971493888, 420783872, 405428352, 409691712, 395000032, 538634416, 1007850088, 103700980, 780737026, 133970691 - ], - [ - 536870912, 268435456, 939524096, 335544320, 167772160, 855638016, 109051904, 692060160, 736100352, 17825792, 79167488, 18612224, 975831040, 411631616, 596934656, 46120960, 817340416, 610521088, 876468224, 807130112, 1057061376, 142653184, 675296384, 174089152, 617642464, 890787024, 762151432, 381842180, 919451278, 431100101 - ], - [ - 536870912, 805306368, 671088640, 872415232, 167772160, 956301312, 662700032, 88080384, 257949696, 361758720, 361234432, 594804736, 438960128, 523304960, 783908864, 533544960, 552050688, 643256320, 1051674624, 813890560, 657738240, 516639488, 434164864, 860891200, 1034474912, 881185872, 934504456, 361622540, 1057432074, 168208141 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 637534208, 1056964608, 612368384, 473956352, 715128832, 275775488, 777519104, 1029439488, 736755712, 123535360, 585793536, 886849536, 640376832, 608006144, 603625472, 1049908224, 750680576, 42139904, 276429184, 158200768, 991089504, 812747920, 1046083976, 358478788, 401265514, 559778975 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 503316480, 922746880, 444596224, 507510784, 836763648, 691011584, 558366720, 287047680, 709230592, 7929856, 475299840, 224083968, 557768704, 414019584, 944666624, 117797888, 249782784, 810190592, 124142976, 48831552, 801926624, 20910256, 145562120, 273675012, 990193546, 283351887 - ], - [ - 536870912, 805306368, 671088640, 738197504, 301989888, 117440512, 897581056, 406847488, 106954752, 179306496, 274202624, 259784704, 362414080, 261816320, 345669632, 454803456, 677027840, 163196928, 474613760, 1072931840, 578774528, 568153344, 730464384, 986841664, 556710304, 141833584, 357480872, 902051196, 412531106, 251147639 - ], - [ - 536870912, 268435456, 671088640, 469762048, 33554432, 822083584, 1031798784, 440401920, 555745280, 745537536, 56098816, 208404480, 732299264, 270336000, 285114368, 678445056, 626548736, 191713280, 958883840, 81591296, 656398848, 48276736, 823251328, 151536576, 834955488, 810728432, 3586440, 30719940, 1021031146, 531767031 - ], - [ - 536870912, 268435456, 134217728, 67108864, 771751936, 889192448, 310378496, 213909504, 878706688, 112197632, 1035468800, 61079552, 834273280, 110559232, 57769984, 693682176, 517234688, 904089600, 113498112, 273857536, 16462336, 800466176, 383846016, 309452864, 98163936, 789945072, 386019432, 582214580, 747264010, 393116677 - ], - [ - 536870912, 268435456, 671088640, 67108864, 33554432, 16777216, 243269632, 1002438656, 757071872, 191889408, 163053568, 917241856, 619315200, 1045233664, 1035632640, 486817792, 820944896, 337793024, 945399808, 226337792, 979547648, 490220800, 812457344, 692721856, 167601376, 346246544, 345587080, 98306244, 22179050, 249608593 - ], - [ - 536870912, 268435456, 671088640, 469762048, 33554432, 922746880, 612368384, 322961408, 1046478848, 737148928, 694681600, 470548480, 310509568, 347275264, 66813952, 417775616, 851189760, 1015754752, 449775616, 617737216, 469358080, 303322368, 682091136, 643683776, 423304096, 38248112, 653104040, 976466612, 733734306, 671487923 - ], - [ - 536870912, 805306368, 402653184, 469762048, 905969664, 117440512, 1048576000, 943718400, 908066816, 862978048, 174587904, 28573696, 371064832, 68878336, 957120512, 57884672, 121184256, 212652032, 801327104, 1051732992, 612894208, 1067748096, 229064320, 905362112, 728717280, 628265680, 674865512, 908870684, 1032016014, 965856715 - ], - [ - 536870912, 805306368, 134217728, 603979776, 905969664, 822083584, 209715200, 834666496, 987758592, 76546048, 548929536, 367788032, 308412416, 369426432, 483885056, 295387136, 768188416, 38039552, 125233152, 69989376, 268514816, 939653888, 738242176, 302107840, 117531872, 1031822928, 1027666056, 186680268, 1047616610, 606607769 - ], - [ - 536870912, 268435456, 939524096, 603979776, 973078528, 956301312, 461373440, 666894336, 102760448, 466616320, 434634752, 671350784, 575537152, 105971712, 153649152, 245743616, 417275904, 534302720, 572344320, 863181824, 326311424, 57827584, 997414528, 527659840, 628280864, 477256560, 133384200, 540154884, 638819854, 1036230921 - ], - [ - 536870912, 805306368, 134217728, 335544320, 301989888, 318767104, 964689920, 675282944, 836763648, 542113792, 779616256, 210501632, 719978496, 700252160, 402882560, 912867328, 722804736, 439799808, 724514816, 1010031616, 771824128, 620831488, 813707392, 381703360, 840999648, 720384656, 105392264, 719608012, 973013218, 797609365 - ], - [ - 536870912, 805306368, 402653184, 335544320, 838860800, 419430400, 830472192, 88080384, 1046478848, 951058432, 410517504, 22806528, 420872192, 279117824, 448823296, 740376576, 273702912, 722022400, 948262912, 861619200, 601662976, 282482944, 805566080, 340862528, 822614304, 763652688, 618328488, 228335900, 104235022, 1014120457 - ], - [ - 536870912, 268435456, 402653184, 872415232, 167772160, 687865856, 662700032, 826277888, 551550976, 504365056, 688390144, 988020736, 392822784, 675872768, 302284800, 628801536, 1061199872, 199282688, 1016170496, 29924352, 138795520, 656035584, 160484480, 273171008, 906235936, 930868176, 574708232, 643862276, 617639046, 111710797 - ], - [ - 536870912, 805306368, 134217728, 469762048, 436207616, 419430400, 92274688, 675282944, 94371840, 898629632, 608698368, 94109696, 232128512, 878116864, 907444224, 582402048, 245768192, 414117888, 26359808, 1012143104, 67786240, 841022208, 684824448, 912889280, 491637024, 868179856, 891013416, 531128220, 246237482, 344891291 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 570425344, 889192448, 343932928, 264241152, 199229440, 95420416, 244842496, 1020002304, 264896512, 634322944, 518029312, 556875776, 425271296, 187494400, 679131136, 508955648, 917264896, 557539584, 930501248, 276572480, 131230368, 1002615856, 843840040, 747569276, 935403534, 132182019 - ], - [ - 536870912, 268435456, 402653184, 603979776, 503316480, 352321536, 159383552, 884998144, 761266176, 510656512, 452460544, 328466432, 862322688, 595263488, 938573824, 1043873792, 653647872, 152555520, 662919168, 828728320, 81766912, 827206912, 327665792, 130759744, 224972640, 509443472, 632026600, 26806484, 887445518, 35546125 - ], - [ - 536870912, 805306368, 939524096, 67108864, 704643072, 352321536, 444596224, 868220928, 962592768, 739246080, 820510720, 679215104, 928382976, 291831808, 51609600, 507953152, 856465408, 615452672, 1047545856, 829957120, 416654848, 554407680, 1065515648, 946862656, 9469024, 136881008, 211629192, 587618636, 464283886, 417212977 - ], - [ - 536870912, 268435456, 671088640, 872415232, 704643072, 520093696, 662700032, 71303168, 572522496, 99614720, 813170688, 615776256, 396754944, 198901760, 470908928, 535412736, 85778432, 127594496, 439396352, 404308992, 509894144, 783192832, 383217280, 375575616, 63265376, 589290128, 848249576, 908532180, 916178946, 816935945 - ], - [ - 536870912, 268435456, 134217728, 469762048, 436207616, 218103808, 847249408, 348127232, 232783872, 59768832, 775421952, 349437952, 457834496, 920322048, 65241088, 985120768, 381493248, 298250240, 93657088, 770395136, 384485888, 728388864, 338317696, 965405760, 876331232, 737292208, 885971176, 206136244, 997987050, 950482611 - ], - [ - 536870912, 268435456, 134217728, 469762048, 234881024, 687865856, 260046848, 415236096, 245366784, 573571072, 375914496, 80478208, 155582464, 244645888, 719486976, 413089792, 670130176, 357085184, 289269760, 722398208, 824770048, 179159296, 836234112, 684580928, 524792544, 865460464, 929234312, 660524356, 265332578, 540656055 - ], - [ - 536870912, 805306368, 134217728, 335544320, 167772160, 117440512, 746586112, 633339904, 1063256064, 191889408, 970457088, 62128128, 491126784, 680853504, 521633792, 807223296, 715857920, 774311936, 98834432, 936309760, 103347712, 867036928, 932404608, 664979904, 802872352, 587139568, 835845512, 1036622284, 958161954, 858435061 - ], - [ - 536870912, 268435456, 402653184, 469762048, 771751936, 587202560, 696254464, 281018368, 6291456, 774897664, 851968000, 25952256, 360316928, 426442752, 817070080, 191315968, 1007263744, 720228352, 382355456, 157467648, 1012802048, 984453376, 787093632, 192033472, 646439072, 821568624, 356878504, 871854196, 395428526, 874100083 - ], - [ - 536870912, 805306368, 671088640, 67108864, 905969664, 419430400, 360710144, 20971520, 1000341504, 875560960, 1062731776, 200540160, 192806912, 272695296, 438403072, 728842240, 435691520, 474329088, 744933376, 899001344, 607095296, 1070177536, 1008468352, 51579584, 774616992, 948946928, 863600648, 159727628, 788930570, 155496449 - ], - [ - 536870912, 805306368, 402653184, 872415232, 167772160, 50331648, 998244352, 834666496, 639631360, 36700160, 956825600, 702808064, 329121792, 340066304, 275742720, 325959680, 263856128, 872124416, 823867392, 193711104, 133330432, 847207680, 626276224, 903318848, 885073056, 278945712, 426776456, 577314124, 230005926, 1011241917 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 301989888, 419430400, 394264576, 968884224, 543162368, 359661568, 72876032, 348389376, 420610048, 669057024, 347176960, 272121856, 800448512, 373985280, 1034274816, 602094592, 779652608, 236282624, 391805824, 42732224, 947849760, 758025872, 514318344, 1034653708, 856967170, 383482895 - ], - [ - 536870912, 805306368, 939524096, 469762048, 234881024, 1056964608, 897581056, 1019215872, 367001600, 292552704, 1051197440, 874250240, 912392192, 363003904, 96632832, 275988480, 658219008, 207081472, 1000089600, 799179776, 549708288, 821234944, 58369664, 569885632, 156101408, 484117552, 304573224, 146033724, 998165286, 222338107 - ], - [ - 536870912, 805306368, 671088640, 603979776, 369098752, 318767104, 209715200, 213909504, 622854144, 567279616, 913833984, 721158144, 1027735552, 6356992, 665944064, 449396736, 817176576, 859222016, 326604800, 177660928, 644326912, 365938944, 525033088, 469072832, 710343648, 21405712, 421437448, 313716748, 659109898, 770970633 - ], - [ - 536870912, 268435456, 134217728, 738197504, 570425344, 889192448, 461373440, 230686720, 224395264, 550502400, 594018304, 972292096, 296353792, 787546112, 144211968, 854343680, 176644096, 655757312, 408823808, 660282368, 40422912, 880073472, 795516544, 51453760, 688473504, 1067826256, 142854152, 899959812, 25363970, 69506827 - ], - [ - 536870912, 805306368, 134217728, 201326592, 637534208, 956301312, 679477248, 364904448, 1063256064, 655360000, 739770368, 130809856, 579469312, 708640768, 247693312, 1011433472, 779476992, 616001536, 855549952, 59438080, 918398464, 956505856, 271156864, 1055228864, 216988384, 924006032, 749784712, 686360524, 990147810, 624860563 - ], - [ - 536870912, 268435456, 402653184, 335544320, 1040187392, 889192448, 427819008, 71303168, 652214272, 15728640, 231211008, 656670720, 924975104, 994902016, 513179648, 983023616, 211230720, 899067904, 102123520, 156687360, 53975552, 503726848, 829378944, 811208512, 172056480, 467710416, 359754632, 596196420, 180708902, 458478229 - ], - [ - 536870912, 805306368, 939524096, 201326592, 570425344, 989855744, 897581056, 46137344, 887095296, 808452096, 417857536, 491520000, 97386496, 764346368, 137265152, 591347712, 528949248, 72495104, 1016719360, 973423616, 76730880, 58307840, 129291392, 314262464, 148165024, 155886544, 308040104, 527885276, 459010470, 275026911 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 100663296, 956301312, 243269632, 683671552, 1067450368, 103809024, 359137280, 635699200, 172097536, 858718208, 634945536, 340606976, 235347968, 979161088, 186546176, 95452160, 556356096, 696535808, 1045685376, 959962816, 901089888, 607892528, 861052136, 632730108, 108341774, 370882307 - ], - [ - 536870912, 805306368, 671088640, 67108864, 905969664, 83886080, 796917760, 322961408, 660602880, 51380224, 129499136, 1069285376, 185466880, 94830592, 312639488, 378650624, 335077376, 744280064, 903854080, 801104896, 523193856, 299310336, 1040865664, 714427968, 290103456, 670374992, 224024232, 953017692, 1025982754, 761509405 - ], - [ - 536870912, 805306368, 671088640, 603979776, 838860800, 553648128, 713031680, 222298112, 186646528, 456130560, 235405312, 623640576, 931790848, 27197440, 372277248, 42516480, 325869568, 321564672, 258971648, 1062788096, 490077696, 1017008896, 850473088, 281653696, 97273120, 1020955440, 210178984, 765834748, 971479042, 104127493 - ], - [ - 536870912, 268435456, 671088640, 469762048, 771751936, 419430400, 662700032, 54525952, 165675008, 756023296, 582483968, 580124672, 80347136, 264175616, 912621568, 862175232, 999464960, 574230528, 253196288, 1019859968, 66942464, 222711040, 26231680, 561537856, 1052041312, 419156848, 615908328, 196714548, 1024826242, 864790339 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 436207616, 285212672, 209715200, 423624704, 450887680, 292552704, 702021632, 600047616, 1014366208, 419495936, 411140096, 658554880, 769777664, 384880640, 756582400, 753165312, 782682624, 994694912, 65866624, 288067264, 726924832, 721925040, 198705160, 1053032460, 854982662, 759234575 - ], - [ - 536870912, 805306368, 939524096, 603979776, 838860800, 452984832, 662700032, 113246208, 874512384, 512753664, 237502464, 166461440, 921829376, 297467904, 304513024, 290275328, 19095552, 829583360, 662366208, 503788544, 735949312, 1024088832, 597674880, 906555584, 159172768, 232463024, 852925096, 747991484, 244734246, 418743669 - ], - [ - 536870912, 805306368, 671088640, 738197504, 1040187392, 620756992, 310378496, 482344960, 425721856, 691011584, 196608000, 704905216, 942800896, 922550272, 588742656, 56508416, 780394496, 788803584, 447907840, 37504000, 376888832, 342804224, 3928960, 394319040, 1044429984, 765549264, 475049352, 478761932, 79507242, 11992603 - ], - [ - 536870912, 805306368, 939524096, 872415232, 369098752, 50331648, 864026624, 599785472, 681574400, 252706816, 370671616, 128712704, 192544768, 212926464, 378109952, 678805504, 91725824, 777760768, 526424064, 28433408, 571047424, 372528384, 957796480, 745157824, 648560480, 186925264, 34551816, 793144332, 731112974, 267684109 - ], - [ - 536870912, 268435456, 134217728, 469762048, 570425344, 318767104, 562036736, 633339904, 228589568, 5242880, 529006592, 350486528, 56754176, 187105280, 714440704, 846905344, 946577408, 646082560, 420890624, 1072477184, 650580480, 614820608, 84052864, 1070994624, 466480224, 525803952, 344770536, 45565300, 45966218, 567267523 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 637534208, 452984832, 411041792, 977272832, 811597824, 533725184, 228065280, 462684160, 882245632, 1069350912, 910852096, 229064704, 548691968, 648540160, 540309504, 686199808, 173373952, 171376384, 72194176, 862160320, 989533472, 594435312, 519633544, 952377028, 290426786, 357151295 - ], - [ - 536870912, 268435456, 134217728, 603979776, 301989888, 218103808, 645922816, 591396864, 819986432, 508559360, 580386816, 240386048, 814088192, 223412224, 790134784, 479477760, 749150208, 874614784, 225503232, 946435072, 234633728, 366679808, 263953024, 346792128, 299018400, 240575280, 193521672, 372077572, 25311746, 265164553 - ], - [ - 536870912, 268435456, 134217728, 603979776, 570425344, 956301312, 914358272, 230686720, 929038336, 244318208, 694681600, 803471360, 499515392, 272695296, 757104640, 783302656, 458825728, 612175872, 442222592, 810202112, 904130048, 937851648, 795907200, 976862016, 971818784, 414360112, 116293640, 730152964, 685219842, 677924873 - ], - [ - 536870912, 805306368, 134217728, 872415232, 369098752, 855638016, 679477248, 591396864, 425721856, 330301440, 669515776, 706478080, 533069824, 1054277632, 11436032, 260751360, 973692928, 15519744, 944687104, 1056623616, 373421568, 987811072, 611444864, 1070162880, 97325344, 807325712, 954349864, 257231900, 608888618, 808000785 - ], - [ - 536870912, 805306368, 939524096, 872415232, 369098752, 922746880, 444596224, 658505728, 589299712, 657457152, 770179072, 482607104, 173670400, 421724160, 410943488, 942227456, 614850560, 340447232, 117155840, 315841536, 611784192, 691803904, 910576256, 257238976, 407063776, 804257200, 875565800, 694773436, 8676966, 301615729 - ], - [ - 536870912, 268435456, 402653184, 335544320, 100663296, 50331648, 478150656, 490733568, 912261120, 95420416, 641204224, 947126272, 725221376, 1010892800, 669024256, 191938560, 60334080, 333721600, 559028224, 645784576, 968256000, 397308672, 277548416, 494420416, 487930784, 705424848, 322469896, 804569092, 653959174, 90255365 - ], - [ - 536870912, 268435456, 939524096, 335544320, 637534208, 184549376, 998244352, 901775360, 85983232, 300941312, 785907712, 603717632, 733085696, 992018432, 519077888, 190431232, 154968064, 856895488, 336680960, 243883008, 211054080, 158763264, 977190784, 260746944, 487359456, 820712336, 169648136, 971190276, 961107982, 213212165 - ], - [ - 536870912, 805306368, 134217728, 603979776, 369098752, 318767104, 360710144, 331350016, 354418688, 953155584, 645398528, 380895232, 339345408, 493158400, 398688256, 269565952, 853057536, 598011904, 274970624, 813767680, 625051136, 459293952, 439384192, 495528640, 454945568, 829898256, 204193928, 196884172, 577137954, 326269721 - ], - [ - 536870912, 805306368, 939524096, 67108864, 570425344, 352321536, 981467136, 717225984, 320864256, 646971392, 6815744, 128188416, 813563904, 492240896, 361922560, 614285312, 1058168832, 106819584, 271718400, 114076672, 660310528, 787073792, 124121984, 173976256, 659018976, 138109072, 530112232, 968682396, 579063142, 934670685 - ], - [ - 536870912, 805306368, 402653184, 201326592, 704643072, 889192448, 142606336, 918552576, 719323136, 705691648, 497549312, 557580288, 295043072, 940244992, 497844224, 436158464, 1012375552, 560705536, 50116608, 66505728, 1020985856, 652540160, 953416576, 90720192, 819851680, 939920592, 149105192, 926006044, 64570254, 658869199 - ], - [ - 536870912, 805306368, 671088640, 201326592, 905969664, 150994944, 243269632, 12582912, 983564288, 923795456, 1019740160, 528744448, 236322816, 828440576, 674332672, 513359872, 615276544, 761507840, 156190720, 971830272, 377669120, 734000384, 181725312, 247389760, 39116832, 796807856, 980803592, 783216652, 891103242, 146424835 - ], - [ - 536870912, 268435456, 134217728, 738197504, 100663296, 117440512, 360710144, 264241152, 555745280, 177209344, 752353280, 921436160, 536215552, 485687296, 434208768, 640729088, 227090432, 286609408, 579471360, 1029542912, 700338688, 247871232, 486260096, 590660160, 261835168, 994440400, 116624936, 14730644, 280010762, 1036619791 - ], - [ - 536870912, 805306368, 402653184, 469762048, 369098752, 16777216, 494927872, 457179136, 144703488, 91226112, 838336512, 345767936, 572391424, 1060700160, 863862784, 1036959744, 11657216, 479801344, 210552832, 334892032, 105736704, 1041747200, 245172096, 488519104, 666472928, 1069306736, 959375880, 299896076, 785475462, 973718983 - ], - [ - 536870912, 268435456, 939524096, 469762048, 234881024, 620756992, 411041792, 373293056, 463470592, 288358400, 820510720, 156499968, 36044800, 968032256, 678789120, 106381312, 192552960, 751898624, 309860352, 210553856, 698017280, 432027392, 778123392, 424720576, 683229920, 728530704, 336329320, 194545620, 1008539782, 121809091 - ], - [ - 536870912, 268435456, 402653184, 67108864, 100663296, 687865856, 645922816, 448790528, 123731968, 911212544, 143130624, 304873472, 694550528, 434044928, 61571072, 849952768, 324820992, 270454784, 424302592, 263834624, 234154496, 155400448, 978603904, 460469696, 286055328, 378985488, 1046874536, 39778580, 569046062, 34159061 - ], - [ - 536870912, 805306368, 671088640, 738197504, 570425344, 1056964608, 343932928, 264241152, 165675008, 886046720, 580386816, 640942080, 152698880, 685834240, 626098176, 47792128, 982867968, 652939264, 482932736, 242033664, 156188160, 6958848, 872953472, 386673856, 1012905376, 907232976, 225271816, 667881484, 883619850, 661136395 - ], - [ - 536870912, 805306368, 402653184, 603979776, 100663296, 184549376, 864026624, 775946240, 371195904, 112197632, 174587904, 828637184, 572653568, 228261888, 1032224768, 811089920, 281829376, 942133248, 682117120, 344224768, 737310208, 115506944, 595281536, 131518400, 358683104, 403827568, 152686568, 661418108, 97965934, 677405877 - ], - [ - 536870912, 805306368, 134217728, 335544320, 33554432, 788529152, 1065353216, 381681664, 295698432, 569376768, 1022885888, 585891840, 538836992, 658440192, 982417408, 227983360, 543842304, 924610560, 786827264, 584283136, 823132672, 1047097088, 608522368, 620470080, 615885856, 646149840, 505007144, 125568732, 221725738, 924496601 - ], - [ - 536870912, 805306368, 939524096, 67108864, 771751936, 1023410176, 8388608, 784334848, 857735168, 556793856, 953679872, 129236992, 1054736384, 204800000, 429883392, 122994688, 474980352, 52277248, 298993664, 823112704, 729562624, 293776640, 520583040, 352422848, 209754656, 1019323696, 606173064, 850430924, 731453998, 450127153 - ], - [ - 536870912, 268435456, 402653184, 872415232, 369098752, 922746880, 595591168, 205520896, 81788928, 900726784, 43515904, 50069504, 548798464, 132972544, 931037184, 1010417664, 346890240, 740192256, 1070143488, 131410944, 433265152, 86481664, 702873472, 856411072, 221955680, 1071899504, 66996104, 66672580, 68019302, 693052541 - ], - [ - 536870912, 268435456, 671088640, 67108864, 1040187392, 419430400, 511705088, 62914560, 404750336, 414187520, 534249472, 259784704, 1061027840, 909443072, 304775168, 355352576, 882745344, 799944704, 425502720, 110076928, 460154368, 613833984, 355573632, 496519616, 1058814816, 418329776, 230551944, 94339268, 1061448426, 919766129 - ], - [ - 536870912, 805306368, 402653184, 603979776, 100663296, 855638016, 377487360, 507510784, 467664896, 537919488, 890765312, 831258624, 1001521152, 53411840, 973373440, 761741312, 686874624, 864587776, 47540224, 903744512, 512587264, 1060254976, 812559232, 543554112, 62360480, 726149488, 796149800, 841998140, 696563086, 245809989 - ], - [ - 536870912, 268435456, 134217728, 335544320, 33554432, 620756992, 696254464, 146800640, 115343360, 376438784, 953679872, 56885248, 540672000, 759496704, 548044800, 200097792, 253108224, 716394496, 661129216, 249404416, 82808320, 214354688, 926567808, 969168320, 501990048, 332219920, 948366728, 144328132, 1033235106, 597920277 - ], - [ - 536870912, 268435456, 134217728, 335544320, 570425344, 620756992, 696254464, 356515840, 1059061760, 407896064, 209190912, 959184896, 222429184, 612433920, 952139776, 6307840, 376479744, 531173376, 85272576, 584010752, 617851392, 790132992, 433848960, 388662208, 343243104, 792646160, 54132744, 682426372, 335708162, 631324677 - ], - [ - 536870912, 805306368, 134217728, 872415232, 905969664, 654311424, 897581056, 901775360, 685768704, 225443840, 261619712, 938737664, 870973440, 891748352, 912818176, 657309696, 281010176, 345837568, 944179200, 920245248, 1012146688, 674961664, 971945088, 672435008, 857380192, 863906800, 729637864, 146172348, 947989002, 356633857 - ], - [ - 536870912, 268435456, 134217728, 335544320, 570425344, 218103808, 998244352, 272629760, 727711744, 489684992, 709361664, 662437888, 600965120, 401670144, 82345984, 845955072, 1061855232, 53743616, 665774080, 1017289728, 64594432, 421825280, 498491776, 195444288, 264192480, 62534032, 459040776, 654564356, 558465538, 738056965 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 234881024, 486539264, 964689920, 331350016, 371195904, 783286272, 556269568, 652476416, 354811904, 981663744, 650477568, 177684480, 338370560, 853544960, 1041356800, 249103360, 447529472, 789755648, 954065024, 446410432, 63492448, 552942224, 671003112, 774820948, 349618310, 197902027 - ], - [ - 536870912, 805306368, 402653184, 67108864, 234881024, 989855744, 92274688, 230686720, 673185792, 277872640, 542638080, 188481536, 252051456, 938934272, 249462784, 252329984, 184049664, 703401984, 666847232, 1056613376, 928082432, 226073344, 1026385792, 589232448, 388642464, 40424336, 230006440, 578955164, 184376494, 86395037 - ], - [ - 536870912, 268435456, 671088640, 67108864, 503316480, 788529152, 880803840, 205520896, 362807296, 286261248, 837287936, 14942208, 629538816, 233897984, 148406272, 467484672, 602546176, 291762176, 242677760, 103375872, 1032159744, 91700480, 1017651328, 918889280, 542636320, 1073309488, 1032607752, 86234116, 668424714, 624470273 - ], - [ - 536870912, 805306368, 939524096, 469762048, 234881024, 285212672, 1031798784, 4194304, 178257920, 273678336, 272105472, 613154816, 931790848, 1069744128, 132546560, 196689920, 567058432, 715870208, 752031744, 1073714176, 329524736, 824122112, 726959488, 376950336, 794882848, 917512176, 1019833640, 702857468, 817780390, 1032176059 - ], - [ - 536870912, 268435456, 939524096, 335544320, 771751936, 754974720, 176160768, 54525952, 1063256064, 955252736, 370671616, 903610368, 633470976, 844824576, 524779520, 237256704, 800055296, 685838336, 422590464, 104434688, 139298304, 137020672, 907955840, 110712896, 631079840, 86158128, 392824232, 461336116, 292145958, 772109937 - ], - [ - 536870912, 268435456, 939524096, 738197504, 1040187392, 989855744, 528482304, 322961408, 610271232, 869269504, 730333184, 1046740992, 286392320, 931594240, 212697088, 840384512, 935698432, 190976000, 377415680, 724681728, 681104896, 617398528, 801558912, 525168832, 109455456, 707543856, 64369128, 140879860, 773031814, 34009551 - ], - [ - 536870912, 805306368, 134217728, 469762048, 1040187392, 419430400, 662700032, 968884224, 174063616, 856686592, 624427008, 1003749376, 460718080, 129040384, 315195392, 1002192896, 708501504, 543354880, 19286016, 397016064, 439152128, 658703104, 756498560, 983674304, 653272224, 1005116080, 915220488, 884165644, 125715970, 820842247 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 637534208, 889192448, 746586112, 222298112, 715128832, 896532480, 292028416, 846462976, 457048064, 5308416, 551059456, 545013760, 131850240, 869675008, 65284096, 336045056, 66898432, 622527744, 95843200, 32778048, 838823328, 170979056, 80332808, 813995012, 580280834, 524673295 - ], - [ - 536870912, 268435456, 134217728, 67108864, 33554432, 587202560, 880803840, 624951296, 845152256, 217055232, 209190912, 481034240, 283508736, 514785280, 870023168, 155303936, 610328576, 636514304, 536422400, 258780160, 617059840, 348003584, 370368128, 737433408, 618266912, 666988944, 773930792, 621871252, 390633386, 653654741 - ], - [ - 536870912, 268435456, 134217728, 603979776, 167772160, 788529152, 662700032, 297795584, 1067450368, 193986560, 698875904, 770965504, 129105920, 336527360, 649691136, 203210752, 690446336, 185364480, 751806464, 798557184, 483136000, 40854272, 780728704, 136641984, 746296544, 600552240, 640917352, 349150708, 328841738, 986539789 - ], - [ - 536870912, 805306368, 402653184, 469762048, 503316480, 83886080, 981467136, 641728512, 828375040, 244318208, 188219392, 447479808, 220332032, 676659200, 170885120, 617070592, 179462144, 804040704, 935561216, 537134080, 288786944, 538658560, 469293696, 999064768, 869404896, 360516432, 654037128, 1034486732, 1033185894, 294649751 - ], - [ - 536870912, 268435456, 671088640, 335544320, 436207616, 520093696, 109051904, 322961408, 232783872, 506462208, 537395200, 661389312, 847380480, 69271552, 512786432, 517554176, 349478912, 975622144, 275773440, 1029944320, 688937472, 504958720, 1005961600, 674728000, 720775008, 920011280, 71704584, 1017024516, 961271818, 15475717 - ], - [ - 536870912, 268435456, 939524096, 603979776, 637534208, 117440512, 394264576, 650117120, 278921216, 898629632, 651689984, 245104640, 695074816, 966721536, 603422720, 65159168, 132734976, 735399936, 1043064832, 770544640, 868614656, 237762304, 99353472, 801593664, 204190624, 619481552, 1061600168, 1030360532, 311177638, 443956957 - ], - [ - 536870912, 268435456, 939524096, 67108864, 167772160, 385875968, 159383552, 1027604480, 970981376, 240123904, 746061824, 333185024, 791019520, 507445248, 141787136, 973881344, 857694208, 310554624, 432359424, 116122624, 134348288, 738236672, 906067840, 419433024, 343964064, 599791888, 220260264, 183578644, 466178086, 838180437 - ], - [ - 536870912, 805306368, 671088640, 603979776, 771751936, 520093696, 478150656, 599785472, 979369984, 770703360, 778567680, 419692544, 953548800, 11206656, 522223616, 491831296, 913858560, 802967552, 656115712, 896080896, 461666816, 739740928, 38444160, 1058139328, 374965088, 504203920, 446860776, 81110876, 1064230914, 672632837 - ], - [ - 536870912, 805306368, 134217728, 872415232, 1040187392, 352321536, 58720256, 146800640, 765460480, 722468864, 1013448704, 752091136, 138805248, 866713600, 636846080, 1058422784, 908107776, 802189312, 331933696, 415611904, 481277440, 20759808, 189973632, 47113536, 688728992, 728443568, 1024603656, 539919628, 293364866, 817075533 - ], - [ - 536870912, 805306368, 939524096, 335544320, 436207616, 251658240, 394264576, 918552576, 337641472, 976224256, 465043456, 372506624, 936247296, 831062016, 93159424, 234602496, 138911744, 553930752, 284571648, 620551168, 195184128, 534956288, 360920448, 584206272, 901398176, 203899632, 55868936, 522065164, 1008825230, 640716485 - ], - [ - 536870912, 268435456, 134217728, 603979776, 838860800, 251658240, 947912704, 616562688, 341835776, 93323264, 700973056, 90963968, 940965888, 236388352, 588742656, 479707136, 618061824, 645361664, 948373504, 744410112, 607906304, 220285184, 1051747712, 981052352, 9814176, 12787728, 209043624, 831725588, 970834090, 359604253 - ], - [ - 536870912, 268435456, 939524096, 872415232, 704643072, 620756992, 461373440, 440401920, 325058560, 560988160, 623378432, 884736000, 486670336, 889782272, 724336640, 1818624, 394043392, 757321728, 983164928, 238418944, 376324608, 997397248, 849414016, 944870208, 792298208, 82166160, 647389704, 968295172, 413552526, 75415373 - ], - [ - 536870912, 268435456, 671088640, 469762048, 503316480, 251658240, 964689920, 88080384, 249561088, 737148928, 102236160, 190578688, 728629248, 575340544, 457801728, 953532416, 169582592, 876679168, 677382144, 1060172800, 297338368, 810331392, 159862912, 378512192, 1044103200, 1058125456, 417871528, 298100948, 301149698, 704940291 - ], - [ - 536870912, 805306368, 671088640, 603979776, 167772160, 285212672, 645922816, 314572800, 387973120, 661651456, 274202624, 293339136, 589168640, 269287424, 1011318784, 351289344, 504930304, 765267968, 298821632, 1071932416, 994287104, 660851968, 798100864, 126593984, 1024972896, 894967344, 637379976, 752865228, 262948458, 318231353 - ], - [ - 536870912, 805306368, 402653184, 872415232, 570425344, 318767104, 243269632, 541065216, 211812352, 435159040, 788004864, 564396032, 414056448, 212664320, 15958016, 19382272, 330375168, 760762368, 953546752, 320259072, 506038784, 1013778688, 18053504, 133607616, 259536800, 828679472, 693046152, 310214092, 674939942, 1058741501 - ], - [ - 536870912, 268435456, 939524096, 872415232, 1040187392, 419430400, 310378496, 121634816, 350224384, 760217600, 23592960, 300679168, 321781760, 75038720, 333742080, 139706368, 379494400, 171995136, 677480448, 185660416, 856189440, 100507392, 531052160, 709207360, 115511904, 153588976, 990208520, 117615364, 1022885006, 439175757 - ], - [ - 536870912, 805306368, 671088640, 872415232, 1040187392, 117440512, 209715200, 1035993088, 304087040, 953155584, 1000865792, 921436160, 771358720, 392626176, 220495872, 648462336, 218488832, 997707776, 925730816, 98204672, 1052129792, 151807744, 520749952, 136195520, 174083872, 78772272, 1008215208, 276134396, 860838274, 76044993 - ], - [ - 536870912, 268435456, 671088640, 738197504, 1040187392, 452984832, 25165824, 440401920, 601882624, 168820736, 401080320, 560726016, 605683712, 225902592, 359497728, 236699648, 746004480, 502075392, 819652608, 257422336, 803065344, 344139008, 270711680, 928195008, 191598880, 223219760, 88681128, 823996916, 664976258, 169025999 - ], - [ - 536870912, 805306368, 671088640, 469762048, 436207616, 251658240, 914358272, 381681664, 828375040, 479199232, 158859264, 488374272, 634781696, 622657536, 567771136, 186400768, 685203456, 681349120, 127342592, 968696832, 1017622016, 489991936, 877873792, 747037888, 696558176, 228280944, 642992776, 260498636, 755278442, 140200567 - ], - [ - 536870912, 805306368, 402653184, 603979776, 369098752, 117440512, 327155712, 541065216, 924844032, 464519168, 907542528, 349962240, 305004544, 961740800, 17596416, 271007744, 434561024, 327618560, 26658816, 721404928, 500846080, 58282752, 21827712, 386374464, 441948448, 27182352, 55208360, 1070681692, 923383950, 573837125 - ], - [ - 536870912, 805306368, 402653184, 469762048, 234881024, 385875968, 796917760, 230686720, 228589568, 764411904, 864550912, 31195136, 1051328512, 758448128, 80183296, 172474368, 319184896, 719728640, 202774528, 1043311616, 992609792, 368408832, 669456000, 244779840, 24032608, 298513040, 243593352, 18842188, 1051974630, 543253975 - ], - [ - 536870912, 268435456, 134217728, 872415232, 301989888, 184549376, 1048576000, 859832320, 635437056, 1032847360, 315097088, 554958848, 309723136, 978649088, 328630272, 499466240, 1046421504, 273797120, 342456320, 828711936, 154034688, 461982464, 737455744, 191237440, 618520096, 1004747504, 174206600, 228805956, 738393634, 754117373 - ], - [ - 536870912, 268435456, 134217728, 335544320, 973078528, 486539264, 343932928, 767557632, 534773760, 609222656, 465043456, 44826624, 467271680, 1043136512, 840597504, 332218368, 524951552, 653561856, 757516288, 911094784, 446342656, 805632, 799720576, 522499776, 903823840, 465707024, 779142280, 738834116, 457556450, 835674133 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 1040187392, 687865856, 461373440, 1027604480, 643825664, 204472320, 783810560, 605290496, 3801088, 227344384, 8355840, 239026176, 551510016, 690958336, 741763072, 330435584, 413168128, 319911680, 250105728, 765208768, 102235168, 644044944, 224976264, 350040012, 712424354, 22170719 - ], - [ - 536870912, 268435456, 671088640, 603979776, 838860800, 654311424, 360710144, 775946240, 945815552, 122683392, 141033472, 383516672, 298975232, 384368640, 723288064, 989020160, 1062739968, 769986560, 359036928, 317099008, 195518976, 239483648, 56063616, 23019840, 936525280, 1005146128, 362635784, 389233412, 1014625930, 542441801 - ], - [ - 536870912, 268435456, 134217728, 603979776, 1040187392, 318767104, 1048576000, 977272832, 522190848, 485490688, 139984896, 107741184, 20054016, 84606976, 53968896, 158187520, 1035198464, 1045139456, 731367424, 1012751360, 1024155136, 1060589312, 460063872, 884080704, 768231456, 1012397872, 666727976, 77260852, 884955818, 162079869 - ], - [ - 536870912, 268435456, 939524096, 469762048, 369098752, 352321536, 595591168, 826277888, 627048448, 611319808, 860356608, 471072768, 162922496, 685309952, 669810688, 63684608, 367779840, 603664384, 809691136, 316652544, 870160896, 342004480, 1003358080, 14971968, 826148256, 762075952, 386568712, 751509252, 493614478, 3906375 - ], - [ - 536870912, 805306368, 134217728, 738197504, 838860800, 50331648, 1015021568, 608174080, 274726912, 30408704, 567803904, 532938752, 880410624, 290783232, 625180672, 285294592, 260104192, 281137152, 404846592, 598766592, 587807232, 43869952, 268381312, 894340544, 902197408, 362442000, 21353608, 725334476, 431336098, 517200411 - ], - [ - 536870912, 805306368, 671088640, 738197504, 973078528, 50331648, 327155712, 171966464, 908066816, 902823936, 486014976, 871628800, 716046336, 609550336, 171933696, 252461056, 693821440, 654020608, 40630272, 1060277248, 626452992, 471883008, 785486976, 192422592, 800347936, 630130096, 17134728, 252097228, 9973546, 379323 - ], - [ - 536870912, 805306368, 671088640, 738197504, 301989888, 855638016, 713031680, 683671552, 115343360, 858783744, 1023934464, 975962112, 616169472, 694878208, 324173824, 41402368, 299933696, 397488128, 482945024, 156056576, 130750976, 155368704, 909065344, 3457216, 961427360, 692401520, 778551208, 414792060, 635800994, 796309623 - ], - [ - 536870912, 268435456, 402653184, 872415232, 1040187392, 620756992, 58720256, 239075328, 660602880, 49283072, 532152320, 1057226752, 247595008, 449249280, 981827584, 25313280, 405168128, 657838080, 81434624, 244536320, 313507328, 766038272, 34470016, 874386496, 510670048, 24700592, 480627816, 747827956, 900724878, 422122569 - ], - [ - 536870912, 805306368, 134217728, 67108864, 637534208, 587202560, 209715200, 918552576, 283115520, 152043520, 993525760, 349437952, 326500352, 280952832, 264404992, 572047360, 463855616, 513757184, 573769728, 1043385344, 323553792, 868037888, 876243328, 1026309696, 21220320, 567899856, 751053288, 701489116, 422199914, 269818013 - ], - [ - 536870912, 805306368, 402653184, 335544320, 436207616, 452984832, 360710144, 633339904, 517996544, 818937856, 401080320, 8650752, 154796032, 1020854272, 457015296, 957792256, 365404160, 607014912, 699045888, 537938944, 763895296, 51683072, 611549824, 766260544, 819865888, 938703440, 896345608, 918455052, 576914566, 220587589 - ], - [ - 536870912, 268435456, 939524096, 67108864, 301989888, 486539264, 125829120, 910163968, 354418688, 97517568, 730333184, 707526656, 700317696, 1021902848, 14450688, 652722176, 751640576, 974000128, 1007691776, 619224064, 350020096, 216424704, 902660736, 797869632, 391185504, 910717296, 659374600, 844083460, 439388814, 767035969 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 369098752, 721420288, 746586112, 926941184, 429916160, 282066944, 581435392, 475267072, 832176128, 145948672, 690388992, 626868224, 874487808, 234983424, 654411776, 42028032, 541091328, 589341440, 210807168, 394803904, 1002752864, 177387056, 70692200, 974460220, 834307302, 748908531 - ], - [ - 536870912, 805306368, 939524096, 201326592, 771751936, 553648128, 427819008, 138412032, 715128832, 32505856, 14155776, 802947072, 973471744, 264962048, 1002733568, 79314944, 769433600, 84316160, 256555008, 637871104, 140230144, 663535360, 498009728, 672068416, 427755808, 1013325648, 324704168, 218961948, 997079174, 1047465039 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 100663296, 50331648, 58720256, 88080384, 337641472, 535822336, 409468928, 238288896, 4063232, 76873728, 504266752, 471613440, 665542656, 152727552, 793933824, 328657920, 927011328, 1025551616, 829447552, 564770368, 450138144, 229526960, 346897800, 316851780, 509503530, 851829183 - ], - [ - 536870912, 805306368, 671088640, 469762048, 704643072, 1056964608, 897581056, 952107008, 908066816, 537919488, 290979840, 673447936, 237109248, 993722368, 226394112, 254656512, 574496768, 315486208, 59754496, 944063488, 324203008, 965921536, 884141952, 1059260224, 532403552, 557832176, 1028499304, 743431420, 669378786, 562293691 - ], - [ - 536870912, 805306368, 402653184, 67108864, 167772160, 218103808, 578813952, 952107008, 85983232, 688914432, 479723520, 211025920, 345374720, 1055457280, 654147584, 967491584, 1071849472, 592367616, 320612352, 966423552, 476739072, 809677056, 782115968, 77872832, 455061408, 1004919600, 410975752, 555078924, 802609798, 931720129 - ], - [ - 536870912, 805306368, 134217728, 469762048, 704643072, 956301312, 226492416, 205520896, 765460480, 999292928, 1054343168, 637272064, 527826944, 514523136, 940343296, 853524480, 373268480, 395259904, 797333504, 142836736, 802782720, 75282176, 825681280, 369843264, 605921824, 960979920, 333637544, 1059590044, 576036234, 786638923 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 301989888, 419430400, 796917760, 868220928, 698351616, 110100480, 67633152, 12845056, 448397312, 213319680, 887652352, 297058304, 860004352, 885682176, 231659520, 869561344, 947110400, 810803968, 1040335232, 220917952, 725494880, 1038994672, 128921576, 82059068, 787210754, 446583555 - ], - [ - 536870912, 805306368, 671088640, 469762048, 369098752, 788529152, 494927872, 121634816, 115343360, 930086912, 30932992, 539230208, 812253184, 951910400, 363823104, 472268800, 411721728, 617443328, 737630208, 507706368, 176263680, 516018944, 597800320, 345030592, 304709536, 339580176, 208643976, 1040657612, 492481066, 520379095 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 838860800, 654311424, 1048576000, 499122176, 782237696, 640679936, 620232704, 688652288, 393871360, 96272384, 272859136, 1058029568, 76046336, 253022208, 698800128, 292512768, 932926976, 762134784, 963313536, 246702784, 1024897504, 844529680, 724969352, 279316172, 586049514, 668696863 - ], - [ - 536870912, 268435456, 671088640, 469762048, 369098752, 452984832, 981467136, 884998144, 241172480, 202375168, 261619712, 797179904, 794689536, 355139584, 1019052032, 564903936, 930914304, 927649792, 514598912, 20147200, 678986240, 567635200, 610678656, 1071546944, 1022072800, 996005968, 1073424488, 340125204, 29332866, 150667075 - ], - [ - 536870912, 805306368, 939524096, 603979776, 704643072, 721420288, 461373440, 356515840, 283115520, 248512512, 197656576, 689700864, 628752384, 577830912, 158957568, 348504064, 655302656, 715542528, 783013888, 54107136, 1034275328, 194983680, 604921472, 489032256, 233514720, 920238800, 703952904, 630590476, 322122254, 858651401 - ], - [ - 536870912, 268435456, 939524096, 738197504, 503316480, 989855744, 109051904, 314572800, 849346560, 697303040, 397934592, 453771264, 269615104, 134021120, 152731648, 580435968, 131981312, 273362944, 444708864, 616580096, 497061376, 487637248, 544811648, 338489536, 767795424, 807775056, 153612936, 212026564, 211121902, 307175003 - ], - [ - 536870912, 805306368, 671088640, 67108864, 369098752, 50331648, 8388608, 666894336, 505413632, 40894464, 98041856, 647757824, 674365440, 702742528, 1040875520, 439336960, 672260096, 650661888, 886425600, 86412288, 904172032, 522081024, 606705792, 872698432, 525207712, 427913264, 104865960, 73444412, 1007811234, 684241725 - ], - [ - 536870912, 805306368, 939524096, 603979776, 570425344, 989855744, 830472192, 943718400, 471859200, 766509056, 1010302976, 619970560, 22151168, 267714560, 953384960, 733265920, 586326016, 520474624, 340490240, 842030080, 829995520, 206945536, 404903808, 1059888320, 527945760, 781076048, 1008359304, 265854156, 69586990, 1048266329 - ], - [ - 536870912, 805306368, 134217728, 67108864, 100663296, 16777216, 343932928, 901775360, 211812352, 550502400, 611844096, 4980736, 574488576, 111083520, 307134464, 943112192, 1031462912, 231002112, 1067177984, 905313280, 416453120, 225449728, 539607424, 435501632, 718521376, 40945616, 833168424, 1051989980, 313719850, 981593053 - ], - [ - 536870912, 268435456, 134217728, 872415232, 436207616, 788529152, 998244352, 742391808, 421527552, 540016640, 680001536, 46399488, 1058406400, 360120320, 266829824, 387956736, 175267840, 579907584, 888719360, 997037056, 702723584, 417914624, 928288384, 477000384, 609966304, 1042559568, 558282984, 762266196, 853151978, 988112473 - ], - [ - 536870912, 268435456, 402653184, 738197504, 503316480, 922746880, 8388608, 247463936, 702545920, 116391936, 276299776, 546045952, 47841280, 750452736, 738951168, 793985024, 315498496, 798806016, 72509440, 72346624, 576576000, 523384064, 629019264, 742758720, 923762976, 285079024, 258187560, 257304052, 601901358, 334596607 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 234881024, 16777216, 1015021568, 12582912, 429916160, 630194176, 918028288, 583270400, 114688000, 696320000, 104955904, 308396032, 867295232, 543715328, 815532032, 610526208, 622790144, 126635264, 588999808, 452629952, 403310112, 730009264, 451805192, 109379596, 330792974, 598786063 - ], - [ - 536870912, 268435456, 134217728, 603979776, 905969664, 654311424, 478150656, 960495616, 132120576, 344981504, 167247872, 142344192, 656539648, 939982848, 338264064, 509919232, 399466496, 81629184, 894568448, 384736256, 342724096, 966427904, 1016841088, 689643328, 131763744, 939162096, 214573992, 767734708, 487982602, 84990221 - ], - [ - 536870912, 268435456, 134217728, 67108864, 905969664, 687865856, 562036736, 37748736, 245366784, 118489088, 139984896, 170655744, 634781696, 204668928, 777093120, 544784384, 201089024, 854560768, 317716480, 49267712, 183426560, 250578688, 955129216, 300900928, 812517280, 841972176, 1016020008, 1000298644, 868644874, 971703301 - ], - [ - 536870912, 805306368, 939524096, 469762048, 100663296, 822083584, 159383552, 725614592, 480247808, 53477376, 150470656, 772538368, 802029568, 219742208, 312311808, 1049083904, 573431808, 440381440, 268519424, 134294528, 604023296, 436309248, 922772864, 947951040, 583129440, 937442800, 529582600, 197786892, 653577614, 29493703 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 100663296, 50331648, 192937984, 918552576, 715128832, 164626432, 915931136, 993787904, 223739904, 710737920, 849772544, 710197248, 442720256, 835645440, 1012955136, 863054848, 122260992, 832887040, 812372096, 604743104, 326892896, 775126384, 446050440, 578655684, 993453422, 875405695 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 33554432, 117440512, 780140544, 1010827264, 228589568, 258998272, 984088576, 672399360, 710541312, 555679744, 542932992, 136232960, 333291520, 165572608, 851208192, 844049408, 591709696, 1027856128, 709046912, 482546880, 880958688, 119772144, 223520360, 511367996, 615437442, 1058304963 - ], - [ - 536870912, 268435456, 402653184, 335544320, 33554432, 184549376, 729808896, 859832320, 132120576, 470810624, 33030144, 297533440, 802029568, 283574272, 990085120, 788611072, 562094080, 876638208, 979429376, 642847744, 647536128, 359463168, 446121344, 447467584, 153477792, 799259728, 619713704, 610799956, 805613358, 101845009 - ], - [ - 536870912, 268435456, 939524096, 872415232, 637534208, 1056964608, 864026624, 432013312, 127926272, 693108736, 721944576, 998506496, 347996160, 445972480, 282492928, 257998848, 1047601152, 35188736, 602691584, 726313984, 422721024, 925769984, 129877120, 985892160, 267830944, 980489648, 202972296, 283961668, 181096622, 435356861 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 33554432, 822083584, 310378496, 608174080, 199229440, 800063488, 382205952, 503054336, 305004544, 872873984, 835354624, 636239872, 750166016, 176304128, 634451968, 246959104, 773135872, 868358400, 380672128, 273221824, 532435488, 382621136, 976743464, 549616860, 87133358, 1049114643 - ], - [ - 536870912, 805306368, 134217728, 603979776, 704643072, 150994944, 159383552, 415236096, 492830720, 714080256, 715653120, 948174848, 956956672, 192872448, 701267968, 224378880, 1073504256, 294121472, 998266880, 230728704, 316774912, 894518528, 491299712, 173313984, 528627296, 483041008, 228503016, 1050494268, 1024940426, 371800773 - ], - [ - 536870912, 805306368, 939524096, 201326592, 838860800, 520093696, 75497472, 717225984, 874512384, 210763776, 98041856, 786169856, 982646784, 561184768, 105021440, 659243008, 867115008, 919646208, 356075520, 57469952, 609909248, 372685568, 334286720, 10148160, 924281760, 150747440, 419613608, 405522748, 241083302, 469275967 - ], - [ - 536870912, 805306368, 671088640, 201326592, 905969664, 184549376, 243269632, 490733568, 576716800, 697303040, 959971328, 218365952, 756154368, 1046937600, 136085504, 426164224, 10231808, 656822272, 545105920, 636996608, 807759360, 266486016, 961534848, 518051648, 902936288, 14278192, 810935656, 327914876, 785520002, 424019535 - ], - [ - 536870912, 805306368, 134217728, 201326592, 905969664, 620756992, 276824064, 348127232, 48234496, 707788800, 648544256, 561250304, 467533824, 713621504, 715489280, 717635584, 622157824, 808333312, 373319680, 958489600, 592532992, 567893760, 930899328, 599440192, 799971488, 956410224, 511817224, 901852940, 677473666, 770830147 - ], - [ - 536870912, 268435456, 671088640, 335544320, 771751936, 721420288, 864026624, 507510784, 65011712, 533725184, 1018691584, 55836672, 436338688, 266928128, 741113856, 133644288, 777756672, 820834304, 1020696576, 481000448, 698655232, 793507584, 242539136, 804510656, 924884896, 821089680, 541604360, 824019716, 975108234, 58092741 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 838860800, 855638016, 578813952, 448790528, 278921216, 644874240, 135790592, 243007488, 549584896, 671416320, 778993664, 867057664, 529424384, 171921408, 1057404928, 491496448, 217185792, 1054456064, 81549696, 162721728, 815599456, 164768336, 558712712, 188368580, 1021939434, 614740383 - ], - [ - 536870912, 805306368, 402653184, 201326592, 838860800, 654311424, 461373440, 616562688, 811597824, 296747008, 848822272, 856424448, 414056448, 297467904, 190349312, 468533248, 274636800, 780333056, 386148352, 942318592, 256924160, 191419648, 380987008, 582131008, 677209760, 768032784, 302930472, 359270492, 217111054, 691639567 - ], - [ - 536870912, 268435456, 671088640, 603979776, 637534208, 16777216, 696254464, 205520896, 1029701632, 909115392, 217579520, 817102848, 589955072, 121700352, 132153344, 485572608, 827924480, 941961216, 700581888, 433867776, 586605056, 968338176, 341250432, 195532736, 880700832, 681215312, 435716104, 120930308, 577445898, 295710729 - ], - [ - 536870912, 805306368, 671088640, 67108864, 33554432, 1056964608, 578813952, 817889280, 174063616, 267386880, 915931136, 1046740992, 660209664, 267190272, 546799616, 36323328, 1035247616, 1049808896, 293705728, 608216064, 799092224, 470851328, 690552192, 224238016, 1043254176, 555644816, 770108296, 879915724, 565248042, 305763665 - ], - [ - 536870912, 268435456, 939524096, 738197504, 234881024, 956301312, 880803840, 784334848, 350224384, 122683392, 1070071808, 714342400, 875167744, 223805440, 89751552, 104677376, 548315136, 320081920, 476788736, 947301376, 929575424, 719642880, 919860608, 714764480, 860873952, 834961136, 769852264, 180600628, 670206470, 313199887 - ], - [ - 536870912, 268435456, 671088640, 872415232, 838860800, 620756992, 327155712, 247463936, 379584512, 124780544, 216530944, 476839936, 490864640, 27066368, 854228992, 244334592, 251207680, 248827904, 41322496, 234490880, 61398528, 822995200, 923970944, 818274880, 114221280, 768571728, 223225224, 789507652, 904838890, 192925789 - ], - [ - 536870912, 268435456, 939524096, 67108864, 369098752, 251658240, 176160768, 130023424, 773849088, 594542592, 260571136, 201064448, 735707136, 574685184, 861962240, 848412672, 114827264, 822390784, 548304896, 149378048, 1027325440, 227619072, 609778560, 180694080, 479115232, 848741072, 926056456, 187482116, 643997710, 634679297 - ], - [ - 536870912, 268435456, 939524096, 469762048, 637534208, 117440512, 562036736, 4194304, 1012924416, 1016070144, 469237760, 9175040, 948830208, 1033961472, 280002560, 587841536, 1004855296, 100347904, 44251136, 874417152, 240665088, 876364544, 562558080, 658782144, 868909152, 6959728, 869949448, 190050308, 301422606, 250379271 - ], - [ - 536870912, 805306368, 671088640, 469762048, 436207616, 385875968, 578813952, 968884224, 463470592, 607125504, 734527488, 270270464, 774504448, 720306176, 836796416, 433111040, 806985728, 50606080, 162424832, 394308608, 138500608, 786453248, 391191680, 1004056512, 329606816, 354346416, 310962216, 561874300, 490414082, 232255499 - ], - [ - 536870912, 268435456, 134217728, 872415232, 234881024, 553648128, 142606336, 910163968, 740294656, 1001390080, 838336512, 534511616, 347471872, 630915072, 662011904, 188923904, 10018816, 936202240, 1027553280, 593488896, 583927296, 897981184, 690133120, 990507072, 260311072, 136010448, 263465128, 203654804, 629720714, 616863561 - ], - [ - 536870912, 268435456, 671088640, 872415232, 436207616, 16777216, 427819008, 356515840, 627048448, 330301440, 410517504, 583270400, 853671936, 865271808, 952860672, 677298176, 867524608, 297447424, 386349056, 958411776, 189890048, 747218176, 719102080, 1509184, 222930784, 360462704, 612835176, 358731124, 732987746, 74979449 - ], - [ - 536870912, 268435456, 134217728, 335544320, 905969664, 587202560, 595591168, 322961408, 631242752, 760217600, 1027080192, 572784640, 137756672, 782172160, 1013153792, 553762816, 645947392, 465653760, 23070720, 766620672, 382246400, 298625792, 74112384, 556576320, 932909664, 247855440, 432407656, 343287380, 314550250, 192066321 - ], - [ - 536870912, 268435456, 939524096, 201326592, 234881024, 520093696, 1015021568, 624951296, 467664896, 781189120, 794296320, 56885248, 843448320, 567738368, 856653824, 246038528, 852238336, 220942336, 990652416, 193694720, 41715200, 71436544, 826398080, 165798720, 126918240, 14169424, 346338920, 333953364, 673591398, 394702935 - ], - [ - 536870912, 805306368, 939524096, 201326592, 503316480, 150994944, 880803840, 784334848, 119537664, 267386880, 310902784, 298057728, 789708800, 341377024, 230522880, 752861184, 374300672, 651587584, 122357760, 1071940608, 610510336, 269492480, 391676800, 306003520, 429804832, 237902864, 709348872, 986895628, 16264590, 688757571 - ], - [ - 536870912, 805306368, 939524096, 469762048, 570425344, 721420288, 360710144, 826277888, 35651584, 963641344, 876085248, 472645632, 724959232, 243859456, 620068864, 839630848, 22536192, 56201216, 696064000, 394234880, 69040640, 355457280, 265617280, 100394944, 699312736, 806730544, 454812168, 1069454604, 494790030, 561999559 - ], - [ - 536870912, 805306368, 402653184, 201326592, 973078528, 654311424, 511705088, 138412032, 442499072, 110100480, 1009254400, 794034176, 2228224, 648740864, 810450944, 825507840, 414392320, 327315456, 278530048, 987126784, 364490240, 704419072, 154594688, 770210496, 334852448, 210962416, 175341416, 530752252, 90847982, 267301951 - ], - [ - 536870912, 268435456, 671088640, 872415232, 167772160, 486539264, 796917760, 373293056, 115343360, 630194176, 626524160, 434372608, 788135936, 134021120, 645824512, 114704384, 1010442240, 199004160, 63866880, 272550912, 271985152, 833303296, 444951168, 271246272, 600063648, 944480912, 26591368, 447975620, 159478826, 222351709 - ], - [ - 536870912, 805306368, 402653184, 738197504, 369098752, 50331648, 998244352, 968884224, 1029701632, 516947968, 106430464, 149159936, 789708800, 1039335424, 283279360, 651837440, 611262464, 426086400, 735217664, 202626048, 913529344, 824381696, 934950784, 750693696, 473771616, 414663920, 448794216, 920769788, 1058014830, 389562615 - ], - [ - 536870912, 805306368, 402653184, 738197504, 771751936, 50331648, 260046848, 297795584, 287309824, 802160640, 83361792, 532414464, 122028032, 32571392, 581533696, 1032110080, 73097216, 363229184, 973117440, 822164480, 981544448, 826317056, 559945344, 741360576, 898109408, 626277680, 220461064, 920341516, 552056326, 23110923 - ], - [ - 536870912, 268435456, 671088640, 603979776, 905969664, 956301312, 947912704, 759169024, 966787072, 1064304640, 565706752, 637272064, 501350400, 721092608, 569868288, 543997952, 529195008, 323932160, 1041291264, 1017674752, 450168320, 905442048, 778839168, 713799488, 969881504, 475056688, 76075432, 811985204, 11414818, 222372477 - ], - [ - 536870912, 268435456, 939524096, 872415232, 33554432, 855638016, 847249408, 926941184, 241172480, 242221056, 1018691584, 105119744, 128581632, 290914304, 918126592, 692404224, 992632832, 588689408, 995624960, 301288448, 204623360, 302217472, 5900416, 875551296, 131865056, 738145904, 456417128, 429102388, 408047110, 192117001 - ], - [ - 536870912, 268435456, 939524096, 335544320, 973078528, 16777216, 562036736, 12582912, 689963008, 684720128, 120061952, 60030976, 295567360, 415039488, 336232448, 505593856, 37167104, 275353600, 360048640, 854572032, 50626048, 584523008, 202933376, 743201344, 812778784, 593433136, 211614344, 190531396, 919241134, 839075957 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 838860800, 520093696, 377487360, 633339904, 950009856, 59768832, 190316544, 1035730944, 241041408, 14352384, 361267200, 914702336, 424878080, 151875584, 215410688, 887065600, 1058732544, 371800832, 764772736, 449462848, 93393184, 844629520, 574474920, 740249436, 641372686, 49870595 - ], - [ - 536870912, 268435456, 134217728, 872415232, 369098752, 822083584, 545259520, 994050048, 148897792, 919601152, 211288064, 6553600, 983433216, 424345600, 945651712, 88784896, 173858816, 709595136, 802977792, 663464960, 763178496, 960181504, 745866624, 1025941568, 543085792, 308941648, 19745128, 367234836, 393300874, 229164361 - ], - [ - 536870912, 805306368, 134217728, 67108864, 33554432, 285212672, 1048576000, 683671552, 316669952, 277872640, 470286336, 2359296, 507904000, 297992192, 917798912, 558874624, 912744448, 984788992, 145512448, 329423872, 702923264, 170322176, 630341504, 1046281920, 586880096, 464014992, 1024773096, 444514396, 559835018, 632185549 - ], - [ - 536870912, 805306368, 134217728, 469762048, 369098752, 788529152, 310378496, 289406976, 165675008, 600834048, 145227776, 549191680, 155582464, 923467776, 991199232, 494649344, 135110656, 192925696, 50235392, 994020352, 312372736, 422550784, 664229248, 941767104, 694711200, 756852560, 16158248, 749863580, 253836170, 552707275 - ], - [ - 536870912, 805306368, 939524096, 738197504, 167772160, 1023410176, 461373440, 616562688, 975175680, 355467264, 647495680, 175898624, 413532160, 815464448, 492601344, 504774656, 650354688, 184659968, 612497408, 373396480, 593545728, 1020350208, 789073024, 110389056, 715362336, 223407696, 113859752, 523618588, 928246918, 468309831 - ], - [ - 536870912, 805306368, 402653184, 67108864, 838860800, 822083584, 562036736, 926941184, 207618048, 835715072, 873988096, 307494912, 158728192, 312541184, 653361152, 665370624, 278667264, 230395904, 776112128, 663194624, 420084224, 409797376, 756219520, 475961536, 234686112, 770323888, 891002888, 1035096076, 330246150, 265608193 - ], - [ - 536870912, 805306368, 939524096, 67108864, 234881024, 385875968, 578813952, 717225984, 601882624, 149946368, 871890944, 563347456, 17432576, 520028160, 323256320, 90324992, 27451392, 88264704, 389253120, 168479744, 109007360, 411427072, 386065536, 252949056, 681289312, 1060607600, 449422056, 688780348, 598674566, 1047391821 - ], - [ - 536870912, 805306368, 939524096, 201326592, 503316480, 385875968, 92274688, 717225984, 157286400, 19922944, 296222720, 531890176, 857866240, 808910848, 180649984, 715800576, 571645952, 698224640, 561055744, 193508352, 455354880, 836449536, 614147712, 171689664, 988414432, 3362864, 554633064, 1032374012, 136621702, 509227727 - ], - [ - 536870912, 268435456, 402653184, 603979776, 973078528, 83886080, 327155712, 213909504, 1012924416, 665845760, 416808960, 105119744, 609615872, 1052966912, 125665280, 442646528, 783081472, 470446080, 1034958848, 232330240, 231074304, 211193088, 950178432, 634139968, 289131488, 606645008, 71139688, 616823380, 310220942, 300140621 - ], - [ - 536870912, 805306368, 402653184, 872415232, 301989888, 50331648, 931135488, 381681664, 723517440, 68157440, 68681728, 1044119552, 719716352, 135069696, 40861696, 761905152, 240394240, 103960576, 645838848, 426880000, 678030848, 416646400, 1014212224, 404681152, 847312224, 4275696, 291585672, 980487628, 803840870, 370414845 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 436207616, 150994944, 377487360, 658505728, 136314880, 261095424, 258473984, 1011613696, 663355392, 242024448, 823820288, 260423680, 370630656, 976162816, 518662144, 316482560, 174248448, 727713024, 833666688, 200857152, 279296224, 805722128, 260562568, 776455748, 422023398, 580353055 - ], - [ - 536870912, 805306368, 671088640, 872415232, 167772160, 251658240, 511705088, 205520896, 652214272, 495976448, 827850752, 515112960, 598081536, 445710336, 735674368, 821379072, 1044881408, 327241728, 432142336, 371307520, 204587520, 514418432, 826053760, 875265728, 911447968, 89565744, 43644936, 932557836, 420987402, 1014523661 - ], - [ - 536870912, 805306368, 402653184, 872415232, 771751936, 318767104, 1048576000, 364904448, 14680064, 32505856, 119013376, 595329024, 257556480, 361299968, 903184384, 748601344, 931045376, 336588800, 81188864, 776606720, 593509888, 162598656, 884568960, 61680320, 659795680, 589082704, 543835656, 15854348, 412620166, 423489997 - ], - [ - 536870912, 805306368, 671088640, 872415232, 1040187392, 452984832, 494927872, 432013312, 803209216, 477102080, 173539328, 40632320, 453115904, 5439488, 823820288, 304070656, 512253952, 333746176, 459786240, 838165504, 110004736, 790742272, 252812928, 527020096, 211068192, 280978992, 542739752, 393040444, 897756962, 806511409 - ], - [ - 536870912, 805306368, 671088640, 469762048, 369098752, 16777216, 25165824, 339738624, 195035136, 726663168, 346554368, 424411136, 317849600, 756482048, 900235264, 684507136, 783523840, 985092096, 150484992, 1030013952, 914296320, 1007005440, 776880000, 597539776, 169582880, 200954608, 101355688, 108152380, 47648258, 357150475 - ], - [ - 536870912, 805306368, 939524096, 872415232, 301989888, 218103808, 662700032, 968884224, 908066816, 588251136, 866648064, 325844992, 256245760, 278069248, 286294016, 245907456, 216817664, 42414080, 884209664, 1057084416, 444641792, 641736448, 1004640640, 120618432, 498618912, 121901904, 636125608, 703964572, 580122630, 739365889 - ], - [ - 536870912, 268435456, 939524096, 335544320, 100663296, 184549376, 276824064, 29360128, 899678208, 326107136, 299368448, 559153152, 516292608, 158793728, 177176576, 65683456, 563404800, 854052864, 1044776960, 548916224, 321823232, 43753216, 1028484224, 137510464, 834682592, 497101776, 1064417000, 64530388, 743830758, 88598737 - ], - [ - 536870912, 805306368, 402653184, 603979776, 234881024, 754974720, 612368384, 331350016, 807403520, 212860928, 746061824, 647757824, 920256512, 374800384, 377782272, 580337664, 287629312, 744935424, 507303936, 732621824, 353241600, 522835712, 745926784, 193925184, 132686368, 701817264, 444557992, 728813052, 978950798, 992761669 - ], - [ - 536870912, 268435456, 671088640, 603979776, 905969664, 520093696, 645922816, 348127232, 685768704, 737148928, 296222720, 143917056, 1063124992, 911015936, 597852160, 484851712, 553689088, 226521088, 742430720, 119645184, 328330752, 832080640, 391957888, 150694976, 811293728, 915122224, 296991624, 54477636, 813498282, 191500153 - ], - [ - 536870912, 268435456, 134217728, 335544320, 436207616, 419430400, 645922816, 1019215872, 455081984, 655360000, 704118784, 64749568, 41549824, 374538240, 542605312, 727826432, 32530432, 793260032, 1073002496, 813640704, 258284032, 130452224, 962152320, 881626688, 493025696, 457059056, 168090536, 355880436, 563144234, 87586993 - ], - [ - 536870912, 805306368, 134217728, 67108864, 167772160, 318767104, 645922816, 314572800, 379584512, 13631488, 580386816, 100925440, 666501120, 760938496, 501907456, 721600512, 407822336, 937996288, 986523648, 501718016, 340019712, 249192192, 212519296, 484615488, 662671712, 776000176, 794947944, 1022468796, 1049147754, 725372605 - ], - [ - 536870912, 268435456, 939524096, 201326592, 771751936, 83886080, 746586112, 322961408, 81788928, 577765376, 320339968, 300154880, 6946816, 455409664, 323649536, 452247552, 79880192, 293187584, 802473984, 605279232, 812765696, 270054144, 207905152, 497793984, 663058080, 475665552, 341631368, 295599044, 644290222, 99771539 - ], - [ - 536870912, 268435456, 939524096, 67108864, 33554432, 218103808, 92274688, 62914560, 878706688, 17825792, 199753728, 262930432, 893517824, 371392512, 196313088, 1008353280, 219570176, 178548736, 415176704, 648590336, 579660288, 863119616, 721080704, 994465472, 896384928, 782462896, 636739496, 935010228, 1046923174, 257731509 - ], - [ - 536870912, 805306368, 134217728, 67108864, 1040187392, 352321536, 713031680, 1035993088, 929038336, 189792256, 709361664, 443809792, 834273280, 591724544, 35880960, 582565888, 613261312, 269987840, 270764032, 1035478016, 755795456, 374771456, 235103360, 692662592, 301249824, 284820880, 954551432, 714253644, 727825186, 156348049 - ], - [ - 536870912, 268435456, 671088640, 335544320, 436207616, 721420288, 998244352, 608174080, 887095296, 542113792, 623378432, 190578688, 358481920, 1033043968, 54886400, 943439872, 802742272, 29683712, 150652928, 922297344, 238333440, 417504512, 933026176, 981424576, 1063505056, 232590992, 396254504, 464761684, 758407042, 660803777 - ], - [ - 536870912, 805306368, 671088640, 603979776, 436207616, 184549376, 1031798784, 331350016, 593494016, 609222656, 463994880, 751566848, 1020657664, 992280576, 398163968, 725762048, 900177920, 75304960, 267368448, 547380224, 523286016, 871972608, 157624448, 18506816, 829594080, 48131696, 207101576, 433331020, 237212010, 1022843449 - ], - [ - 536870912, 268435456, 939524096, 335544320, 436207616, 385875968, 159383552, 918552576, 228589568, 823132160, 213385216, 327417856, 251002880, 445579264, 430669824, 13385728, 1035722752, 385134592, 863913984, 543351808, 113271296, 631244544, 487689088, 45726784, 512012128, 276174672, 634342760, 583684180, 1014834918, 1268753 - ], - [ - 536870912, 268435456, 134217728, 469762048, 503316480, 587202560, 696254464, 1010827264, 333447168, 611319808, 73924608, 192675840, 276168704, 630784000, 894730240, 1072316416, 975167488, 367357952, 413390848, 607316992, 564818432, 83801856, 856971136, 353000768, 519007968, 625802032, 687843848, 890592004, 571123074, 896444999 - ], - [ - 536870912, 268435456, 134217728, 335544320, 973078528, 452984832, 176160768, 96468992, 656408576, 15728640, 620232704, 942407680, 669122560, 1054539776, 769097728, 751157248, 65429504, 1033646080, 586885120, 933633024, 100499968, 149574400, 546187392, 601406784, 685573920, 186289328, 318178600, 808787892, 153046442, 615617265 - ], - [ - 536870912, 268435456, 402653184, 335544320, 704643072, 385875968, 914358272, 994050048, 346030080, 653262848, 699924480, 867434496, 506855424, 1057161216, 947224576, 148258816, 517169152, 972845056, 565946368, 759196672, 899751424, 561010432, 225984128, 399852608, 916920160, 690637456, 728312296, 1052511956, 52149902, 984613953 - ], - [ - 536870912, 268435456, 402653184, 469762048, 503316480, 16777216, 847249408, 1035993088, 98566144, 818937856, 1023934464, 364118016, 648151040, 977076224, 517373952, 25149440, 138108928, 1017229312, 502310912, 549012480, 648934912, 645874432, 934999168, 903888192, 953199136, 956912848, 397738632, 966950468, 163372710, 295086487 - ], - [ - 536870912, 268435456, 402653184, 67108864, 369098752, 150994944, 394264576, 113246208, 987758592, 433061888, 434634752, 743178240, 796000256, 985726976, 954236928, 516997120, 57155584, 722251776, 441600000, 242334720, 1041806848, 294983424, 428273280, 660045632, 876522080, 120752016, 425754632, 17874948, 906502150, 807186433 - ], - [ - 536870912, 268435456, 402653184, 603979776, 637534208, 520093696, 880803840, 633339904, 652214272, 730857472, 198705152, 924581888, 262275072, 146341888, 1053589504, 702201856, 169091072, 977776640, 947337216, 807339008, 187391488, 220049152, 44214400, 490232000, 344802272, 947561360, 1034255880, 141500164, 182653062, 630758601 - ], - [ - 536870912, 268435456, 402653184, 469762048, 33554432, 956301312, 662700032, 264241152, 1004535808, 995098624, 425197568, 830734336, 1043464192, 96927744, 396197888, 789987328, 772087808, 1039298560, 606476288, 164467712, 332337664, 692144384, 530663808, 359691840, 1021873632, 906818864, 539982952, 370222964, 419027854, 536117059 - ], - [ - 536870912, 805306368, 939524096, 201326592, 369098752, 553648128, 729808896, 683671552, 1004535808, 716177408, 847773696, 684982272, 951975936, 655425536, 177831936, 751681536, 892493824, 973320192, 1028360192, 738073600, 1009804800, 801722112, 787828096, 409931840, 552199328, 564431088, 357984264, 188050444, 772673038, 999826179 - ], - [ - 536870912, 268435456, 134217728, 738197504, 234881024, 83886080, 780140544, 1052770304, 534773760, 749731840, 720896000, 111935488, 858390528, 150274048, 60194816, 976699392, 111599616, 462401536, 44730368, 666215424, 590745088, 1042805504, 72310656, 298496704, 1053140448, 1034814992, 75182472, 1018999236, 750916194, 137421019 - ], - [ - 536870912, 805306368, 402653184, 469762048, 100663296, 419430400, 864026624, 574619648, 39845888, 160432128, 854065152, 844365824, 616693760, 227082240, 574980096, 862633984, 188604416, 416788480, 892012544, 593361920, 373711360, 826538752, 113868928, 195378496, 79361440, 1035220112, 974357000, 276843276, 1052805254, 312590663 - ], - [ - 536870912, 268435456, 939524096, 469762048, 905969664, 654311424, 897581056, 222298112, 186646528, 252706816, 1069023232, 69468160, 705560576, 733806592, 851083264, 743096320, 1065574400, 11530240, 736991232, 857979904, 536789504, 66329856, 1003910784, 262765248, 35395232, 762031664, 831771784, 362190788, 185202734, 692873463 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 905969664, 620756992, 813694976, 1069547520, 98566144, 808452096, 599261184, 394526720, 442892288, 726597632, 962822144, 485081088, 818749440, 171577344, 333215744, 47422464, 957354496, 334050560, 55419008, 679115584, 628954208, 1052976336, 175758952, 660954580, 316060906, 188112795 - ], - [ - 536870912, 805306368, 671088640, 738197504, 369098752, 83886080, 947912704, 1052770304, 153092096, 275775488, 392691712, 274464768, 683278336, 958201856, 752582656, 655114240, 513990656, 346615808, 368887808, 336212992, 408272384, 125222144, 463412608, 948098624, 928548704, 97795984, 825662856, 75470412, 231991146, 641830811 - ], - [ - 536870912, 268435456, 939524096, 738197504, 838860800, 1056964608, 92274688, 79691776, 450887680, 814743552, 918028288, 877920256, 374996992, 671547392, 968982528, 140591104, 634429440, 915992576, 321153024, 720622592, 732629504, 99578112, 474813312, 842928448, 97789792, 479893616, 132609768, 533830708, 228163590, 816136207 - ], - [ - 536870912, 268435456, 402653184, 738197504, 503316480, 385875968, 427819008, 171966464, 547356672, 519045120, 227016704, 871628800, 530186240, 175177728, 860389376, 1033158656, 386621440, 594145280, 933509120, 836897792, 143405568, 99054848, 203394944, 60964928, 338460064, 488006096, 982923272, 936840196, 385266182, 776385803 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 1040187392, 721420288, 1065353216, 306184192, 257949696, 938475520, 827850752, 452198400, 197525504, 814809088, 178880512, 1034764288, 104062976, 987164672, 58316800, 132463616, 506343936, 48065280, 346724224, 1040412352, 867096992, 496797488, 457848840, 640928780, 181922314, 729306895 - ], - [ - 536870912, 268435456, 134217728, 67108864, 1040187392, 218103808, 92274688, 239075328, 568328192, 1060110336, 217579520, 44826624, 932315136, 296550400, 789741568, 309149696, 78815232, 851226624, 981125120, 963156992, 17086976, 1052152576, 9094016, 254883008, 351876832, 246192208, 227722120, 581776580, 663959266, 430807121 - ], - [ - 536870912, 268435456, 939524096, 738197504, 33554432, 184549376, 142606336, 1010827264, 677380096, 711983104, 376963072, 445906944, 366608384, 962265088, 52133888, 913981440, 831201280, 439562240, 386361344, 873278464, 629132800, 681118976, 765730432, 1010994496, 327150048, 496561968, 338029032, 797175604, 232679910, 684306239 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 436207616, 352321536, 176160768, 994050048, 773849088, 781189120, 640155648, 909377536, 239206400, 891224064, 994607104, 981778432, 888840192, 201469952, 331282432, 798571520, 504147456, 404675328, 365469056, 264628672, 702211808, 655613104, 290870632, 105655932, 733908482, 194521859 - ], - [ - 536870912, 268435456, 671088640, 201326592, 570425344, 520093696, 612368384, 54525952, 153092096, 311427072, 222822400, 790888448, 165019648, 500760576, 762085376, 712196096, 458186752, 462721024, 177158144, 418710528, 750774784, 300802304, 489924736, 342754368, 939799072, 507995952, 252760584, 193520900, 348406410, 648537411 - ], - [ - 536870912, 268435456, 939524096, 738197504, 771751936, 218103808, 25165824, 943718400, 610271232, 128974848, 470286336, 1061421056, 387842048, 632356864, 789086208, 197509120, 48193536, 395341824, 30992384, 301845504, 433234432, 464212736, 885511552, 122465344, 39458848, 95374320, 70838280, 1041091588, 431661582, 257905419 - ], - [ - 536870912, 805306368, 939524096, 738197504, 33554432, 285212672, 847249408, 574619648, 782237696, 101711872, 746061824, 800325632, 376832000, 3211264, 86605824, 636338176, 546529280, 606015488, 536610816, 116118528, 246067712, 353010944, 932964480, 111304640, 641190816, 932211888, 632907784, 97895436, 847723022, 402166027 - ], - [ - 536870912, 805306368, 134217728, 603979776, 167772160, 788529152, 8388608, 759169024, 836763648, 267386880, 782761984, 762052608, 520749056, 182255616, 532905984, 226574336, 381722624, 505417728, 407918592, 439899136, 242487808, 766479104, 436868480, 358382144, 973264096, 891415824, 584174984, 276393548, 454321890, 85947929 - ], - [ - 536870912, 268435456, 402653184, 469762048, 301989888, 956301312, 796917760, 130023424, 895483904, 32505856, 266862592, 231473152, 551944192, 77791232, 855212032, 991182848, 388112384, 926511104, 796252160, 626160640, 756064768, 786007296, 734309504, 563866816, 613269280, 835160656, 1039372712, 746623892, 88168974, 186745091 - ], - [ - 536870912, 805306368, 134217728, 872415232, 100663296, 788529152, 746586112, 104857600, 480247808, 735051776, 1018691584, 972292096, 977928192, 226820096, 195264512, 461979648, 624697344, 72773632, 113498112, 809096192, 263490048, 787112192, 307625088, 823904448, 226348320, 871842192, 261227656, 297823436, 6332194, 372372637 - ], - [ - 536870912, 268435456, 671088640, 469762048, 1040187392, 989855744, 746586112, 624951296, 312475648, 397410304, 484966400, 859570176, 503185408, 984023040, 326336512, 850444288, 459874304, 318525440, 907986944, 28724224, 589960704, 837032704, 283779712, 654680000, 142314272, 1016896848, 969889064, 630114900, 246374818, 64966291 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 234881024, 620756992, 880803840, 79691776, 450887680, 1020264448, 749207552, 1067188224, 522321920, 294322176, 488013824, 129351680, 343875584, 1011470336, 206387200, 940293120, 156649984, 60138752, 625934208, 867193024, 171526432, 840216496, 621740840, 93391548, 269089954, 745364083 - ], - [ - 536870912, 805306368, 939524096, 67108864, 436207616, 150994944, 746586112, 205520896, 44040192, 238026752, 956825600, 252968960, 48103424, 671940608, 364085248, 65978368, 444899328, 291934208, 777037824, 81269760, 873282048, 1001593088, 686729088, 990213952, 732379168, 699477296, 617190792, 259385932, 252677550, 722835313 - ], - [ - 536870912, 268435456, 671088640, 603979776, 234881024, 956301312, 260046848, 289406976, 211812352, 95420416, 428343296, 869531648, 1029308416, 377028608, 712802304, 184500224, 1036656640, 369225728, 620759040, 226499584, 37870080, 874634496, 577870208, 199768640, 730165664, 767795792, 966087176, 1031438596, 302539658, 1016403785 - ], - [ - 536870912, 268435456, 671088640, 335544320, 234881024, 83886080, 243269632, 381681664, 379584512, 248512512, 842530816, 819200000, 1007550464, 666173440, 637435904, 538722304, 955392000, 586559488, 448858112, 883016704, 970030592, 599265536, 596940928, 938440896, 662975008, 427225776, 981481608, 146868420, 1000413738, 340788917 - ], - [ - 536870912, 805306368, 134217728, 67108864, 301989888, 855638016, 310378496, 683671552, 908066816, 856686592, 849870848, 614727680, 621412352, 448593920, 240615424, 760954880, 661954560, 495144960, 319354880, 1022731264, 549588480, 90807552, 637885056, 400210496, 1001699488, 832795536, 387517576, 249353036, 531010594, 79933649 - ], - [ - 536870912, 268435456, 939524096, 335544320, 100663296, 620756992, 377487360, 792723456, 580911104, 412090368, 306708480, 547094528, 815661056, 247922688, 408125440, 896548864, 947511296, 306532352, 374061056, 415542272, 51013120, 895752960, 974818176, 1038988224, 619076128, 243422800, 756646952, 506847572, 45279654, 717228433 - ], - [ - 536870912, 805306368, 671088640, 469762048, 570425344, 1023410176, 75497472, 985661440, 190840832, 877658112, 215482368, 780402688, 669122560, 195756032, 630620160, 354533376, 904929280, 468234240, 168564736, 666819584, 1070406144, 224274688, 31223680, 237436736, 258596960, 684500464, 417227368, 899518716, 512178146, 383383227 - ], - [ - 536870912, 268435456, 939524096, 67108864, 637534208, 385875968, 142606336, 775946240, 740294656, 743440384, 292028416, 851181568, 742785024, 565903360, 777879552, 1031225344, 69394432, 764973056, 801425408, 145955840, 965813760, 763960064, 864894848, 836698048, 645873056, 451923024, 652706344, 413823892, 26500998, 953823173 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 503316480, 83886080, 226492416, 935329792, 610271232, 338690048, 683147264, 314834944, 132775936, 634454016, 256409600, 337461248, 639623168, 470020096, 119384064, 44018688, 272768512, 767406848, 558872960, 504013248, 1042404384, 395426384, 820529160, 307059716, 597112330, 905928463 - ], - [ - 536870912, 805306368, 939524096, 67108864, 234881024, 587202560, 478150656, 171966464, 526385152, 126877696, 974651392, 121372672, 595722240, 426442752, 400457728, 1064910848, 632053760, 438013952, 43403264, 209521664, 23326208, 423275776, 224806272, 460668736, 285624736, 811914032, 425693096, 741925436, 860646438, 743079037 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 301989888, 352321536, 75497472, 79691776, 576716800, 846200832, 155713536, 814481408, 835846144, 462225408, 710115328, 449593344, 645029888, 152883200, 782944256, 48821248, 1895936, 137029376, 992607616, 452750656, 748411360, 83891152, 478281096, 281046348, 207739370, 896603103 - ], - [ - 536870912, 268435456, 939524096, 738197504, 905969664, 419430400, 8388608, 750780416, 115343360, 735051776, 498597888, 602669056, 977403904, 512688128, 58556416, 274415616, 504602624, 645353472, 842086400, 132705280, 102003200, 697256192, 654120320, 840603968, 20080544, 1036395248, 832131624, 1071426484, 413904262, 370816335 - ], - [ - 536870912, 268435456, 671088640, 738197504, 637534208, 922746880, 327155712, 1002438656, 1000341504, 703594496, 555220992, 378798080, 420610048, 816644096, 439779328, 717635584, 324984832, 596373504, 569907200, 914689024, 681276928, 502376704, 320341376, 60125120, 932316192, 166509776, 1054315400, 282474180, 467048874, 106405659 - ], - [ - 536870912, 805306368, 939524096, 201326592, 905969664, 285212672, 1031798784, 331350016, 815792128, 552599552, 600309760, 746848256, 980287488, 522649600, 853704704, 862797824, 676995072, 501288960, 487643136, 249107456, 442341888, 741558016, 85300352, 653783232, 672867296, 327207952, 1052817896, 52464412, 775007590, 417938399 - ], - [ - 536870912, 805306368, 134217728, 469762048, 570425344, 1023410176, 914358272, 650117120, 450887680, 439353344, 511180800, 948174848, 310509568, 652935168, 449216512, 495501312, 127737856, 678932480, 170989568, 645450752, 746924544, 746763520, 971710592, 289905984, 231248480, 1002288624, 682033256, 242793724, 8729322, 109242555 - ], - [ - 536870912, 805306368, 402653184, 67108864, 905969664, 184549376, 1048576000, 1069547520, 710934528, 732954624, 347602944, 588513280, 897187840, 387121152, 932085760, 798507008, 889544704, 1007898624, 957270016, 140024832, 459608576, 564377856, 649552000, 365806400, 299764960, 483523760, 982038248, 787319228, 130944110, 364408829 - ], - [ - 536870912, 805306368, 939524096, 201326592, 234881024, 318767104, 847249408, 658505728, 367001600, 357564416, 784859136, 663486464, 759824384, 497352704, 941064192, 753319936, 2023424, 55259136, 1051047936, 848806912, 128414208, 469709568, 85699712, 585944896, 844875744, 1057844112, 319438472, 331664460, 696767342, 521101523 - ], - [ - 536870912, 805306368, 134217728, 67108864, 637534208, 16777216, 713031680, 801112064, 937426944, 611319808, 765984768, 741605376, 847118336, 532348928, 808222720, 520339456, 604069888, 369135616, 151091200, 780237824, 163650048, 920701184, 250726528, 40448192, 466990048, 370135504, 840106856, 471375132, 763177610, 1002128845 - ], - [ - 536870912, 268435456, 402653184, 201326592, 369098752, 956301312, 830472192, 180355072, 408944640, 397410304, 668467200, 848560128, 959315968, 159711232, 740720640, 955891712, 696573952, 1009152000, 553166848, 629521408, 707223040, 435695360, 335862656, 552007104, 26854688, 62165424, 121508744, 856488388, 983225126, 247165619 - ], - [ - 536870912, 268435456, 671088640, 67108864, 570425344, 285212672, 8388608, 859832320, 421527552, 609222656, 973602816, 1015808000, 457572352, 417923072, 649887744, 373243904, 792535040, 436178944, 190629888, 328115200, 646236672, 936042752, 732853888, 978674240, 310638944, 671255216, 910387720, 568537348, 32710282, 291182145 - ], - [ - 536870912, 805306368, 402653184, 335544320, 838860800, 553648128, 713031680, 901775360, 882900992, 1053818880, 717750272, 815005696, 485359616, 987037696, 890208256, 1013301248, 725032960, 522735616, 941893632, 500564992, 874055168, 710729984, 880513152, 842663744, 1037749280, 678124592, 1037176968, 31377228, 330066982, 455330869 - ], - [ - 536870912, 268435456, 402653184, 67108864, 33554432, 318767104, 209715200, 46137344, 815792128, 462422016, 445120512, 242483200, 168165376, 1005256704, 1020362752, 594034688, 822403072, 780021760, 178751488, 679181312, 978924032, 723383040, 704883072, 169189568, 943115232, 963840400, 544069736, 75179604, 878184462, 639384581 - ], - [ - 536870912, 268435456, 134217728, 603979776, 100663296, 1023410176, 897581056, 1027604480, 65011712, 122683392, 805830656, 253493248, 997851136, 459997184, 797147136, 89112576, 436002816, 1034670080, 404994048, 981390336, 182738432, 853430528, 726938496, 470169536, 184609056, 276830192, 616616232, 480314356, 1068527402, 1071153917 - ], - [ - 536870912, 268435456, 939524096, 603979776, 1040187392, 486539264, 780140544, 859832320, 442499072, 670040064, 936902656, 298582016, 450232320, 728039424, 562200576, 522108928, 1027645440, 794865664, 359663616, 513385472, 682394112, 245845760, 24957312, 426670016, 945398496, 101578736, 687233928, 24485060, 309031278, 220860217 - ], - [ - 536870912, 805306368, 402653184, 469762048, 973078528, 822083584, 964689920, 792723456, 136314880, 420478976, 924319744, 108265472, 37093376, 106496000, 693469184, 833011712, 176283648, 197152768, 1021396992, 326183936, 631810560, 910018816, 50005120, 877380288, 302183072, 30316848, 660417032, 818612492, 381871238, 330273479 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 167772160, 419430400, 226492416, 79691776, 845152256, 504365056, 844627968, 49545216, 1036648448, 776929280, 340623360, 628047872, 352133120, 1061629952, 205543424, 555860992, 162650624, 799579392, 545087360, 638028864, 48331360, 827436912, 804871656, 100980532, 314811782, 826483019 - ], - [ - 536870912, 805306368, 671088640, 469762048, 234881024, 1023410176, 662700032, 876609536, 358612992, 812646400, 142082048, 392953856, 1057095680, 24444928, 111116288, 533610496, 514220032, 398700544, 383043584, 374303744, 669424128, 220360448, 249906560, 89636544, 1039916512, 500746576, 750632840, 699032012, 321933418, 228137879 - ], - [ - 536870912, 268435456, 939524096, 67108864, 771751936, 285212672, 696254464, 272629760, 685768704, 321912832, 167247872, 381943808, 236060672, 683868160, 428572672, 368459776, 926965760, 73404416, 1022367744, 609784832, 714356224, 362414336, 916394112, 36475712, 306079584, 66908400, 267788136, 541095156, 14692710, 791798261 - ], - [ - 536870912, 268435456, 134217728, 201326592, 369098752, 520093696, 109051904, 71303168, 1054867456, 309329920, 154664960, 866910208, 514457600, 601817088, 489259008, 799326208, 39723008, 199872512, 117753856, 734956544, 522286592, 542237952, 988404864, 176459328, 990856864, 545351472, 54643752, 1013046388, 204578314, 1054456071 - ], - [ - 536870912, 268435456, 939524096, 872415232, 369098752, 285212672, 562036736, 792723456, 1004535808, 28311552, 608698368, 995360768, 274071552, 418971648, 211582976, 994295808, 936288256, 219492352, 372754432, 738749440, 540338688, 656811776, 470886784, 463037504, 535574432, 296483888, 97198600, 507136772, 236176270, 1052132173 - ], - [ - 536870912, 805306368, 402653184, 738197504, 167772160, 83886080, 394264576, 826277888, 689963008, 97517568, 152567808, 675020800, 310509568, 235208704, 7307264, 522174464, 748150784, 529666048, 343738368, 673369088, 76894720, 56061184, 712155264, 349044672, 910819424, 455129424, 483398280, 211321548, 813541606, 639863451 - ], - [ - 536870912, 805306368, 671088640, 872415232, 369098752, 620756992, 645922816, 557842432, 593494016, 118489088, 639107072, 157548544, 869400576, 678625280, 348291072, 1047248896, 900096000, 968413184, 198506496, 142232576, 322897408, 480001280, 166131072, 274320704, 663077472, 167976688, 147530344, 731320060, 206649954, 846811889 - ], - [ - 536870912, 805306368, 134217728, 872415232, 503316480, 520093696, 813694976, 381681664, 224395264, 942669824, 493355008, 941359104, 529399808, 652935168, 922779648, 880918528, 12705792, 643911680, 380635136, 346651648, 100479488, 830397696, 920824448, 925739712, 912714656, 506977424, 250485544, 81413980, 594018314, 387710977 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 436207616, 989855744, 578813952, 801112064, 610271232, 9437184, 771227648, 675545088, 839778304, 193134592, 138510336, 606158848, 816848896, 55128064, 906823680, 126012416, 977365504, 455138560, 875620224, 227052352, 200080864, 173214288, 471455848, 395698196, 727154694, 62275595 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 167772160, 251658240, 612368384, 440401920, 480247808, 61865984, 208142336, 1054081024, 1001521152, 1056636928, 744390656, 417611776, 1744896, 1062105088, 87902208, 27675648, 346664448, 355803904, 723698304, 971188160, 486714976, 689063792, 877371496, 431363196, 737192686, 331890611 - ], - [ - 536870912, 268435456, 134217728, 872415232, 369098752, 16777216, 578813952, 197132288, 316669952, 879755264, 126353408, 575930368, 642908160, 890568704, 443711488, 788873216, 390799360, 750383104, 771565568, 135783424, 528414208, 240825088, 67122560, 234938176, 1023524640, 8421840, 482391432, 828415812, 489692962, 514339293 - ], - [ - 536870912, 268435456, 402653184, 738197504, 436207616, 754974720, 142606336, 876609536, 182452224, 479199232, 987234304, 749993984, 491388928, 887422976, 624066560, 203538432, 523362304, 1009258496, 314312704, 465998848, 881576448, 1053135616, 84084352, 562635200, 122466592, 776881296, 365399688, 1066104260, 423893798, 952240027 - ], - [ - 536870912, 268435456, 671088640, 738197504, 436207616, 16777216, 864026624, 574619648, 1059061760, 951058432, 314048512, 448004096, 960364544, 785317888, 987201536, 328384512, 414556160, 742289408, 55572480, 798467072, 70424064, 818208512, 275169920, 1009402688, 58841312, 440523280, 992059624, 246464020, 163092194, 674566431 - ], - [ - 536870912, 268435456, 402653184, 469762048, 905969664, 754974720, 662700032, 926941184, 803209216, 238026752, 771227648, 528744448, 54657024, 597229568, 66355200, 584761344, 795729920, 430911488, 443983872, 316824576, 533285376, 343717632, 700898688, 459009472, 556656416, 600819088, 604416520, 746227460, 868021638, 99054023 - ], - [ - 536870912, 805306368, 671088640, 738197504, 436207616, 620756992, 528482304, 46137344, 987758592, 986710016, 522715136, 504102912, 62259200, 401276928, 724860928, 24297472, 486612992, 729821184, 482392064, 702592000, 441465344, 661186816, 967638400, 21445056, 150134304, 281131856, 65051560, 391198364, 350814082, 560833735 - ], - [ - 536870912, 268435456, 402653184, 67108864, 637534208, 520093696, 964689920, 1044381696, 492830720, 860880896, 192413696, 44302336, 456523776, 88539136, 856653824, 167985152, 464084992, 446517248, 477308928, 836838400, 26310144, 886631680, 374697856, 12576832, 980076384, 135610832, 232722280, 289043924, 124531054, 695921877 - ], - [ - 536870912, 268435456, 134217728, 738197504, 33554432, 889192448, 226492416, 12582912, 538968064, 531628032, 83361792, 287047680, 838991872, 392888320, 843022336, 156876800, 510500864, 517681152, 902289408, 113529856, 976159232, 332483328, 2624128, 968106816, 251066016, 360465712, 450071720, 1036151348, 1003183146, 114251391 - ], - [ - 536870912, 268435456, 671088640, 201326592, 905969664, 654311424, 578813952, 440401920, 207618048, 493879296, 806879232, 719585280, 559808512, 557252608, 810254336, 3194880, 251240448, 97816576, 287762432, 547527680, 101547520, 694314240, 95189632, 682776640, 853865568, 358551824, 859267688, 759949332, 867198690, 288937303 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 973078528, 452984832, 377487360, 339738624, 513802240, 303038464, 880279552, 742129664, 679346176, 1030422528, 1030782976, 906608640, 850763776, 462041088, 868222976, 1063382016, 980440576, 713668352, 905295232, 799796032, 261191200, 247005200, 316415400, 584020060, 973285386, 682957827 - ], - [ - 536870912, 805306368, 402653184, 738197504, 503316480, 855638016, 612368384, 566231040, 1025507328, 80740352, 265814016, 714342400, 1032454144, 506134528, 305823744, 490881024, 927408128, 276156416, 729499648, 933424128, 162963968, 234679040, 49700224, 169724736, 730227680, 315917744, 518734824, 379213244, 936545262, 754907575 - ], - [ - 536870912, 805306368, 939524096, 738197504, 167772160, 855638016, 1031798784, 180355072, 761266176, 1047527424, 282591232, 1048313856, 222691328, 875888640, 22249472, 1001832448, 447602688, 772673536, 1050687488, 764500992, 568876544, 621051648, 707402112, 618341312, 641861472, 52300144, 889823112, 1068830924, 982776046, 207014331 - ], - [ - 536870912, 805306368, 939524096, 201326592, 369098752, 452984832, 914358272, 490733568, 954204160, 133169152, 285736960, 789839872, 183369728, 979173376, 446398464, 696434688, 904847360, 517861376, 1054537728, 652452864, 350118400, 133520128, 85956992, 525599040, 797958688, 778845104, 573733768, 797416012, 855153582, 740084467 - ], - [ - 536870912, 805306368, 939524096, 603979776, 570425344, 117440512, 662700032, 432013312, 891289600, 355467264, 361234432, 709623808, 1036386304, 567214080, 457342976, 220545024, 110845952, 640741376, 403277824, 680383488, 694610432, 138300160, 460027520, 203018432, 37026208, 228739344, 1043600296, 1000538652, 590734630, 1059295957 - ], - [ - 536870912, 805306368, 671088640, 67108864, 838860800, 318767104, 763363328, 532676608, 664797184, 735051776, 973602816, 217317376, 265945088, 423034880, 766541824, 595116032, 967663616, 476557312, 1039665152, 1005351936, 201773568, 898163456, 406090624, 704337600, 455605216, 286914416, 987615848, 1044313788, 835053570, 333644813 - ], - [ - 536870912, 805306368, 134217728, 872415232, 167772160, 251658240, 813694976, 230686720, 652214272, 735051776, 486014976, 838074368, 7733248, 699203584, 972259328, 164839424, 241377280, 864718848, 1021777920, 561296384, 1035347456, 122452736, 639810688, 522932928, 815223840, 58587120, 411712136, 1047001548, 531910818, 366395709 - ], - [ - 536870912, 268435456, 402653184, 872415232, 771751936, 117440512, 176160768, 826277888, 337641472, 776994816, 678952960, 551813120, 158728192, 764870656, 640122880, 879706112, 1057153024, 91852800, 191145984, 431389696, 410400256, 68663040, 736589184, 571452992, 569609568, 890270928, 492367208, 792044756, 13575534, 17959129 - ], - [ - 536870912, 805306368, 939524096, 201326592, 167772160, 822083584, 914358272, 339738624, 819986432, 787480576, 716701696, 434372608, 1011744768, 923729920, 242122752, 224346112, 46604288, 485715968, 131397632, 1062620160, 880438784, 522823936, 90996352, 582130496, 909462624, 522613264, 109300840, 1009594908, 651357286, 159728159 - ], - [ - 536870912, 805306368, 939524096, 872415232, 637534208, 251658240, 176160768, 734003200, 1021313024, 428867584, 571998208, 131334144, 257032192, 359596032, 94404608, 179322880, 426270720, 123506688, 102713344, 958999552, 704416256, 674199808, 142707584, 180448320, 895522400, 718385200, 473481192, 656742780, 362471430, 662949889 - ], - [ - 536870912, 268435456, 402653184, 738197504, 1040187392, 989855744, 864026624, 977272832, 857735168, 149946368, 887619584, 936116224, 438173696, 526450688, 617644032, 93896704, 275079168, 678686720, 1062131712, 901258240, 387289600, 14301440, 748935040, 718671680, 1037875808, 325566192, 26599432, 572207108, 239319046, 122153995 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 503316480, 1023410176, 847249408, 499122176, 908066816, 890241024, 706215936, 512491520, 62783488, 128122880, 289767424, 998916096, 373301248, 727814144, 636606464, 447323136, 818252288, 566933248, 723553664, 395351616, 802739616, 346857744, 682590248, 280669012, 1028218766, 636878155 - ], - [ - 536870912, 805306368, 402653184, 67108864, 973078528, 419430400, 8388608, 473956352, 367001600, 544210944, 662175744, 274989056, 917897216, 329449472, 351043584, 879443968, 609345536, 472412160, 466475008, 180022272, 221787648, 176489728, 692545664, 253491776, 782780384, 848149776, 970651496, 369666908, 463242894, 479400781 - ], - [ - 536870912, 268435456, 939524096, 67108864, 301989888, 855638016, 880803840, 608174080, 14680064, 141557760, 153616384, 512491520, 993656832, 914292736, 79265792, 441794560, 929030144, 132755456, 925730816, 439090176, 48735744, 574371072, 347249792, 727928512, 240824096, 231629488, 632321448, 738765172, 534629894, 490895621 - ], - [ - 536870912, 268435456, 939524096, 67108864, 905969664, 654311424, 478150656, 490733568, 1038090240, 95420416, 682098688, 373555200, 278790144, 193265664, 306085888, 450150400, 10919936, 335114240, 31299584, 741512192, 675213824, 668285696, 824622976, 121155136, 754804128, 849569456, 956710792, 1009348164, 654656942, 662623921 - ], - [ - 536870912, 268435456, 671088640, 738197504, 973078528, 620756992, 528482304, 364904448, 111149056, 793772032, 122159104, 41680896, 447610880, 125108224, 934445056, 640303104, 299819008, 825036800, 535267328, 604507136, 614315520, 731869440, 441213056, 840371520, 437295712, 1051245744, 164451976, 232209476, 296786666, 578347515 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 33554432, 218103808, 964689920, 406847488, 664797184, 550502400, 133693440, 354680832, 673841152, 692387840, 505053184, 642596864, 123166720, 228282368, 520882176, 326573056, 67766784, 81035520, 868449408, 905447104, 2478496, 631945616, 251960456, 918230724, 840710562, 560969119 - ], - [ - 536870912, 805306368, 671088640, 603979776, 1040187392, 822083584, 897581056, 960495616, 648019968, 984612864, 479723520, 152829952, 660209664, 557252608, 613711872, 1072611328, 698966016, 331698176, 610744320, 337380352, 953816576, 1064777472, 582282368, 933219136, 466710816, 860380080, 475276712, 101602556, 146317954, 443394117 - ], - [ - 536870912, 805306368, 939524096, 335544320, 1040187392, 184549376, 931135488, 557842432, 731906048, 330301440, 295174144, 413401088, 334364672, 254738432, 13533184, 1012875264, 1018683392, 23728128, 959465472, 274265088, 935624192, 733930240, 606592640, 126034496, 468483936, 562232336, 887947112, 268614684, 179150694, 841215001 - ], - [ - 536870912, 805306368, 671088640, 469762048, 33554432, 922746880, 796917760, 507510784, 224395264, 714080256, 176685056, 1026293760, 644743168, 30998528, 1015382016, 145965056, 430956544, 1073254400, 938833920, 124443648, 137036288, 466305792, 26890368, 515045952, 11419744, 226002160, 758512136, 969662220, 110834314, 422734151 - ], - [ - 536870912, 805306368, 402653184, 469762048, 503316480, 922746880, 847249408, 62914560, 878706688, 546308096, 879230976, 732168192, 351928320, 429850624, 176455680, 835403776, 134684672, 744001536, 364644352, 778439680, 231250432, 542471424, 914508672, 127061440, 683357024, 431924592, 506853608, 185804988, 746318734, 123608523 - ], - [ - 536870912, 268435456, 134217728, 201326592, 33554432, 150994944, 411041792, 717225984, 799014912, 598736896, 1063780352, 194248704, 497156096, 240844800, 668434432, 657047552, 469016576, 53620736, 1027815424, 638262272, 829299200, 4542208, 677086848, 819389376, 1017759328, 750010608, 483542120, 311632884, 234053866, 216159031 - ], - [ - 536870912, 268435456, 671088640, 335544320, 838860800, 83886080, 629145600, 482344960, 404750336, 674234368, 1019740160, 669777920, 539623424, 272171008, 788824064, 569851904, 802922496, 173019136, 312076288, 1064619008, 643814912, 904296704, 824427904, 678751296, 383678560, 614986192, 566410760, 711324932, 120042378, 436372805 - ], - [ - 536870912, 805306368, 671088640, 469762048, 704643072, 16777216, 545259520, 650117120, 1012924416, 860880896, 277348352, 304873472, 914751488, 304807936, 426541056, 1051115520, 249208832, 274018304, 43227136, 655993856, 331612672, 897240320, 266638720, 797703360, 98338848, 775895248, 6167976, 907002908, 403051906, 468335819 - ], - [ - 536870912, 268435456, 402653184, 335544320, 369098752, 218103808, 58720256, 952107008, 383778816, 852492288, 868745216, 483655680, 854458368, 666828800, 850886656, 964902912, 943579136, 260722688, 965326848, 997516288, 958382592, 1019651328, 255576960, 80761280, 784901472, 122973968, 506404200, 660572948, 224878446, 164261393 - ], - [ - 536870912, 805306368, 134217728, 872415232, 771751936, 822083584, 1031798784, 893386752, 836763648, 879755264, 250085376, 237240320, 284033024, 356974592, 595755008, 110936064, 846356480, 825593856, 532076544, 1051350016, 647556608, 718108928, 164359808, 1026058176, 268793824, 280963600, 218044904, 211718940, 531535722, 195519697 - ], - [ - 536870912, 268435456, 939524096, 469762048, 167772160, 251658240, 796917760, 851443712, 991952896, 844103680, 699924480, 758382592, 367132672, 728694784, 884572160, 28655616, 983769088, 831500288, 407480320, 664552448, 714066432, 164232960, 878502784, 657333056, 601435744, 881154480, 506071016, 607305204, 303548934, 162397955 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 369098752, 989855744, 25165824, 926941184, 685768704, 596639744, 792199168, 614203392, 720502784, 493027328, 274366464, 499597312, 666148864, 555159552, 342640640, 874185728, 10886656, 560220416, 936320384, 1071669312, 1007737504, 662242352, 670864040, 320995388, 540708006, 563497267 - ], - [ - 536870912, 268435456, 671088640, 872415232, 33554432, 385875968, 293601280, 574619648, 417333248, 988807168, 522715136, 781451264, 325976064, 697106432, 619872256, 245776384, 652746752, 657838080, 184440832, 219429888, 506411520, 1022145280, 172190080, 477068352, 873266208, 414378416, 927370120, 412660548, 484183978, 256620285 - ], - [ - 536870912, 268435456, 939524096, 738197504, 973078528, 184549376, 880803840, 96468992, 513802240, 439353344, 885522432, 870055936, 81133568, 198115328, 9142272, 978862080, 1042554880, 591622144, 788916224, 540191744, 346886656, 25075456, 260250240, 841300672, 155442464, 470140944, 951224104, 728615700, 350144422, 557052639 - ], - [ - 536870912, 268435456, 134217728, 872415232, 301989888, 50331648, 1065353216, 423624704, 81788928, 923795456, 84410368, 478937088, 97386496, 1008795648, 397443072, 611860480, 760586240, 795512832, 861083648, 1046903808, 1021118976, 824657664, 826132608, 112689216, 888459360, 379199600, 1045110792, 1046728708, 769538050, 816360461 - ], - [ - 536870912, 268435456, 402653184, 872415232, 771751936, 956301312, 343932928, 1002438656, 975175680, 271581184, 1010302976, 494141440, 180224000, 226689024, 588349440, 814235648, 915234816, 938135552, 899072, 1059843072, 564967936, 224079616, 653648000, 956270656, 786636384, 1069582416, 471891176, 87065364, 850974734, 833960969 - ], - [ - 536870912, 268435456, 671088640, 335544320, 33554432, 520093696, 494927872, 171966464, 1050673152, 258998272, 150470656, 1002176512, 226361344, 712704000, 991526912, 1005436928, 1052237824, 782217216, 36399104, 483447808, 1024056832, 411326208, 337888896, 198522944, 342580256, 611368208, 125355176, 117183060, 979353090, 759834369 - ], - [ - 536870912, 268435456, 671088640, 872415232, 771751936, 956301312, 8388608, 1010827264, 157286400, 267386880, 742916096, 486801408, 767688704, 305987584, 47087616, 546979840, 289415168, 937472000, 582035456, 296276992, 11885056, 837519104, 4757888, 1057246016, 650353824, 834458576, 688843656, 742004804, 722525994, 561602461 - ], - [ - 536870912, 805306368, 671088640, 603979776, 301989888, 587202560, 897581056, 423624704, 970981376, 877658112, 966262784, 914620416, 282460160, 623968256, 67731456, 54345728, 2301952, 1057984512, 433428480, 550464512, 351644160, 943718144, 383543936, 846452928, 529924640, 500251568, 249083912, 845544460, 67613194, 23646985 - ], - [ - 536870912, 268435456, 402653184, 603979776, 33554432, 1056964608, 847249408, 473956352, 723517440, 74448896, 471334912, 690749440, 541982720, 455409664, 665485312, 1022345216, 982818816, 609374208, 1037244416, 420684800, 762464768, 379802880, 797648256, 1008653248, 533475296, 266223408, 892098440, 374289092, 1042610278, 237751801 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 570425344, 184549376, 1031798784, 910163968, 169869312, 546308096, 914882560, 114032640, 20054016, 33882112, 601849856, 312983552, 500391936, 511004672, 958855168, 378723328, 617978368, 125285632, 150676096, 141151040, 297589216, 642415696, 812726408, 284802636, 724867942, 445048607 - ], - [ - 536870912, 268435456, 671088640, 469762048, 973078528, 620756992, 109051904, 205520896, 656408576, 198180864, 728236032, 772538368, 296615936, 400883712, 98729984, 376061952, 643260416, 136384512, 273680384, 363348992, 594311680, 576713984, 349970560, 172405824, 44578272, 216846768, 983456392, 113000772, 439784810, 189801975 - ], - [ - 536870912, 805306368, 671088640, 67108864, 570425344, 251658240, 394264576, 4194304, 48234496, 540016640, 1043857408, 282853376, 408027136, 74514432, 786006016, 401424384, 904536064, 921440256, 996931584, 606927872, 625713664, 859653888, 920836480, 680009152, 539319520, 414071184, 573732872, 58833932, 977371658, 568416001 - ], - [ - 536870912, 805306368, 939524096, 335544320, 234881024, 956301312, 612368384, 79691776, 291504128, 303038464, 641204224, 564920320, 702676992, 750321664, 745373696, 604225536, 778674176, 355856384, 784205824, 87196672, 484496896, 978387712, 530109568, 954058688, 717897312, 917255056, 73586184, 888668940, 768431246, 695338949 - ], - [ - 536870912, 805306368, 671088640, 335544320, 436207616, 50331648, 679477248, 918552576, 929038336, 1041235968, 900202496, 951320576, 270925824, 708902912, 732004352, 577847296, 926457856, 568119296, 485627904, 754336768, 42546688, 101022464, 998117504, 151838016, 775589280, 39034160, 856129544, 250626060, 66658314, 700289029 - ], - [ - 536870912, 268435456, 939524096, 201326592, 503316480, 889192448, 679477248, 708837376, 656408576, 133169152, 574095360, 176422912, 724959232, 16318464, 400850944, 870825984, 691101696, 559443968, 659843072, 712975360, 470065664, 611717376, 928627584, 911516608, 687758624, 289779248, 14033416, 124309764, 831282062, 686494659 - ], - [ - 536870912, 805306368, 939524096, 603979776, 436207616, 150994944, 360710144, 926941184, 241172480, 808452096, 724041728, 1035730944, 1039532032, 273350656, 633110528, 704004096, 843833344, 146632704, 645322752, 202048512, 324822528, 554111232, 692254336, 516996800, 937010592, 79033552, 110842664, 241519132, 323155590, 667991749 - ], - [ - 536870912, 268435456, 671088640, 603979776, 973078528, 956301312, 696254464, 289406976, 333447168, 363855872, 188219392, 529793024, 648937472, 1051656192, 581926912, 346996736, 867164160, 422457344, 418379776, 869184512, 618544640, 699834624, 682232960, 447239488, 490580448, 663886992, 792570344, 714218644, 347974114, 651304093 - ], - [ - 536870912, 805306368, 939524096, 872415232, 301989888, 318767104, 58720256, 968884224, 715128832, 619708416, 585629696, 776208384, 998113280, 792395776, 994344960, 167657472, 1048272896, 530952192, 745424896, 29615104, 880304640, 578605824, 291673728, 1065996992, 487945824, 870817616, 752345320, 1067339164, 984258182, 1023267521 - ], - [ - 536870912, 805306368, 939524096, 67108864, 301989888, 553648128, 427819008, 935329792, 966787072, 19922944, 896008192, 400818176, 428474368, 660537344, 129794048, 419840000, 808509440, 619261952, 472143872, 908846080, 359588352, 173406976, 547571840, 668662976, 992405856, 801153776, 228719080, 724679228, 275378822, 476373965 - ], - [ - 536870912, 268435456, 134217728, 738197504, 33554432, 50331648, 360710144, 398458880, 35651584, 221249536, 983040000, 557056000, 915537920, 687931392, 713064448, 138428416, 987848704, 412094464, 594024448, 202157056, 223788544, 657133824, 797305216, 785061056, 982854048, 1046627472, 448266248, 1057226756, 294256642, 871694347 - ], - [ - 536870912, 268435456, 134217728, 469762048, 1040187392, 1056964608, 494927872, 524288000, 828375040, 468713472, 378011648, 430178304, 524156928, 322240512, 38174720, 337199104, 417095680, 638824448, 917379072, 768384000, 623624704, 576898816, 778483072, 797505344, 1059399328, 939461552, 538234248, 878172996, 614530210, 609308855 - ], - [ - 536870912, 805306368, 402653184, 738197504, 503316480, 16777216, 998244352, 247463936, 941621248, 277872640, 819462144, 1029439488, 841613312, 1037631488, 685604864, 636141568, 309878784, 680357888, 739428352, 70630400, 616498688, 347474176, 240302208, 206913728, 323879904, 824089040, 266798600, 388630796, 475576454, 219955403 - ], - [ - 536870912, 268435456, 671088640, 603979776, 100663296, 956301312, 864026624, 356515840, 195035136, 426770432, 159907840, 284426240, 932839424, 103350272, 528777216, 789790720, 22814720, 996061184, 463177728, 875117568, 142957056, 26473728, 563955584, 482319936, 986369696, 831578448, 442071560, 1066222852, 430362506, 367436361 - ], - [ - 536870912, 268435456, 134217728, 67108864, 301989888, 989855744, 1015021568, 272629760, 350224384, 831520768, 953679872, 705429504, 126746624, 777584640, 491552768, 837697536, 579411968, 619974656, 1035180032, 637453312, 361861632, 987348736, 420219008, 1058010304, 739884896, 850201840, 1023382024, 168869636, 437815426, 195933377 - ], - [ - 536870912, 805306368, 939524096, 335544320, 234881024, 956301312, 746586112, 750780416, 408944640, 368050176, 584581120, 523501568, 1015939072, 780861440, 381452288, 871514112, 60317696, 588599296, 736000000, 750980096, 471921152, 659565824, 977823872, 513544000, 446862432, 13639248, 285738216, 498949404, 879886982, 416824905 - ], - [ - 536870912, 268435456, 134217728, 335544320, 100663296, 318767104, 864026624, 398458880, 794820608, 619708416, 714604544, 859045888, 980549632, 281608192, 289177600, 1018052608, 819437568, 567521280, 819550208, 345373696, 409103872, 140538624, 24155008, 643346112, 1003839648, 256049424, 103814664, 897089284, 998507906, 1011519941 - ], - [ - 536870912, 268435456, 134217728, 67108864, 704643072, 989855744, 629145600, 1061158912, 643825664, 179306496, 851968000, 710672384, 1007026176, 439418880, 688422912, 637288448, 236331008, 292048896, 642603008, 778005504, 267704832, 308994816, 104779136, 71637568, 908277984, 849505072, 191059976, 1002597380, 106060290, 155951873 - ], - [ - 536870912, 805306368, 134217728, 201326592, 369098752, 1023410176, 109051904, 926941184, 119537664, 321912832, 530055168, 131334144, 568983552, 66387968, 895188992, 866992128, 871358464, 383250432, 921896960, 979387392, 118616576, 858299648, 864820096, 1029679552, 227524896, 197575824, 786168712, 845961676, 193906978, 247955603 - ], - [ - 536870912, 268435456, 939524096, 738197504, 167772160, 1056964608, 696254464, 901775360, 10485760, 821035008, 38273024, 446955520, 843186176, 234160128, 360349696, 316194816, 775806976, 1042255872, 1044092928, 171482112, 900535808, 352839936, 178657664, 64372544, 207595168, 978993744, 854090120, 39138116, 604711086, 827340635 - ], - [ - 536870912, 805306368, 671088640, 335544320, 301989888, 486539264, 176160768, 834666496, 933232640, 921698304, 129499136, 296484864, 1056833536, 280297472, 220430336, 724713472, 706355200, 442454016, 130385920, 383427584, 1065293312, 1022734592, 549639552, 388125376, 305393120, 446428848, 580903816, 686076876, 216707178, 98959477 - ], - [ - 536870912, 268435456, 134217728, 738197504, 503316480, 50331648, 780140544, 859832320, 736100352, 554696704, 539492352, 1038876672, 719192064, 469434368, 559513600, 370458624, 993730560, 75010048, 153380864, 245574656, 223120896, 472823040, 214110080, 329096640, 833045536, 979361424, 1002169768, 741893716, 675661322, 787613967 - ], - [ - 536870912, 268435456, 939524096, 335544320, 234881024, 218103808, 377487360, 88080384, 845152256, 223346688, 936902656, 923533312, 114163712, 786366464, 996638720, 960118784, 472702976, 201297920, 995522560, 976456704, 406373888, 412910848, 850818944, 883152192, 549507872, 77720656, 15805224, 396894292, 1021644070, 281752913 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 503316480, 1023410176, 494927872, 390070272, 1029701632, 319815680, 1010302976, 144441344, 232390656, 327221248, 843153408, 887177216, 642899968, 576253952, 990767104, 992144384, 826128896, 300575488, 138991744, 548766144, 335541472, 50816720, 951713800, 210829324, 947486730, 1031618575 - ], - [ - 536870912, 268435456, 939524096, 67108864, 704643072, 385875968, 562036736, 448790528, 866123776, 265289728, 699924480, 988020736, 523632640, 332595200, 635797504, 313999360, 521330688, 793047040, 31893504, 451630080, 490809856, 945939200, 485603200, 606705984, 649869792, 904100112, 577605224, 64675924, 122271622, 500013381 - ], - [ - 536870912, 268435456, 671088640, 469762048, 503316480, 1056964608, 947912704, 985661440, 1012924416, 357564416, 952631296, 69468160, 280625152, 834469888, 139886592, 253902848, 340877312, 793325568, 778328064, 169595904, 109960704, 449797888, 189724800, 974033728, 841963680, 48115984, 900169352, 433723460, 829193770, 1004535127 - ], - [ - 536870912, 805306368, 671088640, 335544320, 771751936, 117440512, 931135488, 801112064, 975175680, 869269504, 1004011520, 1059323904, 1049755648, 250413056, 189759488, 420102144, 304619520, 120434688, 309319680, 458976256, 355513856, 464033024, 938261632, 600744384, 1028390560, 1036562640, 668750472, 719788236, 132633642, 23540757 - ], - [ - 536870912, 805306368, 402653184, 738197504, 100663296, 352321536, 444596224, 994050048, 618659840, 147849216, 533200896, 584843264, 174718976, 686227456, 151289856, 912211968, 622895104, 661704704, 737695744, 432348160, 830422528, 357651712, 822621568, 754819776, 1050390432, 1021195056, 912376360, 932285948, 153736078, 353217479 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 704643072, 486539264, 411041792, 549453824, 102760448, 506462208, 309854208, 412876800, 545652736, 467206144, 871137280, 882884608, 127197184, 855887872, 647112704, 110797824, 77469184, 798324992, 922994048, 814943680, 832301536, 18862000, 399832584, 300132612, 679701902, 1037265359 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 503316480, 654311424, 629145600, 759169024, 513802240, 638582784, 390594560, 434896896, 862846976, 787546112, 75005952, 720650240, 988536832, 287567872, 923711488, 436268032, 486558208, 679585024, 230758528, 794844736, 393326944, 658057328, 458610696, 91970564, 892015106, 390314255 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 704643072, 16777216, 746586112, 801112064, 195035136, 66060288, 680001536, 312213504, 11665408, 865140736, 114917376, 451166208, 724033536, 150884352, 278562816, 192783360, 866344448, 143240448, 580724608, 145963072, 261121760, 752390800, 467986440, 128431116, 658388482, 456808719 - ], - [ - 536870912, 268435456, 939524096, 335544320, 704643072, 956301312, 427819008, 331350016, 52428800, 420478976, 279445504, 171704320, 516292608, 806682624, 934969344, 531808256, 442441728, 143724544, 1063790592, 253557760, 14067200, 708660480, 247976576, 135532096, 599408224, 900936432, 593458312, 286278468, 749300974, 205323445 - ], - [ - 536870912, 268435456, 402653184, 469762048, 771751936, 16777216, 75497472, 683671552, 65011712, 483393536, 870842368, 18087936, 562954240, 535363584, 655654912, 613335040, 694804480, 550891520, 586074112, 435799040, 941405696, 1019926272, 391062144, 352856384, 994336672, 229109488, 77379080, 403363588, 581902982, 349710663 - ], - [ - 536870912, 805306368, 134217728, 603979776, 167772160, 83886080, 813694976, 188743680, 375390208, 475004928, 656932864, 202113024, 6422528, 592117760, 356941824, 405061632, 804184064, 1005072384, 816633856, 865319936, 605279744, 248757504, 561177472, 16977088, 379212192, 799961392, 571049896, 440257596, 488334378, 594460917 - ], - [ - 536870912, 268435456, 939524096, 67108864, 637534208, 218103808, 696254464, 205520896, 954204160, 1043333120, 728236032, 324796416, 413794304, 60358656, 1007976448, 921157632, 868950016, 250130432, 354232320, 927640576, 992506368, 431759104, 899356032, 141645120, 747147232, 401431504, 520346120, 736391940, 590268302, 826751553 - ], - [ - 536870912, 268435456, 402653184, 469762048, 905969664, 1023410176, 713031680, 88080384, 6291456, 110100480, 120061952, 711196672, 33685504, 156565504, 496664576, 761905152, 126115840, 944992256, 14419968, 684614656, 384958976, 267138816, 156757632, 198111808, 359850912, 304946000, 460785288, 750724676, 101321126, 281147479 - ], - [ - 536870912, 268435456, 671088640, 201326592, 973078528, 855638016, 545259520, 784334848, 375390208, 263192576, 558366720, 419168256, 187301888, 729088000, 129400832, 955138048, 453763072, 6623232, 758003712, 837481472, 857005568, 621166336, 1009235840, 79166272, 544208736, 298557840, 537258376, 731874372, 52666602, 631851731 - ], - [ - 536870912, 805306368, 134217728, 738197504, 637534208, 922746880, 125829120, 322961408, 1067450368, 959447040, 474480640, 163315712, 982646784, 626720768, 94797824, 429178880, 427728896, 844173312, 966289408, 459600896, 978746880, 742222592, 617780864, 75213504, 861281312, 146634288, 840065576, 362487100, 591819946, 235173879 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 637534208, 50331648, 260046848, 62914560, 249561088, 883949568, 1066926080, 833880064, 257556480, 1032650752, 33456128, 375341056, 994992128, 113700864, 729430016, 895314944, 831919616, 13861632, 422612864, 1029177792, 567641376, 782952080, 632584584, 89862852, 277729954, 830421855 - ], - [ - 536870912, 805306368, 134217728, 603979776, 503316480, 1056964608, 1015021568, 1010827264, 673185792, 441450496, 893911040, 120324096, 931004416, 869597184, 1034649600, 301940736, 513122304, 504049664, 795842560, 566014976, 341256704, 193543424, 474776704, 831406400, 76388064, 972010800, 83629704, 334936140, 723091554, 476384633 - ], - [ - 536870912, 268435456, 134217728, 603979776, 33554432, 1056964608, 830472192, 104857600, 383778816, 477102080, 696778752, 821297152, 604897280, 321323008, 541294592, 892715008, 330293248, 70676480, 905660416, 128558080, 363177472, 760641792, 650882688, 1010891968, 367046240, 66159248, 919169128, 714361748, 817786602, 462381917 - ], - [ - 536870912, 805306368, 134217728, 603979776, 436207616, 117440512, 813694976, 943718400, 639631360, 776994816, 943194112, 330039296, 109707264, 105185280, 132087808, 637747200, 31563776, 347148288, 436819968, 14971904, 701442560, 337349888, 35501184, 922940096, 945864416, 158398224, 401196680, 441715660, 650616930, 125815001 - ], - [ - 536870912, 805306368, 402653184, 603979776, 905969664, 889192448, 528482304, 910163968, 652214272, 508559360, 79167488, 648806400, 895090688, 219348992, 615940096, 522731520, 146038784, 340152320, 438319104, 561079296, 306718208, 1051023616, 1059047296, 794642496, 634560032, 899074160, 416833576, 960292220, 490985902, 17809461 - ], - [ - 536870912, 268435456, 671088640, 201326592, 33554432, 50331648, 696254464, 390070272, 543162368, 1039138816, 1023934464, 900464640, 174981120, 343474176, 258244608, 107167744, 860315648, 767922176, 917755904, 887057408, 1058097664, 574147328, 361077632, 760376896, 896474208, 133721072, 1059361288, 25339652, 418795914, 439149891 - ], - [ - 536870912, 268435456, 402653184, 872415232, 1040187392, 553648128, 1031798784, 876609536, 551550976, 544210944, 164102144, 732692480, 572653568, 332070912, 959938560, 168640512, 825483264, 926126080, 842192896, 699552768, 150185472, 731011328, 514047616, 168541888, 899040928, 1050497840, 646676648, 878107188, 104629806, 739959033 - ], - [ - 536870912, 268435456, 134217728, 738197504, 973078528, 452984832, 192937984, 20971520, 811597824, 873463808, 607649792, 848560128, 357433344, 686751744, 73367552, 441958400, 353017856, 45707264, 156542976, 1022260224, 174013952, 525819136, 327904640, 695858240, 687140064, 845026448, 727174376, 227255444, 611861738, 41181343 - ], - [ - 536870912, 805306368, 939524096, 872415232, 33554432, 318767104, 813694976, 213909504, 488636416, 384827392, 145227776, 356777984, 101580800, 144637952, 413564928, 1021001728, 86564864, 1007022080, 242149376, 403680256, 631237120, 891736832, 630938752, 893947328, 412473824, 827786384, 49500648, 900536476, 816460774, 776066961 - ], - [ - 536870912, 805306368, 939524096, 738197504, 973078528, 117440512, 931135488, 583008256, 488636416, 999292928, 847773696, 854327296, 387055616, 990838784, 577011712, 1056849920, 429760512, 279654400, 205203456, 959603712, 287193600, 925755136, 229800320, 442439360, 567107104, 226750832, 990326696, 784921532, 462177158, 568521159 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 704643072, 587202560, 981467136, 507510784, 723517440, 571473920, 537395200, 255590400, 98959360, 234553344, 135036928, 50216960, 693051392, 957755392, 788727808, 415788032, 543020544, 400016128, 157496704, 326762176, 286368, 969087312, 44583720, 32298908, 344923526, 502768323 - ], - [ - 536870912, 268435456, 402653184, 201326592, 838860800, 922746880, 729808896, 457179136, 903872512, 514850816, 484966400, 820248576, 133562368, 69140480, 461078528, 567099392, 422715392, 846737408, 144492544, 611038208, 569728512, 449788160, 392427648, 1017184704, 206610400, 836364496, 994951656, 821219796, 710424942, 671928343 - ], - [ - 536870912, 805306368, 402653184, 67108864, 436207616, 452984832, 142606336, 213909504, 492830720, 907018240, 289931264, 138674176, 178126848, 122224640, 625311744, 522108928, 101261312, 1030049792, 724441088, 946955264, 64566784, 332198656, 448517248, 843529280, 738521376, 725540976, 876164616, 102560524, 471061638, 533937217 - ], - [ - 536870912, 805306368, 402653184, 469762048, 905969664, 754974720, 595591168, 683671552, 509607936, 309329920, 640155648, 954990592, 249167872, 1047461888, 678461440, 355024896, 845946880, 798707712, 332388352, 719385600, 707860992, 436835584, 364720256, 388201152, 574325280, 559901616, 234385576, 508915836, 372234254, 1011938315 - ], - [ - 536870912, 805306368, 402653184, 335544320, 100663296, 117440512, 830472192, 851443712, 480247808, 386924544, 997720064, 299630592, 1064173568, 571408384, 775847936, 798375936, 1007869952, 829476864, 214558720, 934667264, 13283840, 1010693888, 924843904, 1011244096, 80395936, 305955792, 1008656040, 533074908, 923522734, 941369305 - ], - [ - 536870912, 805306368, 134217728, 67108864, 301989888, 788529152, 360710144, 784334848, 748683264, 508559360, 395837440, 594804736, 855244800, 297336832, 1046839296, 721567744, 373104640, 945229824, 886454272, 43387904, 846669312, 1070005504, 644755072, 259179200, 45472416, 1004189520, 690488840, 22867212, 69703298, 476024513 - ], - [ - 536870912, 805306368, 402653184, 335544320, 436207616, 184549376, 1031798784, 4194304, 10485760, 412090368, 619184128, 436469760, 566099968, 718077952, 837517312, 284934144, 106045440, 469143552, 291026944, 238869504, 334686720, 132563200, 259072640, 660198464, 993894304, 661821744, 623372424, 672171340, 875136294, 979718517 - ], - [ - 536870912, 805306368, 939524096, 872415232, 100663296, 721420288, 125829120, 507510784, 249561088, 909115392, 552075264, 271319040, 779485184, 834469888, 869236736, 1007206400, 991698944, 438300672, 206698496, 186223616, 509897216, 428600064, 143815552, 133605440, 956058848, 816801520, 225979272, 1066669132, 247725806, 368046589 - ], - [ - 536870912, 805306368, 134217728, 335544320, 1040187392, 150994944, 662700032, 549453824, 207618048, 321912832, 696778752, 1057226752, 739901440, 654901248, 138772480, 146423808, 744071168, 217870336, 389416960, 415669248, 657356288, 874179328, 185189760, 709155392, 733659936, 1020845392, 45905416, 471329548, 659965314, 301439557 - ], - [ - 536870912, 268435456, 134217728, 335544320, 838860800, 754974720, 411041792, 180355072, 601882624, 389021696, 876085248, 311689216, 716046336, 488701952, 382763008, 101203968, 707567616, 16486400, 963536896, 71386112, 773887488, 491912960, 390695296, 277699008, 963328160, 113690480, 75243528, 473157636, 950192130, 126538757 - ], - [ - 536870912, 805306368, 671088640, 738197504, 704643072, 83886080, 947912704, 104857600, 408944640, 653262848, 92798976, 395051008, 420347904, 1055457280, 385712128, 256327680, 600072192, 488820736, 263612416, 961291264, 523215360, 75090688, 864371584, 843195968, 281539424, 67492336, 964936200, 510073612, 282405770, 681247307 - ], - [ - 536870912, 268435456, 939524096, 201326592, 973078528, 989855744, 192937984, 20971520, 668991488, 382730240, 29884416, 384565248, 789446656, 670629888, 544505856, 980140032, 1048272896, 85086208, 550475776, 802716672, 780466688, 223516416, 330269312, 1036636224, 82658912, 537855984, 444072456, 540326660, 755687566, 577387331 - ], - [ - 536870912, 268435456, 134217728, 738197504, 637534208, 218103808, 981467136, 633339904, 299892736, 296747008, 565706752, 23855104, 825622528, 590020608, 600145920, 175292416, 462954496, 809291776, 364845056, 121625600, 519981568, 555616512, 296711808, 748109376, 87716256, 527246160, 137862952, 464191764, 17138826, 169081679 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 771751936, 83886080, 58720256, 532676608, 568328192, 663748608, 58195968, 211025920, 154533888, 8978432, 113016832, 783990784, 712695808, 85651456, 449538048, 898808832, 343354880, 1059649280, 739104896, 288522688, 809906592, 954220592, 437298696, 28949252, 318054022, 526781135 - ], - [ - 536870912, 805306368, 134217728, 201326592, 234881024, 83886080, 494927872, 155189248, 970981376, 152043520, 887619584, 906231808, 506331136, 20119552, 895516672, 668057600, 189276160, 477368320, 1008097280, 738182144, 964306432, 898974976, 218507136, 454475712, 226406240, 549139792, 347395816, 985078684, 437133322, 453185551 - ], - [ - 536870912, 805306368, 939524096, 469762048, 301989888, 754974720, 679477248, 524288000, 966787072, 584056832, 573046784, 882114560, 934936576, 104136704, 384532480, 148684800, 253714432, 752242688, 716376064, 3183616, 123286016, 862796032, 948368512, 551247936, 746906656, 737320848, 244421768, 67711052, 679865390, 368249751 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 905969664, 83886080, 813694976, 817889280, 866123776, 217055232, 311951360, 125566976, 843972608, 897122304, 183271424, 143048704, 334290944, 503787520, 1043195904, 556196864, 874378752, 85906688, 252810112, 352869056, 246764256, 559660016, 567514632, 1059464452, 85728134, 664751823 - ], - [ - 536870912, 268435456, 402653184, 469762048, 234881024, 318767104, 478150656, 281018368, 1063256064, 47185920, 678952960, 485752832, 299237376, 102432768, 639205376, 396640256, 586031104, 1003458560, 129984512, 200752128, 1055638016, 647015680, 333030784, 725973312, 981454432, 857085968, 880421352, 860392532, 798876174, 532364547 - ], - [ - 536870912, 805306368, 671088640, 335544320, 704643072, 788529152, 327155712, 281018368, 77594624, 831520768, 232259584, 691273728, 46268416, 1003290624, 782729216, 846610432, 919478272, 709529600, 696260608, 667003904, 723602944, 525349120, 209305216, 606415296, 207288864, 110647120, 424988808, 905087180, 1015340202, 868913813 - ], - [ - 536870912, 805306368, 402653184, 469762048, 234881024, 654311424, 662700032, 356515840, 937426944, 563085312, 34078720, 588513280, 786825216, 894763008, 478642176, 814071808, 904880128, 247574528, 480270336, 695307264, 404320768, 979170048, 487759488, 497259328, 1050295840, 955684976, 169680520, 208819020, 770924070, 733096055 - ], - [ - 536870912, 805306368, 402653184, 603979776, 301989888, 285212672, 343932928, 373293056, 996147200, 804257792, 835190784, 394002432, 353239040, 672989184, 419397632, 282443776, 1057136640, 26955776, 1031743488, 571765760, 170023424, 822808320, 826701184, 362850624, 483474016, 442080048, 985978248, 846985548, 47059558, 868085561 - ], - [ - 536870912, 805306368, 134217728, 872415232, 301989888, 184549376, 427819008, 750780416, 392167424, 628097024, 865599488, 567017472, 237895680, 278462464, 1011712000, 955138048, 955817984, 314380288, 750131200, 399797248, 354579968, 416785152, 790939520, 276540096, 293277024, 268052208, 347764232, 35365644, 814401410, 404925133 - ], - [ - 536870912, 268435456, 939524096, 872415232, 838860800, 855638016, 109051904, 222298112, 354418688, 391118848, 571998208, 168034304, 846331904, 883228672, 199393280, 828162048, 257368064, 445075456, 803190784, 268166144, 710414848, 816180480, 300071040, 240985536, 265698464, 382151760, 260020360, 325809604, 270599342, 953223261 - ], - [ - 536870912, 805306368, 671088640, 335544320, 369098752, 956301312, 545259520, 583008256, 631242752, 919601152, 650641408, 955514880, 1010171904, 512557056, 905674752, 378945536, 31203328, 963801088, 1023617024, 949720064, 250064384, 910459136, 135230592, 136353088, 311427104, 816401264, 520376968, 418361420, 470930090, 661240629 - ], - [ - 536870912, 268435456, 134217728, 1006632960, 637534208, 50331648, 25165824, 29360128, 681574400, 116391936, 215482368, 691273728, 923402240, 449380352, 779911168, 783695872, 400482304, 47362048, 125687808, 305605632, 547331584, 808586496, 233624448, 843013312, 63151776, 196447440, 659170824, 1000919300, 1009579394, 43945423 - ], - [ - 536870912, 268435456, 134217728, 335544320, 167772160, 16777216, 562036736, 977272832, 1029701632, 934281216, 196608000, 251396096, 278265856, 984285184, 396197888, 891731968, 739500032, 652308480, 351311872, 190440448, 487337472, 760111360, 593908352, 393395776, 106025760, 566805968, 358875560, 708557716, 116765322, 265539137 - ], - [ - 536870912, 268435456, 671088640, 603979776, 570425344, 989855744, 494927872, 255852544, 547356672, 506462208, 647495680, 974389248, 1019871232, 883228672, 697466880, 198197248, 1057595392, 826036224, 302446592, 375061504, 369893888, 35531008, 378530688, 556237248, 707471648, 1018431120, 737874824, 482115012, 625445674, 989556633 - ], - [ - 536870912, 805306368, 671088640, 738197504, 704643072, 956301312, 780140544, 700448768, 782237696, 789577728, 520617984, 659816448, 302120960, 125501440, 462848000, 844742656, 599629824, 539455488, 591460352, 828402688, 984658432, 194522880, 354161536, 188169664, 977849952, 87399664, 1060349032, 195260412, 166354402, 954163511 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 637534208, 50331648, 260046848, 364904448, 81788928, 741343232, 748158976, 644087808, 523894784, 997261312, 87588864, 385138688, 397664256, 870068224, 630102016, 652459008, 766823936, 1267456, 1011702144, 75974848, 948925728, 107141840, 166991880, 775060484, 1025355270, 317630223 - ], - [ - 536870912, 268435456, 134217728, 469762048, 167772160, 50331648, 746586112, 507510784, 517996544, 682622976, 364380160, 697040896, 402522112, 283312128, 699760640, 397590528, 1061003264, 122040320, 351209472, 327818240, 560989696, 1033387264, 530327168, 555201088, 568801952, 868136976, 352465960, 965011028, 172630154, 22056771 - ], - [ - 536870912, 268435456, 402653184, 738197504, 503316480, 654311424, 1031798784, 79691776, 396361728, 168820736, 489160704, 75759616, 1069678592, 706019328, 749371392, 410107904, 639229952, 754724864, 1041127424, 794958848, 226795008, 759369984, 659871360, 231425088, 1019247776, 731915088, 202411656, 371742788, 654598822, 470020699 - ], - [ - 536870912, 268435456, 939524096, 67108864, 905969664, 218103808, 444596224, 88080384, 1042284544, 957349888, 927465472, 537133056, 923926528, 745603072, 695762944, 987611136, 740171776, 700887040, 55306240, 742167552, 602884608, 25075968, 871870592, 798160448, 976352800, 1020815248, 772622344, 456647684, 426934798, 633373953 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 1040187392, 788529152, 327155712, 381681664, 262144000, 955252736, 641204224, 4456448, 599392256, 885325824, 855277568, 396673024, 682319872, 200093696, 613816320, 586394624, 309964288, 899961088, 699017600, 258785472, 500661152, 93549840, 170404232, 955105476, 421002158, 590525727 - ], - [ - 536870912, 805306368, 671088640, 469762048, 100663296, 1056964608, 931135488, 801112064, 304087040, 934281216, 404226048, 640942080, 510263296, 230621184, 440696832, 374521856, 289054720, 246829056, 479725568, 544498688, 680219136, 95405824, 590207104, 853444416, 110428768, 949665904, 147258088, 497080124, 477188226, 943203147 - ], - [ - 536870912, 805306368, 939524096, 603979776, 838860800, 620756992, 578813952, 390070272, 987758592, 300941312, 219676672, 513540096, 259129344, 20381696, 293109760, 439107584, 629858304, 148615168, 911357952, 442989568, 150064640, 161062144, 652017792, 370305856, 386304544, 348216944, 220251304, 559015996, 545861126, 657796357 - ], - [ - 536870912, 805306368, 402653184, 872415232, 503316480, 150994944, 897581056, 624951296, 1000341504, 923795456, 890765312, 482607104, 564527104, 295895040, 753172480, 183975936, 848977920, 376557568, 1005189120, 32277504, 464246272, 423186176, 93585792, 564024896, 162994656, 71040656, 316774504, 380758236, 218653070, 559711809 - ], - [ - 536870912, 805306368, 939524096, 335544320, 973078528, 486539264, 696254464, 1010827264, 945815552, 380633088, 348651520, 185860096, 620625920, 259325952, 340754432, 280805376, 98246656, 109252608, 974047232, 702405632, 753658368, 487276288, 133844864, 324161856, 452414240, 281074864, 161574792, 277954892, 857309998, 451739829 - ], - [ - 536870912, 805306368, 671088640, 469762048, 167772160, 553648128, 125829120, 1069547520, 325058560, 286261248, 974651392, 226230272, 724434944, 894107648, 949518336, 993837056, 412065792, 129740800, 13752320, 108655616, 82600448, 511169792, 940985216, 143060032, 241154336, 717453200, 582848680, 542002908, 274358786, 343987467 - ], - [ - 536870912, 268435456, 134217728, 603979776, 301989888, 721420288, 461373440, 557842432, 811597824, 814743552, 576192512, 26476544, 913702912, 792788992, 895516672, 1041252352, 93921280, 842305536, 658987008, 925490176, 924682752, 727433984, 267625600, 1034814144, 882152608, 553029552, 612401160, 817905668, 371269634, 762351625 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 503316480, 184549376, 75497472, 432013312, 329252864, 898629632, 1572864, 692846592, 622198784, 491978752, 416382976, 578371584, 192684032, 849285120, 554149888, 453770240, 125610496, 77525760, 772202880, 1032545344, 196970144, 415133904, 114713896, 938679188, 79702022, 136428555 - ], - [ - 536870912, 805306368, 939524096, 603979776, 905969664, 654311424, 444596224, 348127232, 392167424, 254803968, 786956288, 545521664, 609353728, 639565824, 366510080, 812400640, 1071046656, 181243904, 906430464, 257240064, 248173056, 408120576, 69098112, 1020865216, 703368544, 127343024, 778855912, 886541948, 978180614, 398868741 - ], - [ - 536870912, 268435456, 134217728, 67108864, 637534208, 855638016, 461373440, 440401920, 668991488, 141557760, 902299648, 958660608, 482213888, 345571328, 415006720, 1015169024, 568008704, 13021184, 903108608, 448150528, 219972096, 118699776, 845379456, 992712768, 768477216, 1003565936, 1029274120, 823982852, 1024593282, 727933761 - ], - [ - 536870912, 268435456, 402653184, 469762048, 167772160, 150994944, 58720256, 88080384, 685768704, 403701760, 671612928, 671875072, 796524544, 330235904, 208764928, 634929152, 1059332096, 759607296, 728569856, 640340992, 491255296, 594283776, 573282176, 189196480, 544025632, 682248624, 227005864, 231553140, 408631310, 1033856003 - ], - [ - 536870912, 805306368, 939524096, 469762048, 771751936, 117440512, 729808896, 398458880, 744488960, 653262848, 1572864, 563871744, 873070592, 354877440, 664043520, 1061044224, 50864128, 833884160, 829327360, 671122432, 335614464, 167781632, 889317504, 42006848, 994072352, 270583600, 491894696, 176814716, 125063814, 361711691 - ], - [ - 536870912, 805306368, 134217728, 67108864, 301989888, 654311424, 75497472, 725614592, 736100352, 210763776, 378011648, 899940352, 326238208, 362610688, 1030717440, 993214464, 419209216, 901730304, 114972672, 411571200, 1017459200, 787620608, 190622336, 206477632, 344115872, 113612112, 446881928, 301317708, 836381218, 604580625 - ], - [ - 536870912, 805306368, 134217728, 603979776, 1040187392, 16777216, 226492416, 750780416, 727711744, 745537536, 509083648, 473694208, 776601600, 1012203520, 219119616, 527646720, 35233792, 874262528, 379283456, 865975296, 1029381632, 947683072, 711641472, 511999936, 1036415328, 598097680, 72826760, 466615500, 991135458, 719867865 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 33554432, 218103808, 125829120, 239075328, 656408576, 594542592, 301465600, 375652352, 23986176, 509542400, 495419392, 991084544, 465903616, 1004417024, 247977984, 867312640, 183825920, 252133120, 919854208, 614778688, 210737760, 885959184, 821019240, 857624084, 438703202, 547569947 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 234881024, 620756992, 830472192, 499122176, 966787072, 149946368, 251133952, 999030784, 830341120, 370081792, 406224896, 530235392, 164962304, 58871808, 1011480576, 806663168, 807565824, 733570816, 409802880, 216955712, 707218720, 326269392, 917550376, 832163292, 375148330, 657877715 - ], - [ - 536870912, 268435456, 402653184, 67108864, 301989888, 419430400, 394264576, 155189248, 996147200, 179306496, 232259584, 673447936, 241565696, 173735936, 179929088, 613695488, 280944640, 687845376, 136304640, 99562496, 1012372992, 37904640, 104642176, 31637312, 1034707424, 795535120, 438354280, 1037138260, 157906446, 721277189 - ], - [ - 536870912, 268435456, 939524096, 469762048, 369098752, 486539264, 947912704, 650117120, 903872512, 959447040, 562561024, 1007943680, 511049728, 963575808, 753106944, 215498752, 552443904, 600543232, 777893888, 453188608, 183032320, 384122112, 379461760, 277504704, 771608928, 353534288, 766546792, 961048660, 821424614, 365421459 - ], - [ - 536870912, 268435456, 134217728, 201326592, 905969664, 83886080, 629145600, 566231040, 429916160, 726663168, 689438720, 664535040, 611450880, 364576768, 805273600, 405913600, 795385856, 328568832, 764934144, 841331712, 490637824, 823242496, 142113152, 250425152, 251356832, 287230896, 595596456, 1019334836, 941713194, 814780663 - ], - [ - 536870912, 268435456, 671088640, 67108864, 905969664, 218103808, 142606336, 247463936, 182452224, 634388480, 986185728, 303300608, 380764160, 688979968, 858292224, 507854848, 406462464, 69513216, 254470144, 772539392, 133092864, 838313728, 933947008, 416080448, 554659488, 640120464, 912418824, 257508356, 838661642, 186062593 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 570425344, 1056964608, 192937984, 683671552, 916455424, 416284672, 790102016, 738983936, 82968576, 487260160, 238518272, 74268672, 58957824, 407056384, 258115584, 611578880, 675955200, 693575424, 10255744, 168501056, 834079776, 715921456, 337866280, 370308916, 1010547630, 497020027 - ], - [ - 536870912, 805306368, 134217728, 335544320, 369098752, 1056964608, 897581056, 817889280, 325058560, 588251136, 62390272, 886308864, 406716416, 781778944, 803569664, 943079424, 503685120, 979841024, 538753024, 365071360, 990541312, 66536192, 518308992, 515310528, 289784224, 616970096, 216815112, 254489356, 440818818, 799932357 - ], - [ - 536870912, 268435456, 134217728, 67108864, 570425344, 419430400, 528482304, 373293056, 853540864, 787480576, 1028128768, 67895296, 539361280, 218038272, 202080256, 873054208, 40689664, 370634752, 244774912, 542548992, 746014208, 111556864, 356426368, 548090560, 739801504, 869645584, 911419304, 893210644, 449821482, 509820885 - ], - [ - 536870912, 805306368, 402653184, 469762048, 704643072, 520093696, 947912704, 574619648, 153092096, 814743552, 876085248, 1056702464, 654704640, 215416832, 340688896, 467812352, 758947840, 837218304, 682002432, 520489984, 550977024, 642696960, 417524608, 1069315648, 212228000, 419869840, 232153000, 500103324, 673431982, 199085979 - ], - [ - 536870912, 268435456, 939524096, 872415232, 167772160, 587202560, 176160768, 859832320, 425721856, 439353344, 454557696, 714342400, 1030619136, 82640896, 600473600, 865779712, 271720448, 519966720, 778369024, 618062848, 829010432, 846001920, 109811584, 268068288, 495144992, 354937648, 122684808, 589857476, 512507822, 595290877 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 369098752, 352321536, 562036736, 633339904, 769654784, 946864128, 715653120, 356253696, 881983488, 1049952256, 439320576, 617037824, 31154176, 349728768, 311724032, 875437056, 96982528, 173734656, 840534400, 200554560, 136199008, 659465552, 183918472, 340968268, 183874274, 866098463 - ], - [ - 536870912, 268435456, 402653184, 1006632960, 301989888, 117440512, 964689920, 197132288, 840957952, 735051776, 589824000, 272367616, 586809344, 244908032, 2392064, 10403840, 803659776, 171118592, 274036736, 195456000, 181595648, 1025857792, 169769600, 732336960, 449999584, 623144528, 908064264, 967304452, 500403334, 480540239 - ], - [ - 536870912, 268435456, 939524096, 335544320, 100663296, 218103808, 1065353216, 448790528, 924844032, 611319808, 932708352, 180617216, 675151872, 726859776, 928088064, 1038696448, 475881472, 259690496, 313350144, 430117888, 193587712, 1003310848, 179530368, 637622080, 486581984, 125856208, 247529064, 824255892, 695220230, 135889921 - ], - [ - 536870912, 268435456, 402653184, 872415232, 234881024, 50331648, 662700032, 624951296, 35651584, 470810624, 491257856, 805568512, 68812800, 406126592, 574783488, 83476480, 69017600, 863416320, 70957056, 757386240, 227242496, 20794624, 249993856, 322130752, 41968800, 1036053648, 585171592, 40972100, 704229030, 815623581 - ], - [ - 536870912, 805306368, 402653184, 603979776, 503316480, 654311424, 159383552, 88080384, 446693376, 242221056, 977797120, 448528384, 503185408, 365756416, 490176512, 95535104, 472424448, 321662976, 392566784, 625589248, 121410048, 515791104, 208435584, 80115520, 498622048, 364237232, 98722184, 574868300, 749915238, 624593081 - ], - [ - 536870912, 268435456, 671088640, 603979776, 436207616, 50331648, 360710144, 314572800, 249561088, 842006528, 50855936, 689176576, 256507904, 176095232, 31817728, 916701184, 593190912, 715550720, 440928256, 1010062336, 219843072, 403048704, 769131136, 791440320, 47676896, 434156144, 95526760, 516516276, 209029762, 918290381 - ], - [ - 536870912, 268435456, 671088640, 872415232, 234881024, 855638016, 1048576000, 406847488, 840957952, 26214400, 136839168, 505675776, 414056448, 221184000, 670007296, 529448960, 624910336, 788992000, 751470592, 1050770432, 13680128, 294235904, 1047847808, 174523072, 200967136, 978935440, 494699496, 1045585556, 985465826, 867409561 - ], - [ - 536870912, 268435456, 671088640, 201326592, 100663296, 754974720, 729808896, 901775360, 635437056, 5242880, 912785408, 142868480, 506855424, 728170496, 42958848, 499826688, 18653184, 715886592, 755857408, 65201152, 213510656, 514610432, 261271424, 828455104, 17905376, 46694992, 343166696, 950953556, 58434786, 430256983 - ], - [ - 536870912, 268435456, 939524096, 872415232, 436207616, 822083584, 176160768, 708837376, 127926272, 30408704, 967311360, 439091200, 869924864, 72810496, 794656768, 337854464, 622026752, 776663040, 895424512, 757087232, 999372288, 101209856, 805085056, 276012480, 796569376, 369621552, 976572584, 233740276, 1001973638, 702894537 - ], - [ - 536870912, 805306368, 402653184, 603979776, 973078528, 822083584, 192937984, 339738624, 442499072, 686817280, 355991552, 791412736, 33161216, 887029760, 353402880, 529088512, 393601024, 581365760, 886921216, 977425408, 640892416, 265015552, 675677312, 451741248, 383401120, 835677360, 580443688, 889040892, 735229966, 494642181 - ], - [ - 536870912, 268435456, 134217728, 469762048, 1040187392, 855638016, 864026624, 272629760, 526385152, 663748608, 665321472, 423362560, 816185344, 553451520, 914784256, 848117760, 75390976, 1035513856, 97908736, 293219328, 92994048, 598939392, 975693440, 37583424, 254191456, 113085296, 115828360, 412957252, 9848674, 140802935 - ], - [ - 536870912, 268435456, 402653184, 738197504, 771751936, 822083584, 377487360, 490733568, 1025507328, 202375168, 544735232, 641990656, 190185472, 332464128, 303595520, 276086784, 750739456, 808218624, 778766336, 792949760, 475924992, 157145344, 866306176, 187590592, 630571040, 22003632, 799377416, 279360516, 291105286, 341141771 - ], - [ - 536870912, 805306368, 671088640, 469762048, 33554432, 50331648, 830472192, 339738624, 576716800, 911212544, 461897728, 518782976, 874905600, 44367872, 803962880, 993148928, 148267008, 836620288, 746469376, 629226496, 977390080, 190961408, 416310400, 1011413312, 734850272, 295063792, 993799816, 149841484, 665413738, 635253175 - ], - [ - 536870912, 268435456, 939524096, 335544320, 704643072, 687865856, 377487360, 415236096, 597688320, 326107136, 454557696, 273416192, 345636864, 625410048, 727023616, 349650944, 165437440, 437481472, 360896512, 873126912, 89088512, 391148288, 36274816, 573963584, 151473056, 87414576, 881324328, 242599540, 661053574, 627412545 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 838860800, 419430400, 847249408, 54525952, 950009856, 386924544, 54001664, 239337472, 1054736384, 785580032, 771784704, 453001216, 327163904, 230715392, 165763072, 917593088, 648646144, 238935808, 138116480, 119382336, 65792992, 994395344, 912187496, 814962332, 706740230, 609222659 - ], - [ - 536870912, 268435456, 671088640, 201326592, 100663296, 1056964608, 92274688, 884998144, 601882624, 999292928, 932708352, 561774592, 499777536, 921894912, 406814720, 27049984, 500932608, 782897152, 354560000, 705111040, 97571328, 490276096, 701336960, 941816640, 579217824, 697349232, 983096232, 972841332, 428564002, 492006967 - ], - [ - 536870912, 268435456, 671088640, 1006632960, 570425344, 687865856, 1015021568, 675282944, 794820608, 856686592, 608698368, 553910272, 421658624, 601161728, 483033088, 199245824, 525426688, 1026052096, 622110720, 183170048, 1058081280, 1044913920, 470129280, 1000585536, 9732256, 640295760, 741454472, 1010306372, 6056618, 728706143 - ], - [ - 536870912, 268435456, 402653184, 67108864, 973078528, 318767104, 226492416, 742391808, 174063616, 206569472, 303562752, 141295616, 312606720, 182517760, 345014272, 850968576, 731652096, 281792512, 94738432, 496430080, 483303936, 625210112, 586216064, 283666624, 142942048, 36085520, 214310920, 576114692, 66000902, 636693505 - ], - [ - 536870912, 268435456, 939524096, 67108864, 234881024, 956301312, 209715200, 1027604480, 421527552, 137363456, 675807232, 683409408, 629538816, 488177664, 224690176, 671334400, 625680384, 460845056, 212961280, 956892160, 60586496, 515330304, 248552832, 756646976, 627426016, 335703728, 793399816, 745956612, 959467406, 147398977 - ], - [ - 536870912, 805306368, 402653184, 738197504, 973078528, 587202560, 696254464, 767557632, 270532608, 711983104, 634912768, 823918592, 317849600, 917700608, 995262464, 419577856, 984293376, 342814720, 344057856, 423732224, 962677248, 185666304, 46741632, 165004864, 942102176, 655723824, 830985896, 950324540, 679376558, 432569655 - ], - [ - 536870912, 268435456, 939524096, 335544320, 973078528, 587202560, 746586112, 700448768, 383778816, 896532480, 300417024, 721682432, 684064768, 893452288, 388005888, 261210112, 177774592, 602787840, 205723648, 415654912, 490786304, 992081664, 563137408, 328859456, 745377824, 151206448, 669417480, 1053868036, 532160526, 461115397 - ], - [ - 536870912, 805306368, 402653184, 67108864, 570425344, 788529152, 897581056, 239075328, 559939584, 57671680, 817364992, 164364288, 612499456, 351207424, 666664960, 1052459008, 1055121408, 673165312, 709109760, 93828096, 441527808, 933802240, 1015288960, 3610688, 461442720, 792785136, 98597416, 833624252, 655899790, 1058843725 - ], - [ - 536870912, 805306368, 671088640, 872415232, 905969664, 486539264, 109051904, 750780416, 891289600, 894435328, 698875904, 696516608, 230817792, 932118528, 368607232, 11321344, 1032249344, 1038946304, 233232384, 350002176, 662663680, 146882304, 455134080, 877667264, 757608288, 776277808, 593753832, 681493500, 632400386, 693740289 - ], - [ - 536870912, 805306368, 402653184, 738197504, 637534208, 117440512, 310378496, 289406976, 652214272, 686817280, 970457088, 408682496, 648937472, 32571392, 676954112, 161267712, 470769664, 1012936704, 1035057152, 221795328, 1034807808, 754321152, 493649792, 735500992, 389908704, 60744304, 1015658504, 647255052, 240904710, 253429515 - ], - [ - 536870912, 268435456, 671088640, 603979776, 905969664, 318767104, 125829120, 574619648, 786432000, 781189120, 498597888, 129761280, 557711360, 821231616, 568688640, 613662720, 632643584, 134877184, 20539392, 377291776, 866115072, 126016768, 592187264, 265802560, 710343456, 353780368, 595000488, 975603156, 238989698, 494083661 - ], - [ - 536870912, 268435456, 939524096, 335544320, 167772160, 218103808, 931135488, 398458880, 291504128, 256901120, 617086976, 203685888, 363462656, 234160128, 186810368, 846249984, 590880768, 165515264, 479643648, 452127744, 351884800, 146568960, 734504064, 708468032, 316515232, 269950736, 296971400, 920236356, 835483054, 1014933525 - ], - [ - 536870912, 268435456, 402653184, 469762048, 704643072, 855638016, 394264576, 826277888, 610271232, 774897664, 536346624, 952893440, 657850368, 416874496, 228360192, 863944704, 565043200, 193449984, 551573504, 418438144, 316152320, 781998848, 1023319424, 216919488, 99015008, 1037042224, 277445128, 458574596, 768288134, 169271751 - ], - [ - 536870912, 805306368, 402653184, 738197504, 234881024, 822083584, 343932928, 155189248, 241172480, 101711872, 42467328, 364118016, 996802560, 936181760, 84377600, 284934144, 746971136, 764620800, 820062208, 877671424, 325677568, 493108992, 356691584, 113812800, 693488160, 825980304, 228922504, 551722572, 49856166, 355212251 - ], - [ - 536870912, 805306368, 134217728, 335544320, 838860800, 687865856, 780140544, 4194304, 979369984, 818937856, 782761984, 569638912, 114950144, 255000576, 86409216, 250396672, 114778112, 880046080, 823916544, 328395776, 467017216, 418772224, 274366336, 326247616, 424085088, 624751408, 805279848, 994166332, 232818666, 370184953 - ], - [ - 536870912, 805306368, 402653184, 469762048, 100663296, 285212672, 578813952, 650117120, 299892736, 324009984, 734527488, 570163200, 995753984, 811794432, 1059487744, 913850368, 518365184, 925765632, 384129024, 53357568, 350579200, 137350400, 560255872, 493790144, 885272352, 958354800, 498941224, 544990332, 752024750, 180287163 - ], - [ - 536870912, 268435456, 671088640, 335544320, 33554432, 486539264, 377487360, 775946240, 849346560, 196083712, 372768768, 225705984, 546963456, 141623296, 995655680, 765804544, 561160192, 460132352, 840853504, 762508288, 896291328, 287196416, 821187968, 313341376, 108929440, 824323536, 331671560, 606254084, 21262858, 543364357 - ], - [ - 536870912, 268435456, 134217728, 201326592, 301989888, 218103808, 1065353216, 801112064, 44040192, 674234368, 287834112, 1000603648, 452329472, 145948672, 731217920, 534691840, 622272512, 576942080, 938293248, 331559936, 794636800, 397112064, 169414784, 437109440, 873665376, 212084752, 880190440, 49502932, 133441674, 416216775 - ], - [ - 536870912, 805306368, 671088640, 335544320, 503316480, 385875968, 511705088, 549453824, 916455424, 72351744, 488112128, 96731136, 996540416, 996999168, 587956224, 686178304, 338436096, 15347712, 777410560, 302261248, 591891968, 939333888, 481427584, 930239424, 626251168, 549704560, 385513096, 925769420, 271688490, 48876981 - ], - [ - 536870912, 805306368, 402653184, 67108864, 570425344, 83886080, 578813952, 1052770304, 819986432, 428867584, 483917824, 630980608, 756416512, 338231296, 731217920, 636665856, 764616704, 1002672128, 259680256, 213349376, 219710976, 519954176, 382075008, 634395840, 586740192, 351021360, 744476168, 258751244, 639594118, 1045264321 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 167772160, 352321536, 226492416, 390070272, 648019968, 747634688, 586678272, 400818176, 352714752, 1015611392, 497909760, 189415424, 485679104, 884396032, 44066816, 579881984, 167332352, 962866432, 281538688, 367552960, 224189472, 885130160, 601768456, 943517964, 506606210, 22534351 - ], - [ - 536870912, 268435456, 134217728, 335544320, 771751936, 419430400, 159383552, 809500672, 589299712, 791674880, 543686656, 237764608, 727842816, 374669312, 337018880, 41107456, 982327296, 890482688, 10299392, 1061886976, 492403200, 491109632, 332367744, 167178304, 916631008, 859155408, 486995336, 1051451716, 327776354, 603847317 - ], - [ - 536870912, 805306368, 671088640, 603979776, 704643072, 553648128, 595591168, 834666496, 119537664, 288358400, 306708480, 172752896, 33947648, 893976576, 919437312, 860307456, 623386624, 412930048, 668878848, 146619392, 577723904, 263549184, 306394496, 48368704, 269665120, 679155120, 512187912, 873033996, 246232458, 957811785 - ], - [ - 536870912, 805306368, 134217728, 872415232, 704643072, 989855744, 780140544, 96468992, 677380096, 972029952, 73924608, 985923584, 829554688, 1063321600, 829521920, 749223936, 421896192, 851660800, 53008384, 828699648, 232943104, 158982912, 899489664, 524270400, 770048544, 753563024, 835559432, 851922956, 381343746, 1026946061 - ], - [ - 536870912, 805306368, 939524096, 201326592, 301989888, 620756992, 276824064, 448790528, 740294656, 749731840, 730333184, 532414464, 708968448, 928448512, 244875264, 449069056, 479698944, 473559040, 599013376, 582904832, 930427392, 832481024, 440790144, 240606656, 68757408, 285476592, 1043749160, 491260988, 295479814, 468859663 - ], - [ - 536870912, 268435456, 671088640, 603979776, 771751936, 318767104, 696254464, 641728512, 983564288, 829423616, 358088704, 749993984, 244973568, 223412224, 434667520, 336412672, 427761664, 354578432, 188028928, 735742976, 913330688, 718865664, 368386944, 398089920, 660695968, 210799568, 101201928, 509475844, 1058523658, 946850057 - ], - [ - 536870912, 805306368, 671088640, 872415232, 838860800, 721420288, 243269632, 457179136, 236978176, 179306496, 520617984, 181665792, 530448384, 639827968, 578322432, 868007936, 56287232, 826617856, 111626240, 733965312, 60001792, 703658752, 1026038912, 778414528, 764878048, 997680976, 52883048, 243254684, 1056065026, 425744129 - ], - [ - 536870912, 268435456, 939524096, 603979776, 436207616, 452984832, 998244352, 616562688, 501219328, 982515712, 39321600, 357826560, 280625152, 104529920, 343638016, 198852608, 384524288, 763604992, 431974400, 641250304, 604279296, 377683200, 843049344, 989354816, 501539296, 907222064, 728162792, 338435124, 698311142, 768171069 - ], - [ - 536870912, 268435456, 134217728, 201326592, 301989888, 486539264, 931135488, 507510784, 589299712, 1064304640, 1067974656, 149684224, 306053120, 392888320, 910262272, 1059110912, 628105216, 782823424, 762083328, 293557248, 63589888, 393243392, 598221440, 317466304, 54479392, 854306448, 889257640, 729843540, 71401482, 841007111 - ], - [ - 536870912, 268435456, 134217728, 335544320, 369098752, 1056964608, 713031680, 801112064, 610271232, 982515712, 354942976, 638844928, 720764928, 830275584, 566394880, 549142528, 644292608, 190148608, 626497536, 831259648, 628758016, 788954880, 977610368, 507498560, 548970784, 29150576, 1059303560, 1038872388, 53356450, 30420277 - ], - [ - 536870912, 805306368, 939524096, 201326592, 234881024, 419430400, 427819008, 432013312, 316669952, 946864128, 690487296, 698613760, 448921600, 902234112, 777289728, 925515776, 755146752, 237408256, 933623808, 197272576, 407294464, 898892032, 852189312, 368238784, 659423584, 354548144, 999375336, 1020840316, 458004614, 914867407 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 1040187392, 117440512, 327155712, 994050048, 543162368, 856686592, 117964800, 764674048, 265420800, 619511808, 954171392, 610484224, 869621760, 892481536, 809277440, 192351232, 533156352, 796837632, 466873984, 384694592, 165591840, 216230992, 622150792, 689046092, 818716578, 70147615 - ], - [ - 536870912, 268435456, 671088640, 872415232, 838860800, 989855744, 897581056, 725614592, 866123776, 852492288, 343408640, 176422912, 198574080, 559611904, 505511936, 361873408, 165208064, 89403392, 590235648, 236942336, 949450240, 519702272, 49376128, 1021887808, 1071407072, 725765776, 789899880, 974112980, 940498946, 990851081 - ], - [ - 536870912, 805306368, 134217728, 335544320, 973078528, 855638016, 729808896, 46137344, 106954752, 456130560, 792199168, 835977216, 325713920, 58654720, 99909632, 58441728, 30924800, 558493696, 72189952, 1055794176, 681392640, 187165952, 328298112, 610912832, 282935904, 990300016, 25210088, 163630396, 836767370, 938539593 - ], - [ - 536870912, 805306368, 671088640, 67108864, 234881024, 318767104, 142606336, 918552576, 329252864, 110100480, 20447232, 293863424, 676462592, 192086016, 656572416, 398180352, 430956544, 625315840, 317851648, 811781120, 257669632, 635324160, 17572736, 851427904, 356323936, 211182320, 583070312, 94434044, 965769826, 62521085 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 503316480, 117440512, 914358272, 960495616, 350224384, 533725184, 718798848, 126615552, 108134400, 834994176, 180781056, 946520064, 594042880, 29732864, 583407616, 1013687296, 23626240, 415525632, 323395712, 866790336, 751381984, 334845904, 642693768, 520037572, 758607726, 608347935 - ], - [ - 536870912, 268435456, 134217728, 335544320, 704643072, 285212672, 260046848, 130023424, 480247808, 416284672, 614989824, 185335808, 987365376, 787808256, 767459328, 1057177600, 738271232, 637636608, 654338048, 545360896, 859956736, 98570496, 204506240, 656014912, 735345632, 229520656, 998967944, 849175364, 110336354, 273193557 - ], - [ - 536870912, 268435456, 671088640, 469762048, 503316480, 218103808, 931135488, 364904448, 199229440, 135266304, 750256128, 588513280, 198836224, 461701120, 438468608, 707805184, 558391296, 582856704, 804685824, 948587520, 211633664, 335946496, 673336960, 19966656, 801636384, 50155280, 584500872, 33285828, 175490602, 92941335 - ], - [ - 536870912, 805306368, 671088640, 67108864, 234881024, 50331648, 461373440, 440401920, 44040192, 1066401792, 43515904, 158597120, 332267520, 714932224, 303267840, 816726016, 1038917632, 96120832, 13793280, 734923776, 916290048, 806498560, 967828096, 728505280, 125556256, 62062640, 213893256, 154457804, 74421930, 562927345 - ], - [ - 536870912, 268435456, 671088640, 738197504, 301989888, 822083584, 830472192, 432013312, 316669952, 810549248, 180879360, 781451264, 208535552, 1006567424, 282558464, 647151616, 611688448, 675164160, 657864704, 826438656, 947689984, 113966336, 38397824, 987067840, 1028645728, 72247568, 164518760, 705617172, 636445026, 910037023 - ], - [ - 536870912, 268435456, 134217728, 872415232, 301989888, 553648128, 578813952, 700448768, 874512384, 959447040, 432537600, 180617216, 1038483456, 544800768, 63733760, 495075328, 728670208, 1029509120, 775669760, 428078080, 560987648, 543029504, 716879232, 54715456, 382664992, 304925616, 781334024, 77008132, 198298498, 559504717 - ], - [ - 536870912, 805306368, 671088640, 335544320, 369098752, 587202560, 713031680, 406847488, 387973120, 978321408, 192413696, 52166656, 573440000, 285147136, 113672192, 863748096, 231038976, 253939712, 76105728, 242605056, 57376256, 1016960768, 66047360, 488548928, 670456992, 57881296, 485561512, 266989276, 755296930, 759413209 - ], - [ - 536870912, 268435456, 134217728, 469762048, 838860800, 721420288, 209715200, 281018368, 799014912, 779091968, 603455488, 529268736, 891420672, 524877824, 550797312, 475938816, 928243712, 380637184, 5871616, 201114624, 568063488, 1044690176, 775344000, 540458432, 691431264, 112719760, 116846088, 194392324, 558291330, 541989063 - ] -] // End Direction Vectors - - - - -// The Market / Model Data -// md_c md_vols md_drifts md_starts md_detval md_disc - -[ [ // md_c[3][3] (begin) - [ 1.0000000 , 0.6000000 , 0.8000000 ], - [ 0.6000000 , 0.8000000 , 0.1500000 ], - [ 0.8000000 , 0.1500000 , 0.5809475 ] -] ] // md_c (end) - -[ [ // md_vols[367][3] volatility (begin) - [ 0.0000000 , 0.0000000 , 0.0000000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ] -] ] // md_vols volatility (end) - -[ [ // md_drifts[367][3] (begin) - [ 0.0000000000000000 , 0.0000000000000000 , 0.0000000000000000 ], - [ -0.0000769148269844 , 0.0000327749731970 , -0.0000051340050666 ], - [ -0.0000769148269844 , 0.0000327749731970 , -0.0000051340050666 ], - [ -0.0000769148269844 , 0.0000327749731970 , -0.0000051340050666 ], - [ -0.0000769117410220 , 0.0000327819160986 , -0.0000051309191042 ], - [ -0.0000769117410220 , 0.0000327819160986 , -0.0000051309191042 ], - [ -0.0000769197006278 , 0.0000342555768863 , -0.0000036470215480 ], - [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], - [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], - [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], - [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], - [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], - [ -0.0000769364349073 , 0.0000371477302492 , -0.0000007324359000 ], - [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], - [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], - [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], - [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], - [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], - [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], - [ -0.0000769609069770 , 0.0000476737925826 , 0.0000098342203061 ], - [ -0.0000769695550586 , 0.0000523282070770 , 0.0000145040722083 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], - [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], - [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], - [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], - [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], - [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], - [ -0.0000770387184138 , 0.0000516935336623 , 0.0000148283938103 ], - [ -0.0000770931821601 , 0.0000481674750561 , 0.0000109174165401 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000486764057747 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000486764057747 , 0.0000104828635101 ], - [ -0.0000770992336875 , 0.0000486764057747 , 0.0000104828635101 ], - [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], - [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], - [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], - [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], - [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], - [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], - [ -0.0000772189449197 , 0.0000489308711339 , 0.0000112366493239 ], - [ -0.0000772189449197 , 0.0000491853364932 , 0.0000112366493239 ], - [ -0.0000772189449197 , 0.0000491853364932 , 0.0000112366493239 ], - [ -0.0000773147139055 , 0.0000491853364932 , 0.0000118396779749 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351376 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], - [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351376 ], - [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], - [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], - [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], - [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], - [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], - [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], - [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], - [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], - [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], - [ -0.0000775909658212 , 0.0000511403391975 , 0.0000142949696444 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], - [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], - [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], - [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], - [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], - [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], - [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], - [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], - [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], - [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], - [ -0.0000778667234691 , 0.0000478503243642 , 0.0000114070604692 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], - [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ] -] ] // md_drifts (end) - -// md_starts[3] -[ [ 3758.0500000000001819, 11840.0000000000000000, 1200.0000000000000000 ] ] - -// model deterministic values [0] -[ [ ] ] - -// model discounts [2] -[ [ 0.9800680293073579 , 0.9800680293073579 ] ] - -// Brownian Bridge (BB) Metadata - -//BB indirect accessing: -[ [ 367, 183, 91, 45, 22, 11, 5, 2, 1, 3, 4, 8, 6, 7, 9, 10, 16, 13, 12, 14, 15, 19, 17, 18, 20, 21, 33, 27, 24, 23, 25, 26, 30, 28, 29, 31, 32, 39, 36, 34, 35, 37, 38, 42, 40, 41, 43, 44, 68, 56, 50, 47, 46, 48, 49, 53, 51, 52, 54, 55, 62, 59, 57, 58, 60, 61, 65, 63, 64, 66, 67, 79, 73, 70, 69, 71, 72, 76, 74, 75, 77, 78, 85, 82, 80, 81, 83, 84, 88, 86, 87, 89, 90, 137, 114, 102, 96, 93, 92, 94, 95, 99, 97, 98, 100, 101, 108, 105, 103, 104, 106, 107, 111, 109, 110, 112, 113, 125, 119, 116, 115, 117, 118, 122, 120, 121, 123, 124, 131, 128, 126, 127, 129, 130, 134, 132, 133, 135, 136, 160, 148, 142, 139, 138, 140, 141, 145, 143, 144, 146, 147, 154, 151, 149, 150, 152, 153, 157, 155, 156, 158, 159, 171, 165, 162, 161, 163, 164, 168, 166, 167, 169, 170, 177, 174, 172, 173, 175, 176, 180, 178, 179, 181, 182, 275, 229, 206, 194, 188, 185, 184, 186, 187, 191, 189, 190, 192, 193, 200, 197, 195, 196, 198, 199, 203, 201, 202, 204, 205, 217, 211, 208, 207, 209, 210, 214, 212, 213, 215, 216, 223, 220, 218, 219, 221, 222, 226, 224, 225, 227, 228, 252, 240, 234, 231, 230, 232, 233, 237, 235, 236, 238, 239, 246, 243, 241, 242, 244, 245, 249, 247, 248, 250, 251, 263, 257, 254, 253, 255, 256, 260, 258, 259, 261, 262, 269, 266, 264, 265, 267, 268, 272, 270, 271, 273, 274, 321, 298, 286, 280, 277, 276, 278, 279, 283, 281, 282, 284, 285, 292, 289, 287, 288, 290, 291, 295, 293, 294, 296, 297, 309, 303, 300, 299, 301, 302, 306, 304, 305, 307, 308, 315, 312, 310, 311, 313, 314, 318, 316, 317, 319, 320, 344, 332, 326, 323, 322, 324, 325, 329, 327, 328, 330, 331, 338, 335, 333, 334, 336, 337, 341, 339, 340, 342, 343, 355, 349, 346, 345, 347, 348, 352, 350, 351, 353, 354, 361, 358, 356, 357, 359, 360, 364, 362, 363, 365, 366 ], //bb_bi[367] - [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 5, 5, 6, 8, 9, 11, 11, 11, 13, 14, 16, 16, 17, 19, 20, 22, 22, 22, 22, 24, 25, 27, 27, 28, 30, 31, 33, 33, 33, 34, 36, 37, 39, 39, 40, 42, 43, 45, 45, 45, 45, 45, 47, 48, 50, 50, 51, 53, 54, 56, 56, 56, 57, 59, 60, 62, 62, 63, 65, 66, 68, 68, 68, 68, 70, 71, 73, 73, 74, 76, 77, 79, 79, 79, 80, 82, 83, 85, 85, 86, 88, 89, 91, 91, 91, 91, 91, 91, 93, 94, 96, 96, 97, 99, 100, 102, 102, 102, 103, 105, 106, 108, 108, 109, 111, 112, 114, 114, 114, 114, 116, 117, 119, 119, 120, 122, 123, 125, 125, 125, 126, 128, 129, 131, 131, 132, 134, 135, 137, 137, 137, 137, 137, 139, 140, 142, 142, 143, 145, 146, 148, 148, 148, 149, 151, 152, 154, 154, 155, 157, 158, 160, 160, 160, 160, 162, 163, 165, 165, 166, 168, 169, 171, 171, 171, 172, 174, 175, 177, 177, 178, 180, 181, 183, 183, 183, 183, 183, 183, 183, 185, 186, 188, 188, 189, 191, 192, 194, 194, 194, 195, 197, 198, 200, 200, 201, 203, 204, 206, 206, 206, 206, 208, 209, 211, 211, 212, 214, 215, 217, 217, 217, 218, 220, 221, 223, 223, 224, 226, 227, 229, 229, 229, 229, 229, 231, 232, 234, 234, 235, 237, 238, 240, 240, 240, 241, 243, 244, 246, 246, 247, 249, 250, 252, 252, 252, 252, 254, 255, 257, 257, 258, 260, 261, 263, 263, 263, 264, 266, 267, 269, 269, 270, 272, 273, 275, 275, 275, 275, 275, 275, 277, 278, 280, 280, 281, 283, 284, 286, 286, 286, 287, 289, 290, 292, 292, 293, 295, 296, 298, 298, 298, 298, 300, 301, 303, 303, 304, 306, 307, 309, 309, 309, 310, 312, 313, 315, 315, 316, 318, 319, 321, 321, 321, 321, 321, 323, 324, 326, 326, 327, 329, 330, 332, 332, 332, 333, 335, 336, 338, 338, 339, 341, 342, 344, 344, 344, 344, 346, 347, 349, 349, 350, 352, 353, 355, 355, 355, 356, 358, 359, 361, 361, 362, 364, 365 ], //bb_li[367] - [ 0, 367, 183, 91, 45, 22, 11, 5, 2, 5, 5, 11, 8, 8, 11, 11, 22, 16, 13, 16, 16, 22, 19, 19, 22, 22, 45, 33, 27, 24, 27, 27, 33, 30, 30, 33, 33, 45, 39, 36, 36, 39, 39, 45, 42, 42, 45, 45, 91, 68, 56, 50, 47, 50, 50, 56, 53, 53, 56, 56, 68, 62, 59, 59, 62, 62, 68, 65, 65, 68, 68, 91, 79, 73, 70, 73, 73, 79, 76, 76, 79, 79, 91, 85, 82, 82, 85, 85, 91, 88, 88, 91, 91, 183, 137, 114, 102, 96, 93, 96, 96, 102, 99, 99, 102, 102, 114, 108, 105, 105, 108, 108, 114, 111, 111, 114, 114, 137, 125, 119, 116, 119, 119, 125, 122, 122, 125, 125, 137, 131, 128, 128, 131, 131, 137, 134, 134, 137, 137, 183, 160, 148, 142, 139, 142, 142, 148, 145, 145, 148, 148, 160, 154, 151, 151, 154, 154, 160, 157, 157, 160, 160, 183, 171, 165, 162, 165, 165, 171, 168, 168, 171, 171, 183, 177, 174, 174, 177, 177, 183, 180, 180, 183, 183, 367, 275, 229, 206, 194, 188, 185, 188, 188, 194, 191, 191, 194, 194, 206, 200, 197, 197, 200, 200, 206, 203, 203, 206, 206, 229, 217, 211, 208, 211, 211, 217, 214, 214, 217, 217, 229, 223, 220, 220, 223, 223, 229, 226, 226, 229, 229, 275, 252, 240, 234, 231, 234, 234, 240, 237, 237, 240, 240, 252, 246, 243, 243, 246, 246, 252, 249, 249, 252, 252, 275, 263, 257, 254, 257, 257, 263, 260, 260, 263, 263, 275, 269, 266, 266, 269, 269, 275, 272, 272, 275, 275, 367, 321, 298, 286, 280, 277, 280, 280, 286, 283, 283, 286, 286, 298, 292, 289, 289, 292, 292, 298, 295, 295, 298, 298, 321, 309, 303, 300, 303, 303, 309, 306, 306, 309, 309, 321, 315, 312, 312, 315, 315, 321, 318, 318, 321, 321, 367, 344, 332, 326, 323, 326, 326, 332, 329, 329, 332, 332, 344, 338, 335, 335, 338, 338, 344, 341, 341, 344, 344, 367, 355, 349, 346, 349, 349, 355, 352, 352, 355, 355, 367, 361, 358, 358, 361, 361, 367, 364, 364, 367, 367 ] //bb_ri[367] -] - -//BB (real) data: -[ [ 1.0013689260344547, 0.5006769876043941, 0.3530474200541117, 0.2482204548705323, 0.1734206441019846, 0.1197954333762150, 0.0810884854079383, 0.0453298413911625, 0.0000000000000000, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0864406158858196, 0.0573382179080996, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.1253939592915132, 0.0864406158858196, 0.0573382179080996, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0906596827823249, 0.0641060764756032, 0.0427373843170688, 0.0370116605098802, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098802, 0.0427373843170688, 0.0370116605098803, 0.1775016882034323, 0.1253939592915132, 0.0864406158858195, 0.0573382179080996, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0906596827823249, 0.0641060764756033, 0.0427373843170689, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.1253939592915132, 0.0864406158858196, 0.0573382179080996, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756033, 0.0427373843170689, 0.0370116605098802, 0.0427373843170689, 0.0370116605098803, 0.0906596827823249, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170689, 0.0370116605098802, 0.2510252948014144, 0.1775016882034323, 0.1253939592915132, 0.0864406158858195, 0.0573382179080996, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0906596827823250, 0.0641060764756033, 0.0427373843170690, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.0641060764756032, 0.0427373843170687, 0.0370116605098802, 0.0427373843170690, 0.0370116605098802, 0.1253939592915132, 0.0864406158858195, 0.0573382179080996, 0.0370116605098802, 0.0427373843170690, 0.0370116605098802, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0906596827823250, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170690, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.1775016882034323, 0.1253939592915131, 0.0864406158858195, 0.0573382179080996, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.0641060764756032, 0.0427373843170687, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.0906596827823249, 0.0641060764756032, 0.0427373843170687, 0.0370116605098802, 0.0427373843170690, 0.0370116605098802, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.1253939592915132, 0.0864406158858195, 0.0573382179080996, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0906596827823250, 0.0641060764756033, 0.0427373843170690, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.0641060764756032, 0.0427373843170687, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.3550033764068646, 0.2510252948014144, 0.1775016882034323, 0.1253939592915132, 0.0864406158858196, 0.0573382179080996, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0906596827823249, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170693, 0.0370116605098802, 0.1253939592915131, 0.0864406158858195, 0.0573382179080995, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0906596827823249, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.1775016882034323, 0.1253939592915131, 0.0864406158858196, 0.0573382179080996, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0906596827823249, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.1253939592915133, 0.0864406158858197, 0.0573382179080998, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0906596827823249, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170693, 0.0370116605098802, 0.2510252948014144, 0.1775016882034322, 0.1253939592915131, 0.0864406158858195, 0.0573382179080995, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0906596827823249, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170693, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.1253939592915131, 0.0864406158858196, 0.0573382179080996, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0906596827823249, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.1775016882034324, 0.1253939592915133, 0.0864406158858197, 0.0573382179080998, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0906596827823249, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170693, 0.0370116605098802, 0.1253939592915133, 0.0864406158858195, 0.0573382179080995, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0906596827823250, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756035, 0.0427373843170693, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806 ], //bb_sd[367] (standard deviation) - [ 0.0000000000000000, 0.5027322404371586, 0.5054945054945055, 0.5111111111111111, 0.5227272727272727, 0.5238095238095238, 0.6000000000000000, 0.7500000000000001, 1.0000000000000000, 0.6666666666666666, 0.5000000000000001, 0.4999999999999999, 0.6666666666666669, 0.5000000000000003, 0.6666666666666666, 0.5000000000000000, 0.5454545454545455, 0.6000000000000001, 0.4999999999999994, 0.6666666666666664, 0.4999999999999994, 0.5000000000000000, 0.6666666666666664, 0.4999999999999994, 0.6666666666666664, 0.5000000000000007, 0.5217391304347826, 0.5454545454545455, 0.5999999999999996, 0.5000000000000000, 0.6666666666666677, 0.5000000000000000, 0.4999999999999996, 0.6666666666666666, 0.5000000000000000, 0.6666666666666677, 0.5000000000000000, 0.5000000000000000, 0.5000000000000004, 0.6666666666666661, 0.4999999999999987, 0.6666666666666666, 0.5000000000000000, 0.5000000000000004, 0.6666666666666661, 0.5000000000000012, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.5217391304347827, 0.5454545454545453, 0.5999999999999996, 0.5000000000000026, 0.6666666666666677, 0.5000000000000026, 0.5000000000000000, 0.6666666666666677, 0.4999999999999974, 0.6666666666666677, 0.4999999999999974, 0.4999999999999996, 0.4999999999999992, 0.6666666666666655, 0.5000000000000026, 0.6666666666666677, 0.5000000000000026, 0.5000000000000000, 0.6666666666666677, 0.4999999999999974, 0.6666666666666677, 0.4999999999999974, 0.5217391304347823, 0.5454545454545457, 0.5999999999999996, 0.4999999999999974, 0.6666666666666677, 0.4999999999999974, 0.5000000000000009, 0.6666666666666644, 0.5000000000000000, 0.6666666666666655, 0.5000000000000026, 0.5000000000000000, 0.5000000000000000, 0.6666666666666677, 0.5000000000000026, 0.6666666666666677, 0.4999999999999974, 0.5000000000000000, 0.6666666666666677, 0.4999999999999974, 0.6666666666666644, 0.5000000000000000, 0.4999999999999999, 0.5000000000000000, 0.5217391304347829, 0.5454545454545453, 0.5999999999999975, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.6666666666666690, 0.4999999999999949, 0.6666666666666666, 0.5000000000000000, 0.4999999999999992, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.6666666666666690, 0.5000000000000051, 0.5000000000000017, 0.6666666666666666, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.5217391304347829, 0.5454545454545453, 0.6000000000000016, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.4999999999999983, 0.6666666666666690, 0.5000000000000051, 0.6666666666666666, 0.5000000000000000, 0.5000000000000009, 0.4999999999999983, 0.6666666666666690, 0.4999999999999949, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.6666666666666690, 0.5000000000000051, 0.5000000000000002, 0.5217391304347825, 0.5454545454545453, 0.6000000000000016, 0.5000000000000000, 0.6666666666666690, 0.5000000000000051, 0.5000000000000017, 0.6666666666666666, 0.5000000000000000, 0.6666666666666690, 0.4999999999999949, 0.5000000000000000, 0.5000000000000017, 0.6666666666666666, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.4999999999999983, 0.6666666666666690, 0.5000000000000051, 0.6666666666666666, 0.5000000000000000, 0.5217391304347829, 0.5454545454545453, 0.5999999999999975, 0.5000000000000051, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.6666666666666690, 0.4999999999999949, 0.6666666666666666, 0.5000000000000000, 0.4999999999999992, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.6666666666666690, 0.5000000000000051, 0.5000000000000017, 0.6666666666666666, 0.5000000000000000, 0.6666666666666690, 0.4999999999999949, 0.5000000000000000, 0.5000000000000001, 0.4999999999999998, 0.5217391304347820, 0.5454545454545461, 0.5999999999999975, 0.4999999999999949, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101, 0.5000000000000017, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666576, 0.5000000000000000, 0.5217391304347825, 0.5454545454545471, 0.6000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000004, 0.5217391304347825, 0.5454545454545434, 0.6000000000000032, 0.5000000000000000, 0.6666666666666712, 0.4999999999999899, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5217391304347816, 0.5454545454545451, 0.5999999999999951, 0.4999999999999899, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101, 0.5000000000000017, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666576, 0.5000000000000000, 0.5000000000000004, 0.5000000000000000, 0.5217391304347825, 0.5454545454545471, 0.6000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.5000000000000017, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999966, 0.6666666666666576, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5217391304347825, 0.5454545454545434, 0.6000000000000032, 0.5000000000000000, 0.6666666666666712, 0.4999999999999899, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.5217391304347816, 0.5454545454545451, 0.5999999999999951, 0.4999999999999899, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101, 0.5000000000000017, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666576, 0.5000000000000000, 0.5217391304347834, 0.5454545454545471, 0.6000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.6666666666666576, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101 ], //bb_lw[367] - [ 0.0000000000000000, 0.4972677595628415, 0.4945054945054945, 0.4888888888888889, 0.4772727272727272, 0.4761904761904762, 0.4000000000000000, 0.2500000000000000, 0.0000000000000000, 0.3333333333333333, 0.4999999999999998, 0.5000000000000001, 0.3333333333333332, 0.4999999999999997, 0.3333333333333333, 0.5000000000000000, 0.4545454545454545, 0.3999999999999999, 0.5000000000000007, 0.3333333333333336, 0.5000000000000007, 0.5000000000000000, 0.3333333333333336, 0.5000000000000007, 0.3333333333333336, 0.4999999999999994, 0.4782608695652174, 0.4545454545454545, 0.4000000000000004, 0.5000000000000000, 0.3333333333333322, 0.5000000000000000, 0.5000000000000004, 0.3333333333333333, 0.5000000000000000, 0.3333333333333322, 0.5000000000000000, 0.5000000000000000, 0.4999999999999996, 0.3333333333333339, 0.5000000000000012, 0.3333333333333333, 0.5000000000000000, 0.4999999999999996, 0.3333333333333339, 0.4999999999999987, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.4782608695652172, 0.4545454545454547, 0.4000000000000004, 0.4999999999999974, 0.3333333333333322, 0.4999999999999974, 0.5000000000000000, 0.3333333333333322, 0.5000000000000026, 0.3333333333333322, 0.5000000000000026, 0.5000000000000004, 0.5000000000000009, 0.3333333333333345, 0.4999999999999974, 0.3333333333333322, 0.4999999999999974, 0.5000000000000000, 0.3333333333333322, 0.5000000000000026, 0.3333333333333322, 0.5000000000000026, 0.4782608695652177, 0.4545454545454543, 0.4000000000000004, 0.5000000000000026, 0.3333333333333322, 0.5000000000000026, 0.4999999999999992, 0.3333333333333356, 0.5000000000000000, 0.3333333333333345, 0.4999999999999974, 0.5000000000000000, 0.5000000000000000, 0.3333333333333322, 0.4999999999999974, 0.3333333333333322, 0.5000000000000026, 0.5000000000000000, 0.3333333333333322, 0.5000000000000026, 0.3333333333333356, 0.5000000000000000, 0.5000000000000001, 0.5000000000000000, 0.4782608695652171, 0.4545454545454547, 0.4000000000000024, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.3333333333333311, 0.5000000000000051, 0.3333333333333333, 0.5000000000000000, 0.5000000000000009, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.3333333333333311, 0.4999999999999949, 0.4999999999999983, 0.3333333333333333, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.4782608695652171, 0.4545454545454547, 0.3999999999999984, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.5000000000000017, 0.3333333333333311, 0.4999999999999949, 0.3333333333333333, 0.5000000000000000, 0.4999999999999992, 0.5000000000000017, 0.3333333333333311, 0.5000000000000051, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.3333333333333311, 0.4999999999999949, 0.4999999999999998, 0.4782608695652175, 0.4545454545454547, 0.3999999999999984, 0.5000000000000000, 0.3333333333333311, 0.4999999999999949, 0.4999999999999983, 0.3333333333333333, 0.5000000000000000, 0.3333333333333311, 0.5000000000000051, 0.5000000000000000, 0.4999999999999983, 0.3333333333333333, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.5000000000000017, 0.3333333333333311, 0.4999999999999949, 0.3333333333333333, 0.5000000000000000, 0.4782608695652171, 0.4545454545454547, 0.4000000000000024, 0.4999999999999949, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.3333333333333311, 0.5000000000000051, 0.3333333333333333, 0.5000000000000000, 0.5000000000000009, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.3333333333333311, 0.4999999999999949, 0.4999999999999983, 0.3333333333333333, 0.5000000000000000, 0.3333333333333311, 0.5000000000000051, 0.4999999999999999, 0.4999999999999999, 0.5000000000000002, 0.4782608695652179, 0.4545454545454539, 0.4000000000000024, 0.5000000000000051, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899, 0.4999999999999983, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333424, 0.5000000000000000, 0.4782608695652175, 0.4545454545454529, 0.4000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4999999999999996, 0.4782608695652175, 0.4545454545454565, 0.3999999999999967, 0.5000000000000000, 0.3333333333333288, 0.5000000000000101, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4782608695652184, 0.4545454545454549, 0.4000000000000049, 0.5000000000000101, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899, 0.4999999999999983, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333424, 0.5000000000000000, 0.4999999999999996, 0.5000000000000000, 0.4782608695652175, 0.4545454545454529, 0.4000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.4999999999999983, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000033, 0.3333333333333424, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4782608695652175, 0.4545454545454565, 0.3999999999999967, 0.5000000000000000, 0.3333333333333288, 0.5000000000000101, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.4782608695652184, 0.4545454545454549, 0.4000000000000049, 0.5000000000000101, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899, 0.4999999999999983, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333424, 0.5000000000000000, 0.4782608695652166, 0.4545454545454529, 0.4000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.3333333333333424, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899 ] //bb_rw[367] -] - -// [(EXsimple_price(EUR, 1046.247619993985, "MC BS (C) 3dim, Sobol, 131072 paths, 34771 ms"))] diff --git a/OptionPricing/Data/Large/output.data b/OptionPricing/Data/Large/output.data deleted file mode 100644 index 3ee5621..0000000 --- a/OptionPricing/Data/Large/output.data +++ /dev/null @@ -1 +0,0 @@ -[ 1046.2474858484 ] // Price for the large contract diff --git a/OptionPricing/Data/Medium/input.data b/OptionPricing/Data/Medium/input.data deleted file mode 100644 index a21a39b..0000000 --- a/OptionPricing/Data/Medium/input.data +++ /dev/null @@ -1,108 +0,0 @@ -2 // contract number -1048576 // number of Monte-Carlo Iterations -5 // number of path dates -3 // number of underlyings -1 // number of models -30 // integer bit-length representation for Sobol - -// Begin Direction vectors [3*5][30] -[ - [ - 536870912, 268435456, 134217728, 67108864, 33554432, 16777216, 8388608, 4194304, 2097152, 1048576, 524288, 262144, 131072, 65536, 32768, 16384, 8192, 4096, 2048, 1024, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1 - ], - [ - 536870912, 805306368, 671088640, 1006632960, 570425344, 855638016, 713031680, 1069547520, 538968064, 808452096, 673710080, 1010565120, 572653568, 858980352, 715816960, 1073725440, 536879104, 805318656, 671098880, 1006648320, 570434048, 855651072, 713042560, 1069563840, 538976288, 808464432, 673720360, 1010580540, 572662306, 858993459 - ], - [ - 536870912, 805306368, 402653184, 603979776, 973078528, 385875968, 595591168, 826277888, 438304768, 657457152, 999817216, 358875136, 538574848, 807862272, 406552576, 605372416, 975183872, 389033984, 597170176, 828646400, 437926400, 656873216, 1002152832, 357921088, 536885792, 805312304, 402662296, 603992420, 973085210, 385885991 - ], - [ - 536870912, 805306368, 939524096, 335544320, 234881024, 721420288, 411041792, 616562688, 920649728, 1062207488, 381157376, 258736128, 771883008, 453181440, 545488896, 817971200, 954261504, 340963328, 238651392, 732843008, 417426944, 609285376, 909831040, 1068349120, 383778848, 256901168, 783810616, 460062740, 537001998, 805503019 - ], - [ - 536870912, 805306368, 402653184, 1006632960, 167772160, 285212672, 713031680, 566231040, 853540864, 489684992, 952631296, 208928768, 316801024, 758317056, 550076416, 813154304, 417505280, 1009913856, 172697600, 297131008, 704744960, 553894656, 847291520, 499194688, 954376224, 204607536, 306915352, 766893116, 536972810, 805552913 - ], - [ - 536870912, 805306368, 402653184, 469762048, 301989888, 721420288, 92274688, 264241152, 941621248, 741343232, 169345024, 924581888, 395444224, 619380736, 1034256384, 603963392, 838868992, 452997120, 494934016, 331357184, 706744832, 120597248, 261621120, 953946048, 800208928, 148581424, 935168536, 350484252, 630339474, 1072370923 - ], - [ - 536870912, 805306368, 134217728, 1006632960, 503316480, 754974720, 629145600, 440401920, 94371840, 711983104, 229113856, 374079488, 330694656, 996212736, 907247616, 557531136, 867573760, 190918656, 1041467392, 490437632, 766918144, 643898624, 462663040, 125527616, 672545696, 202454896, 373006376, 288845836, 1000351766, 930090001 - ], - [ - 536870912, 268435456, 402653184, 872415232, 838860800, 956301312, 612368384, 717225984, 211812352, 386924544, 302514176, 688128000, 1015414784, 516751360, 1051492352, 773734400, 914432000, 63877120, 807741440, 165200896, 748683776, 118489344, 168296832, 486802240, 243663648, 667747216, 439124552, 81674924, 975249610, 350138737 - ], - [ - 536870912, 268435456, 671088640, 469762048, 973078528, 1023410176, 713031680, 339738624, 912261120, 797966336, 176685056, 71565312, 510263296, 865533952, 814120960, 961232896, 887136256, 668078080, 116070400, 382772224, 1047134720, 597098752, 411468416, 625689024, 249602976, 449975248, 745216680, 43033924, 134873446, 201786361 - ], - [ - 536870912, 268435456, 402653184, 67108864, 704643072, 385875968, 696254464, 205520896, 920649728, 946864128, 359137280, 859045888, 302907392, 50659328, 462192640, 524599296, 895541248, 590794752, 168810496, 118033408, 831447552, 138662144, 485185920, 796511296, 1021313184, 1064304752, 619184920, 997458052, 250479054, 745865975 - ], - [ - 536870912, 268435456, 939524096, 1006632960, 838860800, 889192448, 645922816, 46137344, 476053504, 584056832, 210239488, 465829888, 820903936, 689897472, 73695232, 249118720, 110075904, 315338752, 610637824, 517665792, 1049494016, 785318144, 376210304, 735921088, 402760480, 738505552, 168368744, 151499820, 344957894, 936096557 - ], - [ - 536870912, 805306368, 939524096, 1006632960, 503316480, 922746880, 41943040, 423624704, 228589568, 651165696, 195559424, 500957184, 791019520, 261292032, 1040285696, 118407168, 982065152, 625250304, 329533440, 298984448, 153690624, 76845824, 579619712, 692987840, 900670432, 450334832, 363187112, 719119956, 765461306, 382730781 - ], - [ - 536870912, 805306368, 402653184, 603979776, 838860800, 117440512, 478150656, 658505728, 752877568, 1060110336, 141033472, 209453056, 244187136, 272957440, 678068224, 1014546432, 377724928, 876875776, 443160576, 998185984, 168665600, 318837504, 914397568, 71818816, 40763680, 527762288, 939688008, 335855668, 705536494, 587273091 - ], - [ - 536870912, 268435456, 671088640, 738197504, 637534208, 150994944, 813694976, 943718400, 77594624, 179306496, 798490624, 967049216, 134348800, 1006698496, 235044864, 620937216, 377643008, 826314752, 874711040, 854819840, 725109248, 856992512, 664336768, 94804544, 100663328, 419430416, 411041832, 339738668, 580911142, 61865993 - ], - [ - 536870912, 805306368, 939524096, 603979776, 100663296, 452984832, 998244352, 188743680, 866123776, 389021696, 287834112, 172228608, 824836096, 977731584, 153714688, 507854848, 254402560, 88403968, 883578880, 235160576, 118055424, 422917888, 371224704, 326210368, 654926368, 691353392, 773877944, 930190180, 554263078, 842348331 - ] -] // End Direction Vectors - - - - -// The Market / Model Data -// md_c md_vols md_drifts md_starts md_detval md_disc - -[[ // md_c[1][3][3] (begin) - [ 1.0000000 , 0.6000000 , 0.8000000 ], - [ 0.6000000 , 0.8000000 , 0.1500000 ], - [ 0.8000000 , 0.1500000 , 0.5809475 ] -]] // md_c (end) - -[[ // md_vols[1][5][3] volatility (begin) - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ], - [ 0.1900000 , 0.1900000 , 0.1500000 ] -]] // md_vols volatility (end) - -[[ // md_drifts[1][5][3] (begin) - [ -0.0283491736871803 , 0.0178771081725381 , 0.0043096808044729 ], - [ -0.0183841413744211 , -0.0044530897672834 , 0.0024263805987983 ], - [ -0.0172686581005089 , 0.0125638544546015 , 0.0094452810918001 ], - [ -0.0144179417871814 , 0.0157411263968213 , 0.0125315353728014 ], - [ -0.0121497422218761 , 0.0182904634062437 , 0.0151125070556484 ] -]] // md_drifts (end) - -// md_starts[1][3] -[[ 3758.0500000000001819, 11840.0000000000000000, 1200.0000000000000000 ]] - -// model deterministic values [0] -[[ ]] - -// model discounts [5] -[[ 0.9797862861805930 , 0.9505748482484491 , 0.9214621679912968 , 0.8906693055891434 , 0.8588567633110704 ]] - -// Brownian Bridge (BB) Metadata - -//BB indirect accessing: -[ [ 5, 2, 1, 3, 4 ], //bb_bi[5] - [ 0, 0, 0, 2, 3 ], //bb_li[5] - [ 0, 5, 2, 5, 5 ] //bb_ri[5] -] - -//BB (real) data: -[ [ 2.2372928847280580, 1.0960951589853829, 0.7075902730592357, 0.8166828043492210, 0.7075902730592357 ], //bb_sd[5] (standard deviation) - [ 0.0000000000000000, 0.5998905309250137, 0.4993160054719562, 0.6669708029197080, 0.5006839945280438 ], //bb_lw[5] - [ 0.0000000000000000, 0.4001094690749863, 0.5006839945280438, 0.3330291970802919, 0.4993160054719562 ] //bb_rw[5] -] - -// [(EXsimple_price(EUR, 937.3914952240884, "MC BS (C) 3dim, Sobol, 1048576 paths, 1800 ms"))] diff --git a/OptionPricing/Data/Medium/output.data b/OptionPricing/Data/Medium/output.data deleted file mode 100644 index 6111972..0000000 --- a/OptionPricing/Data/Medium/output.data +++ /dev/null @@ -1 +0,0 @@ -[ 937.3915829436 ] // Price for medium contract diff --git a/OptionPricing/Data/Small/input.data b/OptionPricing/Data/Small/input.data deleted file mode 100644 index 1f27037..0000000 --- a/OptionPricing/Data/Small/input.data +++ /dev/null @@ -1,56 +0,0 @@ -1 // contract number -8388608 // number of Monte-Carlo Iterations -1 // number of path dates -1 // number of underlyings -1 // number of models -30 // integer bit-length representation for Sobol - -// Begin Direction vectors [1*1][30] -[ - [ - 536870912, 268435456, 134217728, 67108864, 33554432, 16777216, 8388608, 4194304, 2097152, 1048576, 524288, 262144, 131072, 65536, 32768, 16384, 8192, 4096, 2048, 1024, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1 - ] -] // End Direction Vectors - - - - -// The Market / Model Data -// md_c md_vols md_drifts md_starts md_detval md_disc - -[ [ // md_c[1][1] (begin) - [ 1.0000000 ] -] ] // md_c (end) - -[ [ // md_vols[1][1] volatility (begin) - [ 0.1900000 ] -] ] // md_vols volatility (end) - -[ [ // md_drifts[1][1] (begin) - [ -0.0276481070940405 ] -] ] // md_drifts (end) - -// md_starts[1] -[ [ 3758.0500000000001819 ] ] - -// model deterministic values [1] -[ [ 0.9997817434496459 ] ] - -// model discounts [1] -[ [ 0.9805494836196852 ] ] - -// Brownian Bridge (BB) Metadata - -//BB indirect accessing: -[ [ 1 ], //bb_bi[1] - [ 0 ], //bb_li[1] - [ 0 ] //bb_ri[1] -] - -//BB (real) data: -[ [ 0.9889803798765787 ], //bb_sd[1] (standard deviation) - [ 0.0000000000000000 ], //bb_lw[1] - [ 0.0000000000000000 ] //bb_rw[1] -] - -// [(EXsimple_price(EUR, 98.05493927001953, "MC BS (C) 1dim, Sobol, 8388608 paths, 1060 ms"))] diff --git a/OptionPricing/Data/Small/output.data b/OptionPricing/Data/Small/output.data deleted file mode 100644 index 128994a..0000000 --- a/OptionPricing/Data/Small/output.data +++ /dev/null @@ -1 +0,0 @@ -[ 167.05571416613 ] // Price for the small contract diff --git a/OptionPricing/HaskellLH/Makefile b/OptionPricing/HaskellLH/Makefile deleted file mode 100644 index 4cdb206..0000000 --- a/OptionPricing/HaskellLH/Makefile +++ /dev/null @@ -1,44 +0,0 @@ -# can be set using $>gmake GHC=/path/to/my/ghc -ifeq ($(strip $(GHC)),) - GHC=`which ghc` -endif - -# switch this on if llvm is enabled -#BACKEND=-fllvm - -OPTIMIZATION=-O2 -msse2 -rtsopts -#-Wall -EXECUTABLE=GenPricing - -all: $(EXECUTABLE) - -$(EXECUTABLE): % : %.hs - $(GHC) $(OPTIMIZATION) --make $< -o $@ - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) - -run_large: $(EXECUTABLE) - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) - - -#------------------------------------------------------------------------- -# clean -#------------------------------------------------------------------------- -.PHONY : clean_executables clean_obj clean_source_backup -.SILENT : clean_executables clean_obj clean_source_backup - -clean: clean_executables clean_obj clean_source_backup - -clean_executables: - rm -f $(EXECUTABLE) - -clean_obj : - rm -f *.o *.hi - -clean_source_backup: - rm -f *~ - diff --git a/OptionPricing/OrigCpp/Makefile b/OptionPricing/OrigCpp/Makefile deleted file mode 100644 index b37237c..0000000 --- a/OptionPricing/OrigCpp/Makefile +++ /dev/null @@ -1,38 +0,0 @@ -include ../../setup.mk - -ifndef ($(HAVE_GPU)) -include ../../platform.mk -endif - -INCLUDES += -I../includeC -GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) - -SOURCES_CPP =GenPricing.cpp -HELPERS =Contracts.h SobolGaussBB.h ../includeC/Constants.h ../includeC/Optimizations.h ../includeC/ParseInput.h -# XXX what about the boilerplate in ../includeC ??? -OBJECTS =GenPricing.o -EXECUTABLE =GenPricing - -default: cpu - -# TODO need redesign, probably use different executable names (or -# standardisation of "gpu" targets across all benchmarks) - -.cpp.o: $(SOURCES_CPP) $(HELPERS) - $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< - -cpu: $(OBJECTS) - $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) - -run_small: $(EXECUTABLE) - cat ../Data/Small/input.data ../Data/Small/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_medium: $(EXECUTABLE) - cat ../Data/Medium/input.data ../Data/Medium/output.data | ./$(EXECUTABLE) 2> Debug.txt - -run_large: $(EXECUTABLE) - cat ../Data/Large/input.data ../Data/Large/output.data | ./$(EXECUTABLE) 2> Debug.txt - -clean: - rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) - diff --git a/OptionPricing/includeC/Contracts.h b/OptionPricing/includeC/Contracts.h deleted file mode 100644 index 56ca84c..0000000 --- a/OptionPricing/includeC/Contracts.h +++ /dev/null @@ -1,139 +0,0 @@ -#ifndef CONTRACTS_CODE -#define CONTRACTS_CODE - -#define underlyings(i,j) \ - (inst_traj[i*num_under + j]) - -inline -void trajectory_inner( - const UINT& num_cash_flows, - const UINT& model_ind, // the model index - const UINT& disct_index,// index of the discount - const REAL& amount, // update with amount - const REAL* md_discts, // [model_num][num_cash_flow] discounts - double* vhat // [model_num] Accumulated per-model price -) { - UINT ind = disct_index + model_ind*num_cash_flows; - vhat[model_ind] += (amount * md_discts[ind]); -} - -inline -void trajectory_contract1( // SMALL - const UINT& model_num, // the index of the current model - const UINT& num_under, // the number of underlyings - const UINT& num_cash_flows, - const UINT& num_pricers,// the number of deterministic procers - const REAL* md_discts, // [num_models][num_cash_flows] discounts - const REAL* md_detvals, // [num_models, num_det_pricers] pricers - const REAL* inst_traj, // [num_dates, num_under] current trajectory - double* vhat // [model_num] Accumulated per-model price - -) { - REAL amount = ((underlyings(0,0)) - 4000.0) * md_detvals[model_num*num_pricers]; - amount = fmax(0.0, amount); - trajectory_inner( num_cash_flows, model_num, 0, amount, md_discts, vhat ); -} - -inline -void trajectory_contract2( // MEDIUM - const UINT& model_num, // the index of the current model - const UINT& num_under, // the number of underlyings - const UINT& num_cash_flows, - const UINT& num_pricers,// the number of deterministic procers - const REAL* md_discts, // [num_models][num_cash_flows] discounts - const REAL* md_detvals, // [num_models, num_det_pricers] pricers - const REAL* inst_traj, // [num_dates, num_under] current trajectory - double* vhat // [model_num] Accumulated per-model price -) { - double x50; - int date; - double amount; - - if ( 1. <= fmin( underlyings(0,1) / 11840., fmin( underlyings(0,2) / 1200., underlyings(0,0) / 3758.05 ) ) ) { - //goto L21; - date = 0; amount = 1150.; - } else if ( 1. <= fmin( underlyings(1,1) / 11840., fmin( underlyings(1,2) / 1200., underlyings(1,0) / 3758.05 ) ) ) { - //goto L22; - date = 1; amount = 1300.; - } else if ( 1. <= fmin( underlyings(2,1) / 11840., fmin( underlyings(2,2) / 1200., underlyings(2,0) / 3758.05 ) ) ) { - //goto L23; - date = 2; amount = 1450.; - } else if ( 1. <= fmin( underlyings(3,1) / 11840., fmin( underlyings(3,2) / 1200., underlyings(3,0) / 3758.05 ) ) ) { - //goto L24; - date = 3; amount = 1600.; - } else { - date = 4; - x50 = fmin( underlyings(4,1) / 11840., fmin( underlyings(4,2) / 1200., underlyings(4,0) / 3758.05 ) ); - if( 1. <= x50 ) { amount = 1750.; } - else if ( 0.75 < x50 ) { amount = 1000.; } - else { amount = x50*1000.; } - } - - trajectory_inner( num_cash_flows, model_num, date, amount, md_discts, vhat ); -} - - -inline -void trajectory_contract3( // MARGE (Barrier Contract) - const UINT& model_num, // the index of the current model - const UINT& num_under, // the number of underlyings - const UINT& num_cash_flows, - const UINT& num_pricers,// the number of deterministic procers - const REAL* md_discts, // [num_models][num_scash_flow] discounts - const REAL* md_detvals, // [num_models, num_det_pricers] pricers - const REAL* inst_traj, // [num_dates, num_under] current trajectory - double* vhat // [model_num] Accumulated per-model price -) { - bool goto_L40, x3309 = false; - REAL mult = 0.0; - for(int i=0; (i<367 && (!x3309)); i++) { - x3309 = x3309 || - (underlyings(i,0) <= 2630.6349999999998) || - (underlyings(i,1) <= 8288.) || - (underlyings(i,2) <= 840. ) ; - } - - trajectory_inner( num_cash_flows, model_num, 0, 100., md_discts, vhat ); - - goto_L40 = x3309 && - ( (underlyings(366,0) < 3758.05) || - (underlyings(366,1) < 11840. ) || - (underlyings(366,2) < 1200. ) ); - - mult = (goto_L40) ? 1.0 : 0.0; - - const REAL min_amount = fmin( (underlyings(366,1) / 11840.) - 1., - fmin( (underlyings(366,2) / 1200. ) - 1., - (underlyings(366,0) / 3758.05) - 1. ) ); - - const REAL amount = 1000. * ( 1. + mult*min_amount ) ; - - trajectory_inner( num_cash_flows, model_num, 1, amount, md_discts, vhat ); -} - - -inline -void aggregDiscountedPayoff( - const UINT& model_num, // the index of the current model - const UINT& contr_num, - const UINT& num_under, // the number of underlyings - const UINT& num_cash_flows, - const UINT& num_pricers,// the number of deterministic procers - const REAL* md_discts, // [num_models][num_scash_flow] discounts - const REAL* md_detvals, // [num_models, num_det_pricers] pricers - const REAL* inst_traj, // [num_dates, num_under] current trajectory - double* vhat // [model_num] Accumulated per-model price -) { - if (contr_num == 1) { - trajectory_contract1(model_num, num_under, num_cash_flows, num_pricers, md_discts, md_detvals, inst_traj, vhat); - } else if (contr_num == 2) { - trajectory_contract2(model_num, num_under, num_cash_flows, num_pricers, md_discts, md_detvals, inst_traj, vhat); - } else if (contr_num == 3) { - trajectory_contract3(model_num, num_under, num_cash_flows, num_pricers, md_discts, md_detvals, inst_traj, vhat); - } else { - trajectory_contract1(model_num, num_under, num_cash_flows, num_pricers, md_discts, md_detvals, inst_traj, vhat); - } -} - -#endif //CONTRACTS_CODE - diff --git a/OptionPricing/includeC/Optimizations.h b/OptionPricing/includeC/Optimizations.h deleted file mode 100644 index 76bd4fd..0000000 --- a/OptionPricing/includeC/Optimizations.h +++ /dev/null @@ -1,10 +0,0 @@ -#ifndef OPTIMISATIONS -#define OPTIMISATIONS - -#define _OPTIMIZATION_USE_FLOATS 1 -#define _OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV 0 // cost model: 0, vectorized: 1, privatized: 2 -#define _OPTIMIZATION_SOBOL_STRENGTH_RED_RECURR -#define _OPTIMIZATION_MEM_COALES_ON - -#endif // OPTIMISATIONS - diff --git a/benchmarks.hs b/benchmarks.hs deleted file mode 100644 index a41b878..0000000 --- a/benchmarks.hs +++ /dev/null @@ -1,171 +0,0 @@ -{-# LANGUAGE CPP,RecordWildCards #-} - --- running finpar benchmarks --- Usage: runhaskell benchmarks.hs - -import System.Environment -import System.IO -import System.Process -- run commands -import System.Exit -- exit codes -import System.Directory -import System.FilePath -import System.Console.GetOpt -import Control.Exception -import Text.ParserCombinators.ReadP -- (string, readP_to_S) -import Control.Monad -import Control.Applicative((<*), (<$>), (<*>), pure ) -import Data.Maybe - - -------------------------------- options of this script: ------------------------- -options = - [ Option ['v'] ["verbose"] (NoArg (\o -> o{optVerbose = True})) - "report activities on stderr" - -- , Option ['g'] ["graph"] (ReqArg (\f o -> o{optGraph = Just f}) "out.png") - -- "output a png graph to given filename" - , Option [] ["all"] (NoArg (\o -> o{optAll = True})) - "run all configured benchmarks" - , Option ['s'] ["small"] (NoArg (\o -> o{optSize = Small})) - "run on small data (default)" - , Option ['m'] ["medium"] (NoArg (\o -> o{optSize = Medium})) - "run on medium data" - , Option ['l'] ["large"] (NoArg (\o -> o{optSize = Large})) - "run on large data" - ] - -data Options = Options - { optVerbose :: Bool - , optGraph :: Maybe FilePath - , optAll :: Bool - , optSize :: BenchSize - } -instance Show Options where - show Options{..} = "// Options:" - ++ "Running with " ++ show optSize ++ " data size, " - ++ (if optVerbose then "verbose, " else "") - -- ++ (case optGraph of - -- Just f -> "output to " ++ f ++ ", " - -- Nothing -> "" - -- ) - ++ (if optAll then "(all benchmarks)" else "") - -defaults = Options { optVerbose = False, optGraph = Nothing - , optAll = False, optSize = Small } - -data BenchSize = Small | Medium | Large - deriving (Eq,Ord) -instance Show BenchSize where - show Small = "small" - show Medium = "medium" - show Large = "large" -instance Read BenchSize where - readsPrec _ = readP_to_S $ - (string "small" >> return Small) +++ - (string "medium" >> return Medium) +++ - (string "large" >> return Large) - ---------------------------------------------------------------------------------- - -usage = usageInfo "runhaskell benchmarks.hs [OPTIONS] benchmarkname" options - -main = do putStrLn "Please use make!" - args <- getArgs - let (opts,bs) = case getOpt Permute options args of - (o, [], []) -> - (foldl (flip ($)) defaults{optAll=True} o, []) - -- (flip id) :-] - (o, n, []) -> (foldl (flip ($)) defaults o, n) - (_,_,errs) -> error (concat errs ++ '\n':usage) - benches <- filterM doesDirectoryExist - (if optAll opts then dirnames else bs) - when (optVerbose opts) $ do hPutStrLn stderr usage - print benches - print opts - mapM_ (runBench opts) benches - - ---------------------------------------------------------------------------------- -runBench :: Options -> String -> IO () -runBench Options{..} dir = - do (e,msg) <- runMake optVerbose dir [] - (ret,out) <- if e /= ExitSuccess then return (e,msg) - else runMake optVerbose dir ["run_" ++ show optSize] - when (optVerbose || (ret /= ExitSuccess)) - (hPutStrLn stderr ("make returned " ++ show ret)) - -- parsing output - putStrLn out - -runMake :: Bool -> FilePath -> [String] -> IO (ExitCode,String) -runMake verbose dir targets = do - when verbose (putStrLn ("make " ++ unwords ("-C":dir:targets))) - dirOK <- doesDirectoryExist dir - if not dirOK then return (ExitFailure 1, dir ++ ": does not exist") - else do - let args = (if verbose then ["-C"] else ["--no-print-directory","-C"]) - (code, stdo, stde) <- readProcessWithExitCode "make" (args ++dir:targets) "" - when verbose $ hPutStrLn stderr ("Output from " ++ dir ++ "\nstdout:\n" - ++ stdo ++ "\nstderr:\n" ++ stde) - return (code,stdo) - --- every directory with source code must supply a makefile with --- default target compiling the program, and targets run_small, --- run_medium, run_large with test data in a relative path "../Data" - --- names of target directories (only those with code) -dirnames = ["CalibVolDiff" "Orig_COpenMP" - , "CalibVolDiff" "Original" - , "CalibVolDiff" "All_COpenMPCL" - , "CalibVolDiff" "Outer_COpenMPCL" - , "CalibVolDiff" "HaskellLH" --- , "CalibGA/CppAndGPU" --- , "CalibGA/python" --- , "CalibGA/OCaml" - , "GenericPricing" "Orig_COpenMp" - , "GenericPricing" "CppOpenCL" - , "GenericPricing" "HaskellLH" - ] - --- names of different benchmarks -benchnames = [ "CalibVolDiff" - , "GenericPricing" - -- , "CalibGA" - ] - --- code directories inside benchmark directories; kind-of ad-hoc standardised -codenames = ["Orig_COpenMP", "Original", "CppOpenCL" - , "All_COpenMPCL", "Outer_COpenMPCL" - , "HaskellLH" - ] - - ---------------------- --- parsing using ReadP (no external library required) - -signed p = (char '-' >> (('-':) <$> p)) +++ p - -whitespace :: ReadP () -whitespace = skipSpaces <* - optional (string "//" >> manyTill anyChar (char '\n') >> whitespace) -anyChar = satisfy (const True) -digit = satisfy (`elem` ['0'..'9']) - -lexeme :: ReadP a -> ReadP a -lexeme p = p <* whitespace - --- token :: String -> Parser () -token = return () . lexeme . string - -readInt :: ReadP Int -readInt = lexeme $ read <$> signed (many1 digit) - -readDouble :: ReadP Double -readDouble = read <$> signed (s2 +++ s1) - where s1 = do bef <- many1 digit - aft <- option "" ((:) <$> char '.' <*> many1 digit) - return $ bef ++ aft - s2 = (++) <$> (char '.' >> pure "0.") <*> many1 digit - --- not ready: --- readArray :: ReadP a -> ReadP [a] --- readArray p = lexeme $ between (token "[") (token "]") (p `sepBy` token ",") - diff --git a/InterestCalib/README.txt b/benchmarks/InterestCalib/README.txt similarity index 96% rename from InterestCalib/README.txt rename to benchmarks/InterestCalib/README.txt index e70018c..c9962ef 100644 --- a/InterestCalib/README.txt +++ b/benchmarks/InterestCalib/README.txt @@ -1,3 +1,5 @@ +FIXME: this README is outdated. + 1. Compile & Run with: $ make clean; make; make run_medium diff --git a/InterestCalib/Data/Large/input.data b/benchmarks/InterestCalib/datasets/large/input.json similarity index 90% rename from InterestCalib/Data/Large/input.data rename to benchmarks/InterestCalib/datasets/large/input.json index 58d5534..6491f1b 100644 --- a/InterestCalib/Data/Large/input.data +++ b/benchmarks/InterestCalib/datasets/large/input.json @@ -1,7 +1,9 @@ -128 // population size -424 // number of iterations of the convergence loop -196 // number of swaption quotes (NUM_SWAP_QUOTES) -[ +{ + "population_size": 128, + "convergence_iterations": 424, + "num_swaption_quotes": 196, + "swaption_quotes": + [ [1.0, 6.0, 1.0, 1.052], [2.0, 6.0, 1.0, 0.81485], [3.0, 6.0, 1.0, 0.6165], @@ -211,33 +213,32 @@ [20.0, 6.0, 30.0, 0.1989], [25.0, 6.0, 30.0, 0.18115], [30.0, 6.0, 30.0, 0.16355] -] // SwaptionQuotes :: REAL[NUM_SWAP_QUOTES,4] + ], - - -11 // Gauss_DIM: Number of Hermite Coefficients; -[ + "num_hermite_coefficients": 11, + "hermite_coefficients": + [ 0.0, 0.6568095668820999044613, -0.6568095668820997934390, -1.3265570844949334805563, 1.3265570844949330364670, 2.0259480158257567872226, -2.0259480158257558990442, -2.7832900997816496513337, 2.7832900997816474308877, 3.6684708465595856630159, -3.6684708465595838866591 -] // GaussHermiteCoefs::coefs[Gauss_DIM] + ], -[ + "hermite_coefficient_weights": + [ 0.6547592869145917315876, 0.6609604194409607336169, 0.6609604194409606225946, 0.6812118810666693002887, 0.6812118810666689672217, 0.7219536247283847574252, 0.7219536247283852015144, 0.8025168688510405656800, 0.8025168688510396775015, 1.0065267861723647957461, 1.0065267861723774522886 -] // GaussHermiteCoefs::weights[Gauss_DIM] - - - -30 // SOBOL_BITS_NUM -[ 536870912, 268435456, 134217728, 67108864, 33554432, - 16777216, 8388608, 4194304, 2097152, 1048576, - 524288, 262144, 131072, 65536, 32768, - 16384, 8192, 4096, 2048, 1024, - 512, 256, 128, 64, 32, - 16, 8, 4, 2, 1 -] // SOBOL_DIR_VCT == Sobol Direction Vectors REAL[SOBOL_BITS_NUM] - + ], + + "sobol_num_bits": 30, + "sobol_dir_vs": + [ 536870912, 268435456, 134217728, 67108864, 33554432, + 16777216, 8388608, 4194304, 2097152, 1048576, + 524288, 262144, 131072, 65536, 32768, + 16384, 8192, 4096, 2048, 1024, + 512, 256, 128, 64, 32, + 16, 8, 4, 2, 1 + ] +} diff --git a/benchmarks/InterestCalib/datasets/large/output.json b/benchmarks/InterestCalib/datasets/large/output.json new file mode 100644 index 0000000..19162b3 --- /dev/null +++ b/benchmarks/InterestCalib/datasets/large/output.json @@ -0,0 +1,207 @@ +{ + "a_field": 0.023511, + "b_field": 0.964110, + "sigma_field": 0.025390, + "nu_field": 0.142763, + "rho_field": -0.912444, + "lg_likelyhood": 504.367344, + "swaption_calibration_result": + [ + [ 157.397565 , 115.320470 , 36.487100 ], + [ 158.760952 , 162.945479 , 2.568054 ], + [ 165.097976 , 174.297729 , 5.278183 ], + [ 175.510974 , 171.631308 , 2.260465 ], + [ 185.096581 , 168.408756 , 9.909120 ], + [ 193.322704 , 168.310831 , 14.860525 ], + [ 199.745999 , 169.877089 , 17.582659 ], + [ 204.980646 , 172.511293 , 18.821581 ], + [ 207.965455 , 172.824865 , 20.333063 ], + [ 210.211604 , 172.561368 , 21.818462 ], + [ 209.496752 , 177.275607 , 18.175735 ], + [ 198.058665 , 161.933876 , 22.308358 ], + [ 180.931070 , 139.430038 , 29.764772 ], + [ 162.740296 , 120.029132 , 35.583998 ], + [ 180.828953 , 136.735565 , 32.247198 ], + [ 197.570095 , 228.603138 , 13.575073 ], + [ 231.652896 , 275.866189 , 16.027079 ], + [ 267.035700 , 293.303444 , 8.955825 ], + [ 296.574053 , 305.655752 , 2.971218 ], + [ 320.041550 , 313.896508 , 1.957665 ], + [ 338.547315 , 323.484107 , 4.656553 ], + [ 352.372052 , 330.054072 , 6.761916 ], + [ 362.299599 , 335.261016 , 8.064935 ], + [ 369.752884 , 335.769411 , 10.121075 ], + [ 379.269057 , 354.321026 , 7.041081 ], + [ 362.343709 , 318.366856 , 13.813264 ], + [ 333.799298 , 274.710927 , 21.509290 ], + [ 301.589807 , 236.227803 , 27.669057 ], + [ 172.210684 , 192.203184 , 10.401753 ], + [ 227.955695 , 306.754568 , 25.687922 ], + [ 299.934061 , 377.675217 , 20.584129 ], + [ 362.136697 , 412.847194 , 12.283115 ], + [ 410.791383 , 436.793689 , 5.952995 ], + [ 448.676865 , 457.418930 , 1.911173 ], + [ 477.384722 , 472.046625 , 1.130841 ], + [ 499.183038 , 483.257228 , 3.295514 ], + [ 515.122617 , 491.981354 , 4.703687 ], + [ 527.462746 , 496.017051 , 6.339640 ], + [ 543.860701 , 526.391523 , 3.318666 ], + [ 520.875868 , 470.271579 , 10.760652 ], + [ 480.620983 , 406.010507 , 18.376489 ], + [ 434.912156 , 349.521869 , 24.430599 ], + [ 175.817605 , 234.956228 , 25.170060 ], + [ 281.983907 , 379.997542 , 25.793229 ], + [ 386.986699 , 470.343801 , 17.722590 ], + [ 470.710384 , 525.541048 , 10.433184 ], + [ 534.924952 , 566.158092 , 5.516682 ], + [ 583.629049 , 592.597274 , 1.513376 ], + [ 620.647894 , 612.901965 , 1.263812 ], + [ 648.638703 , 631.047390 , 2.787637 ], + [ 669.568744 , 645.427184 , 3.740400 ], + [ 684.736202 , 654.142965 , 4.676843 ], + [ 704.954513 , 694.837660 , 1.456002 ], + [ 674.726162 , 617.784741 , 9.217033 ], + [ 622.980296 , 533.755298 , 16.716461 ], + [ 563.277986 , 459.106740 , 22.689984 ], + [ 203.693343 , 276.585395 , 26.354266 ], + [ 354.131456 , 452.559843 , 21.749253 ], + [ 484.673742 , 563.065703 , 13.922347 ], + [ 585.697217 , 634.734726 , 7.725670 ], + [ 661.769994 , 685.829366 , 3.508070 ], + [ 719.413650 , 722.893858 , 0.481427 ], + [ 763.082942 , 749.627445 , 1.794958 ], + [ 796.409044 , 777.716103 , 2.403569 ], + [ 820.552620 , 793.738233 , 3.378241 ], + [ 838.266809 , 814.271603 , 2.946831 ], + [ 860.928096 , 858.501503 , 0.282654 ], + [ 824.031243 , 761.317980 , 8.237460 ], + [ 760.549282 , 657.575731 , 15.659573 ], + [ 687.849618 , 565.396155 , 21.657994 ], + [ 248.505950 , 302.881789 , 17.952826 ], + [ 434.064679 , 507.004879 , 14.386489 ], + [ 585.500618 , 646.006214 , 9.366101 ], + [ 700.296189 , 732.520960 , 4.399160 ], + [ 786.607031 , 799.352396 , 1.594461 ], + [ 851.884344 , 846.847045 , 0.594830 ], + [ 901.714482 , 886.814283 , 1.680194 ], + [ 939.036181 , 919.813612 , 2.089833 ], + [ 966.478792 , 947.705019 , 1.980972 ], + [ 986.566873 , 973.538216 , 1.338279 ], + [ 1012.284446 , 1018.774022 , 0.636999 ], + [ 968.529570 , 900.113746 , 7.600798 ], + [ 894.291386 , 777.120699 , 15.077540 ], + [ 809.047014 , 668.478449 , 21.028137 ], + [ 301.083452 , 329.637202 , 8.662175 ], + [ 515.826990 , 565.288233 , 8.749739 ], + [ 684.590231 , 726.481623 , 5.766339 ], + [ 811.675874 , 826.947428 , 1.846738 ], + [ 907.198294 , 908.089329 , 0.098122 ], + [ 979.880266 , 969.342726 , 1.087081 ], + [ 1034.847365 , 1020.253181 , 1.430447 ], + [ 1076.438202 , 1064.021851 , 1.166926 ], + [ 1107.169795 , 1100.814671 , 0.577311 ], + [ 1130.070001 , 1133.431347 , 0.296564 ], + [ 1158.486301 , 1173.896940 , 1.312776 ], + [ 1108.583472 , 1034.952546 , 7.114425 ], + [ 1023.739103 , 893.361764 , 14.594014 ], + [ 926.405670 , 768.766979 , 20.505393 ], + [ 356.263480 , 356.827677 , 0.158115 ], + [ 595.869060 , 617.529617 , 3.507614 ], + [ 780.304180 , 799.855865 , 2.444401 ], + [ 918.734772 , 925.119226 , 0.690122 ], + [ 1023.322212 , 1016.348538 , 0.686150 ], + [ 1102.541547 , 1091.098583 , 1.048756 ], + [ 1162.947248 , 1155.093079 , 0.679960 ], + [ 1208.815882 , 1211.268964 , 0.202522 ], + [ 1243.236271 , 1253.935152 , 0.853224 ], + [ 1268.212772 , 1292.295297 , 1.863547 ], + [ 1299.649410 , 1322.310735 , 1.713767 ], + [ 1243.247078 , 1165.542638 , 6.666804 ], + [ 1147.864983 , 1006.341959 , 14.063115 ], + [ 1037.737231 , 865.928307 , 19.841010 ], + [ 411.077411 , 385.708301 , 6.577279 ], + [ 673.052319 , 670.320845 , 0.407487 ], + [ 872.045789 , 871.766681 , 0.032016 ], + [ 1021.605672 , 1014.726741 , 0.677910 ], + [ 1134.443556 , 1123.647094 , 0.960841 ], + [ 1220.439476 , 1216.562717 , 0.318665 ], + [ 1286.238835 , 1291.521445 , 0.409022 ], + [ 1336.683060 , 1357.265823 , 1.516487 ], + [ 1373.994926 , 1405.905836 , 2.269776 ], + [ 1401.325508 , 1449.385390 , 3.315880 ], + [ 1434.917178 , 1466.233816 , 2.135856 ], + [ 1371.509883 , 1292.197312 , 6.137807 ], + [ 1264.493843 , 1115.647694 , 13.341680 ], + [ 1141.954794 , 960.931878 , 18.838267 ], + [ 464.369070 , 417.340024 , 11.268760 ], + [ 746.924235 , 725.581250 , 2.941502 ], + [ 960.029056 , 944.790788 , 1.612872 ], + [ 1119.892820 , 1104.819384 , 1.364335 ], + [ 1241.112296 , 1233.382877 , 0.626684 ], + [ 1333.761841 , 1339.925477 , 0.459998 ], + [ 1405.131840 , 1430.418237 , 1.767762 ], + [ 1459.286022 , 1504.133035 , 2.981586 ], + [ 1499.614145 , 1558.787332 , 3.796104 ], + [ 1529.026303 , 1603.723695 , 4.657747 ], + [ 1563.609130 , 1617.465612 , 3.329683 ], + [ 1491.509266 , 1414.735272 , 5.426739 ], + [ 1372.969721 , 1221.580427 , 12.392904 ], + [ 1238.265153 , 1052.546538 , 17.644694 ], + [ 697.607256 , 530.230908 , 31.566690 ], + [ 1069.199975 , 947.532306 , 12.840477 ], + [ 1345.044085 , 1275.884477 , 5.420523 ], + [ 1552.898160 , 1525.869310 , 1.771374 ], + [ 1711.010275 , 1711.039174 , 0.001689 ], + [ 1831.352455 , 1869.396149 , 2.035079 ], + [ 1922.088013 , 1996.914758 , 3.747118 ], + [ 1989.466621 , 2097.112670 , 5.133060 ], + [ 2037.854512 , 2165.268099 , 5.884425 ], + [ 2071.221986 , 2214.863774 , 6.485355 ], + [ 2085.093776 , 2210.469050 , 5.671886 ], + [ 1964.177356 , 1958.551506 , 0.287245 ], + [ 1790.799073 , 1696.520335 , 5.557183 ], + [ 1603.204230 , 1464.255987 , 9.489341 ], + [ 880.212905 , 661.437438 , 33.075761 ], + [ 1324.703181 , 1198.312686 , 10.547372 ], + [ 1650.853118 , 1613.025965 , 2.345105 ], + [ 1893.136248 , 1919.256956 , 1.360980 ], + [ 2073.770699 , 2162.521880 , 4.104059 ], + [ 2206.964010 , 2342.159055 , 5.772240 ], + [ 2304.126621 , 2488.030128 , 7.391531 ], + [ 2373.154766 , 2604.805409 , 8.893203 ], + [ 2420.005673 , 2685.680924 , 9.892286 ], + [ 2448.863167 , 2735.089966 , 10.464987 ], + [ 2422.889960 , 2699.275863 , 10.239261 ], + [ 2253.562833 , 2403.016190 , 6.219407 ], + [ 2034.519052 , 2098.532599 , 3.050396 ], + [ 1806.243306 , 1816.122090 , 0.543949 ], + [ 1023.193649 , 776.276975 , 31.807806 ], + [ 1525.146555 , 1409.444747 , 8.209035 ], + [ 1886.122306 , 1904.185866 , 0.948624 ], + [ 2148.130146 , 2251.764495 , 4.602362 ], + [ 2338.190044 , 2542.942445 , 8.051791 ], + [ 2474.348845 , 2745.634809 , 9.880628 ], + [ 2570.187192 , 2901.373100 , 11.414799 ], + [ 2635.146070 , 3027.489893 , 12.959377 ], + [ 2675.747420 , 3100.613536 , 13.702647 ], + [ 2697.190433 , 3157.776542 , 14.585773 ], + [ 2625.390139 , 3097.907042 , 15.252779 ], + [ 2405.414280 , 2785.983861 , 13.660150 ], + [ 2140.334096 , 2435.764543 , 12.128859 ], + [ 1918.911826 , 2120.329248 , 9.499346 ], + [ 1134.844622 , 876.885316 , 29.417679 ], + [ 1679.290415 , 1587.638861 , 5.772821 ], + [ 2062.069732 , 2124.580533 , 2.942266 ], + [ 2333.411719 , 2509.129235 , 7.003127 ], + [ 2525.701359 , 2819.187942 , 10.410323 ], + [ 2659.649760 , 3044.948789 , 12.653711 ], + [ 2750.616462 , 3196.018358 , 13.936150 ], + [ 2808.740074 , 3339.851753 , 15.902253 ], + [ 2841.435455 , 3435.052610 , 17.281166 ], + [ 2854.008165 , 3482.652710 , 18.050739 ], + [ 2726.384653 , 3448.098035 , 20.930767 ], + [ 2458.831616 , 3105.329082 , 20.818968 ], + [ 2239.608440 , 2736.951332 , 18.171419 ], + [ 1972.754114 , 2378.093534 , 17.044722 ] + ] +} diff --git a/InterestCalib/Data/Medium/input.data b/benchmarks/InterestCalib/datasets/medium/input.json similarity index 83% rename from InterestCalib/Data/Medium/input.data rename to benchmarks/InterestCalib/datasets/medium/input.json index 58d5534..0379260 100644 --- a/InterestCalib/Data/Medium/input.data +++ b/benchmarks/InterestCalib/datasets/medium/input.json @@ -1,7 +1,9 @@ -128 // population size -424 // number of iterations of the convergence loop -196 // number of swaption quotes (NUM_SWAP_QUOTES) -[ +{ + "population_size": 128, + "convergence_iterations": 424, + "num_swaption_quotes": 196, + "swaption_quotes": + [ [1.0, 6.0, 1.0, 1.052], [2.0, 6.0, 1.0, 0.81485], [3.0, 6.0, 1.0, 0.6165], @@ -211,33 +213,29 @@ [20.0, 6.0, 30.0, 0.1989], [25.0, 6.0, 30.0, 0.18115], [30.0, 6.0, 30.0, 0.16355] -] // SwaptionQuotes :: REAL[NUM_SWAP_QUOTES,4] - - - -11 // Gauss_DIM: Number of Hermite Coefficients; -[ - 0.0, 0.6568095668820999044613, -0.6568095668820997934390, - -1.3265570844949334805563, 1.3265570844949330364670, 2.0259480158257567872226, - -2.0259480158257558990442, -2.7832900997816496513337, 2.7832900997816474308877, - 3.6684708465595856630159, -3.6684708465595838866591 -] // GaussHermiteCoefs::coefs[Gauss_DIM] - -[ - 0.6547592869145917315876, 0.6609604194409607336169, 0.6609604194409606225946, - 0.6812118810666693002887, 0.6812118810666689672217, 0.7219536247283847574252, - 0.7219536247283852015144, 0.8025168688510405656800, 0.8025168688510396775015, - 1.0065267861723647957461, 1.0065267861723774522886 -] // GaussHermiteCoefs::weights[Gauss_DIM] - - - -30 // SOBOL_BITS_NUM -[ 536870912, 268435456, 134217728, 67108864, 33554432, - 16777216, 8388608, 4194304, 2097152, 1048576, - 524288, 262144, 131072, 65536, 32768, - 16384, 8192, 4096, 2048, 1024, - 512, 256, 128, 64, 32, - 16, 8, 4, 2, 1 -] // SOBOL_DIR_VCT == Sobol Direction Vectors REAL[SOBOL_BITS_NUM] - + ], + + "num_hermite_coefficients": 11, + "hermite_coefficients": + [ 0.0, 0.6568095668820999044613, -0.6568095668820997934390, + -1.3265570844949334805563, 1.3265570844949330364670, 2.0259480158257567872226, + -2.0259480158257558990442, -2.7832900997816496513337, 2.7832900997816474308877, + 3.6684708465595856630159, -3.6684708465595838866591 + ], + "hermite_coefficient_weights": + [ + 0.6547592869145917315876, 0.6609604194409607336169, 0.6609604194409606225946, + 0.6812118810666693002887, 0.6812118810666689672217, 0.7219536247283847574252, + 0.7219536247283852015144, 0.8025168688510405656800, 0.8025168688510396775015, + 1.0065267861723647957461, 1.0065267861723774522886 + ], + "sobol_num_bits": 30, + "sobol_dir_vs": + [ 536870912, 268435456, 134217728, 67108864, 33554432, + 16777216, 8388608, 4194304, 2097152, 1048576, + 524288, 262144, 131072, 65536, 32768, + 16384, 8192, 4096, 2048, 1024, + 512, 256, 128, 64, 32, + 16, 8, 4, 2, 1 + ] +} diff --git a/benchmarks/InterestCalib/datasets/medium/output.json b/benchmarks/InterestCalib/datasets/medium/output.json new file mode 100644 index 0000000..54af5f1 --- /dev/null +++ b/benchmarks/InterestCalib/datasets/medium/output.json @@ -0,0 +1,208 @@ +{ + "a_field": 0.023511, + "b_field": 0.964110, + "sigma_field": 0.025390, + "nu_field": 0.142763, + "rho_field": -0.912444, + "lg_likelyhood": 504.367344, + + "swaption_calibration_result": + [ + [ 157.397565 , 115.320470 , 36.487100 ], + [ 158.760952 , 162.945479 , 2.568054 ], + [ 165.097976 , 174.297729 , 5.278183 ], + [ 175.510974 , 171.631308 , 2.260465 ], + [ 185.096581 , 168.408756 , 9.909120 ], + [ 193.322704 , 168.310831 , 14.860525 ], + [ 199.745999 , 169.877089 , 17.582659 ], + [ 204.980646 , 172.511293 , 18.821581 ], + [ 207.965455 , 172.824865 , 20.333063 ], + [ 210.211604 , 172.561368 , 21.818462 ], + [ 209.496752 , 177.275607 , 18.175735 ], + [ 198.058665 , 161.933876 , 22.308358 ], + [ 180.931070 , 139.430038 , 29.764772 ], + [ 162.740296 , 120.029132 , 35.583998 ], + [ 180.828953 , 136.735565 , 32.247198 ], + [ 197.570095 , 228.603138 , 13.575073 ], + [ 231.652896 , 275.866189 , 16.027079 ], + [ 267.035700 , 293.303444 , 8.955825 ], + [ 296.574053 , 305.655752 , 2.971218 ], + [ 320.041550 , 313.896508 , 1.957665 ], + [ 338.547315 , 323.484107 , 4.656553 ], + [ 352.372052 , 330.054072 , 6.761916 ], + [ 362.299599 , 335.261016 , 8.064935 ], + [ 369.752884 , 335.769411 , 10.121075 ], + [ 379.269057 , 354.321026 , 7.041081 ], + [ 362.343709 , 318.366856 , 13.813264 ], + [ 333.799298 , 274.710927 , 21.509290 ], + [ 301.589807 , 236.227803 , 27.669057 ], + [ 172.210684 , 192.203184 , 10.401753 ], + [ 227.955695 , 306.754568 , 25.687922 ], + [ 299.934061 , 377.675217 , 20.584129 ], + [ 362.136697 , 412.847194 , 12.283115 ], + [ 410.791383 , 436.793689 , 5.952995 ], + [ 448.676865 , 457.418930 , 1.911173 ], + [ 477.384722 , 472.046625 , 1.130841 ], + [ 499.183038 , 483.257228 , 3.295514 ], + [ 515.122617 , 491.981354 , 4.703687 ], + [ 527.462746 , 496.017051 , 6.339640 ], + [ 543.860701 , 526.391523 , 3.318666 ], + [ 520.875868 , 470.271579 , 10.760652 ], + [ 480.620983 , 406.010507 , 18.376489 ], + [ 434.912156 , 349.521869 , 24.430599 ], + [ 175.817605 , 234.956228 , 25.170060 ], + [ 281.983907 , 379.997542 , 25.793229 ], + [ 386.986699 , 470.343801 , 17.722590 ], + [ 470.710384 , 525.541048 , 10.433184 ], + [ 534.924952 , 566.158092 , 5.516682 ], + [ 583.629049 , 592.597274 , 1.513376 ], + [ 620.647894 , 612.901965 , 1.263812 ], + [ 648.638703 , 631.047390 , 2.787637 ], + [ 669.568744 , 645.427184 , 3.740400 ], + [ 684.736202 , 654.142965 , 4.676843 ], + [ 704.954513 , 694.837660 , 1.456002 ], + [ 674.726162 , 617.784741 , 9.217033 ], + [ 622.980296 , 533.755298 , 16.716461 ], + [ 563.277986 , 459.106740 , 22.689984 ], + [ 203.693343 , 276.585395 , 26.354266 ], + [ 354.131456 , 452.559843 , 21.749253 ], + [ 484.673742 , 563.065703 , 13.922347 ], + [ 585.697217 , 634.734726 , 7.725670 ], + [ 661.769994 , 685.829366 , 3.508070 ], + [ 719.413650 , 722.893858 , 0.481427 ], + [ 763.082942 , 749.627445 , 1.794958 ], + [ 796.409044 , 777.716103 , 2.403569 ], + [ 820.552620 , 793.738233 , 3.378241 ], + [ 838.266809 , 814.271603 , 2.946831 ], + [ 860.928096 , 858.501503 , 0.282654 ], + [ 824.031243 , 761.317980 , 8.237460 ], + [ 760.549282 , 657.575731 , 15.659573 ], + [ 687.849618 , 565.396155 , 21.657994 ], + [ 248.505950 , 302.881789 , 17.952826 ], + [ 434.064679 , 507.004879 , 14.386489 ], + [ 585.500618 , 646.006214 , 9.366101 ], + [ 700.296189 , 732.520960 , 4.399160 ], + [ 786.607031 , 799.352396 , 1.594461 ], + [ 851.884344 , 846.847045 , 0.594830 ], + [ 901.714482 , 886.814283 , 1.680194 ], + [ 939.036181 , 919.813612 , 2.089833 ], + [ 966.478792 , 947.705019 , 1.980972 ], + [ 986.566873 , 973.538216 , 1.338279 ], + [ 1012.284446 , 1018.774022 , 0.636999 ], + [ 968.529570 , 900.113746 , 7.600798 ], + [ 894.291386 , 777.120699 , 15.077540 ], + [ 809.047014 , 668.478449 , 21.028137 ], + [ 301.083452 , 329.637202 , 8.662175 ], + [ 515.826990 , 565.288233 , 8.749739 ], + [ 684.590231 , 726.481623 , 5.766339 ], + [ 811.675874 , 826.947428 , 1.846738 ], + [ 907.198294 , 908.089329 , 0.098122 ], + [ 979.880266 , 969.342726 , 1.087081 ], + [ 1034.847365 , 1020.253181 , 1.430447 ], + [ 1076.438202 , 1064.021851 , 1.166926 ], + [ 1107.169795 , 1100.814671 , 0.577311 ], + [ 1130.070001 , 1133.431347 , 0.296564 ], + [ 1158.486301 , 1173.896940 , 1.312776 ], + [ 1108.583472 , 1034.952546 , 7.114425 ], + [ 1023.739103 , 893.361764 , 14.594014 ], + [ 926.405670 , 768.766979 , 20.505393 ], + [ 356.263480 , 356.827677 , 0.158115 ], + [ 595.869060 , 617.529617 , 3.507614 ], + [ 780.304180 , 799.855865 , 2.444401 ], + [ 918.734772 , 925.119226 , 0.690122 ], + [ 1023.322212 , 1016.348538 , 0.686150 ], + [ 1102.541547 , 1091.098583 , 1.048756 ], + [ 1162.947248 , 1155.093079 , 0.679960 ], + [ 1208.815882 , 1211.268964 , 0.202522 ], + [ 1243.236271 , 1253.935152 , 0.853224 ], + [ 1268.212772 , 1292.295297 , 1.863547 ], + [ 1299.649410 , 1322.310735 , 1.713767 ], + [ 1243.247078 , 1165.542638 , 6.666804 ], + [ 1147.864983 , 1006.341959 , 14.063115 ], + [ 1037.737231 , 865.928307 , 19.841010 ], + [ 411.077411 , 385.708301 , 6.577279 ], + [ 673.052319 , 670.320845 , 0.407487 ], + [ 872.045789 , 871.766681 , 0.032016 ], + [ 1021.605672 , 1014.726741 , 0.677910 ], + [ 1134.443556 , 1123.647094 , 0.960841 ], + [ 1220.439476 , 1216.562717 , 0.318665 ], + [ 1286.238835 , 1291.521445 , 0.409022 ], + [ 1336.683060 , 1357.265823 , 1.516487 ], + [ 1373.994926 , 1405.905836 , 2.269776 ], + [ 1401.325508 , 1449.385390 , 3.315880 ], + [ 1434.917178 , 1466.233816 , 2.135856 ], + [ 1371.509883 , 1292.197312 , 6.137807 ], + [ 1264.493843 , 1115.647694 , 13.341680 ], + [ 1141.954794 , 960.931878 , 18.838267 ], + [ 464.369070 , 417.340024 , 11.268760 ], + [ 746.924235 , 725.581250 , 2.941502 ], + [ 960.029056 , 944.790788 , 1.612872 ], + [ 1119.892820 , 1104.819384 , 1.364335 ], + [ 1241.112296 , 1233.382877 , 0.626684 ], + [ 1333.761841 , 1339.925477 , 0.459998 ], + [ 1405.131840 , 1430.418237 , 1.767762 ], + [ 1459.286022 , 1504.133035 , 2.981586 ], + [ 1499.614145 , 1558.787332 , 3.796104 ], + [ 1529.026303 , 1603.723695 , 4.657747 ], + [ 1563.609130 , 1617.465612 , 3.329683 ], + [ 1491.509266 , 1414.735272 , 5.426739 ], + [ 1372.969721 , 1221.580427 , 12.392904 ], + [ 1238.265153 , 1052.546538 , 17.644694 ], + [ 697.607256 , 530.230908 , 31.566690 ], + [ 1069.199975 , 947.532306 , 12.840477 ], + [ 1345.044085 , 1275.884477 , 5.420523 ], + [ 1552.898160 , 1525.869310 , 1.771374 ], + [ 1711.010275 , 1711.039174 , 0.001689 ], + [ 1831.352455 , 1869.396149 , 2.035079 ], + [ 1922.088013 , 1996.914758 , 3.747118 ], + [ 1989.466621 , 2097.112670 , 5.133060 ], + [ 2037.854512 , 2165.268099 , 5.884425 ], + [ 2071.221986 , 2214.863774 , 6.485355 ], + [ 2085.093776 , 2210.469050 , 5.671886 ], + [ 1964.177356 , 1958.551506 , 0.287245 ], + [ 1790.799073 , 1696.520335 , 5.557183 ], + [ 1603.204230 , 1464.255987 , 9.489341 ], + [ 880.212905 , 661.437438 , 33.075761 ], + [ 1324.703181 , 1198.312686 , 10.547372 ], + [ 1650.853118 , 1613.025965 , 2.345105 ], + [ 1893.136248 , 1919.256956 , 1.360980 ], + [ 2073.770699 , 2162.521880 , 4.104059 ], + [ 2206.964010 , 2342.159055 , 5.772240 ], + [ 2304.126621 , 2488.030128 , 7.391531 ], + [ 2373.154766 , 2604.805409 , 8.893203 ], + [ 2420.005673 , 2685.680924 , 9.892286 ], + [ 2448.863167 , 2735.089966 , 10.464987 ], + [ 2422.889960 , 2699.275863 , 10.239261 ], + [ 2253.562833 , 2403.016190 , 6.219407 ], + [ 2034.519052 , 2098.532599 , 3.050396 ], + [ 1806.243306 , 1816.122090 , 0.543949 ], + [ 1023.193649 , 776.276975 , 31.807806 ], + [ 1525.146555 , 1409.444747 , 8.209035 ], + [ 1886.122306 , 1904.185866 , 0.948624 ], + [ 2148.130146 , 2251.764495 , 4.602362 ], + [ 2338.190044 , 2542.942445 , 8.051791 ], + [ 2474.348845 , 2745.634809 , 9.880628 ], + [ 2570.187192 , 2901.373100 , 11.414799 ], + [ 2635.146070 , 3027.489893 , 12.959377 ], + [ 2675.747420 , 3100.613536 , 13.702647 ], + [ 2697.190433 , 3157.776542 , 14.585773 ], + [ 2625.390139 , 3097.907042 , 15.252779 ], + [ 2405.414280 , 2785.983861 , 13.660150 ], + [ 2140.334096 , 2435.764543 , 12.128859 ], + [ 1918.911826 , 2120.329248 , 9.499346 ], + [ 1134.844622 , 876.885316 , 29.417679 ], + [ 1679.290415 , 1587.638861 , 5.772821 ], + [ 2062.069732 , 2124.580533 , 2.942266 ], + [ 2333.411719 , 2509.129235 , 7.003127 ], + [ 2525.701359 , 2819.187942 , 10.410323 ], + [ 2659.649760 , 3044.948789 , 12.653711 ], + [ 2750.616462 , 3196.018358 , 13.936150 ], + [ 2808.740074 , 3339.851753 , 15.902253 ], + [ 2841.435455 , 3435.052610 , 17.281166 ], + [ 2854.008165 , 3482.652710 , 18.050739 ], + [ 2726.384653 , 3448.098035 , 20.930767 ], + [ 2458.831616 , 3105.329082 , 20.818968 ], + [ 2239.608440 , 2736.951332 , 18.171419 ], + [ 1972.754114 , 2378.093534 , 17.044722 ] + ] +} diff --git a/InterestCalib/Data/Small/input.data b/benchmarks/InterestCalib/datasets/small/input.json similarity index 83% rename from InterestCalib/Data/Small/input.data rename to benchmarks/InterestCalib/datasets/small/input.json index 43c8491..a51aabb 100644 --- a/InterestCalib/Data/Small/input.data +++ b/benchmarks/InterestCalib/datasets/small/input.json @@ -1,7 +1,9 @@ -256 // population size -128 // number of iterations of the convergence loop -196 // number of swaption quotes (NUM_SWAP_QUOTES) -[ +{ + "population_size" : 256, + "convergence_iterations": 128, + "num_swaption_quotes": 196, + "swaption_quotes": + [ [1.0, 6.0, 1.0, 1.052], [2.0, 6.0, 1.0, 0.81485], [3.0, 6.0, 1.0, 0.6165], @@ -211,33 +213,29 @@ [20.0, 6.0, 30.0, 0.1989], [25.0, 6.0, 30.0, 0.18115], [30.0, 6.0, 30.0, 0.16355] -] // SwaptionQuotes :: REAL[NUM_SWAP_QUOTES,4] - - - -11 // Gauss_DIM: Number of Hermite Coefficients; -[ - 0.0, 0.6568095668820999044613, -0.6568095668820997934390, - -1.3265570844949334805563, 1.3265570844949330364670, 2.0259480158257567872226, - -2.0259480158257558990442, -2.7832900997816496513337, 2.7832900997816474308877, - 3.6684708465595856630159, -3.6684708465595838866591 -] // GaussHermiteCoefs::coefs[Gauss_DIM] - -[ - 0.6547592869145917315876, 0.6609604194409607336169, 0.6609604194409606225946, - 0.6812118810666693002887, 0.6812118810666689672217, 0.7219536247283847574252, - 0.7219536247283852015144, 0.8025168688510405656800, 0.8025168688510396775015, - 1.0065267861723647957461, 1.0065267861723774522886 -] // GaussHermiteCoefs::weights[Gauss_DIM] - - - -30 // SOBOL_BITS_NUM -[ 536870912, 268435456, 134217728, 67108864, 33554432, - 16777216, 8388608, 4194304, 2097152, 1048576, - 524288, 262144, 131072, 65536, 32768, - 16384, 8192, 4096, 2048, 1024, - 512, 256, 128, 64, 32, - 16, 8, 4, 2, 1 -] // SOBOL_DIR_VCT == Sobol Direction Vectors REAL[SOBOL_BITS_NUM] - + ], + + "num_hermite_coefficients": 11, + "hermite_coefficients": + [ 0.0, 0.6568095668820999044613, -0.6568095668820997934390, + -1.3265570844949334805563, 1.3265570844949330364670, 2.0259480158257567872226, + -2.0259480158257558990442, -2.7832900997816496513337, 2.7832900997816474308877, + 3.6684708465595856630159, -3.6684708465595838866591 + ], + "hermite_coefficient_weights": + [ + 0.6547592869145917315876, 0.6609604194409607336169, 0.6609604194409606225946, + 0.6812118810666693002887, 0.6812118810666689672217, 0.7219536247283847574252, + 0.7219536247283852015144, 0.8025168688510405656800, 0.8025168688510396775015, + 1.0065267861723647957461, 1.0065267861723774522886 + ], + "sobol_num_bits": 30, + "sobol_dir_vs": + [ 536870912, 268435456, 134217728, 67108864, 33554432, + 16777216, 8388608, 4194304, 2097152, 1048576, + 524288, 262144, 131072, 65536, 32768, + 16384, 8192, 4096, 2048, 1024, + 512, 256, 128, 64, 32, + 16, 8, 4, 2, 1 + ] +} diff --git a/benchmarks/InterestCalib/datasets/small/output.json b/benchmarks/InterestCalib/datasets/small/output.json new file mode 100644 index 0000000..c21426d --- /dev/null +++ b/benchmarks/InterestCalib/datasets/small/output.json @@ -0,0 +1,207 @@ +{ + "a_field": 0.325608, + "b_field": 0.001000, + "sigma_field": 0.009058, + "nu_field": 0.018683, + "rho_field": -0.083963, + "lg_likelyhood": 624.116935, + "swaption_calibration_result": + [ + [ 74.172585 , 115.320470 , 35.681337 ], + [ 100.626570 , 162.945479 , 38.245252 ], + [ 118.719023 , 174.297729 , 31.887223 ], + [ 132.735321 , 171.631308 , 22.662524 ], + [ 143.164628 , 168.408756 , 14.989796 ], + [ 151.813418 , 168.310831 , 9.801754 ], + [ 158.832697 , 169.877089 , 6.501402 ], + [ 164.984854 , 172.511293 , 4.362868 ], + [ 169.170571 , 172.824865 , 2.114449 ], + [ 172.872471 , 172.561368 , 0.180286 ], + [ 181.530751 , 177.275607 , 2.400298 ], + [ 180.340962 , 161.933876 , 11.367038 ], + [ 172.565436 , 139.430038 , 23.764892 ], + [ 162.247156 , 120.029132 , 35.173148 ], + [ 74.172585 , 69.393222 , 6.887362 ], + [ 100.626570 , 116.015964 , 13.264894 ], + [ 118.719023 , 139.816103 , 15.089163 ], + [ 132.735321 , 149.054929 , 10.948721 ], + [ 143.164628 , 155.120122 , 7.707249 ], + [ 151.813418 , 159.302301 , 4.701052 ], + [ 158.832697 , 163.950093 , 3.121313 ], + [ 164.984854 , 167.731363 , 1.637445 ], + [ 169.170571 , 170.144777 , 0.572575 ], + [ 172.872471 , 170.402787 , 1.449321 ], + [ 181.530751 , 179.579039 , 1.086827 ], + [ 180.340962 , 161.791994 , 11.464700 ], + [ 172.565436 , 139.415641 , 23.777673 ], + [ 162.247156 , 119.885477 , 35.335121 ], + [ 74.172585 , 65.999080 , 12.384271 ], + [ 100.626570 , 105.242095 , 4.385626 ], + [ 118.719023 , 129.573722 , 8.377237 ], + [ 132.735321 , 142.022857 , 6.539466 ], + [ 143.164628 , 149.987013 , 4.548651 ], + [ 151.813418 , 156.932387 , 3.261895 ], + [ 158.832697 , 161.950891 , 1.925395 ], + [ 164.984854 , 166.244493 , 0.757703 ], + [ 169.170571 , 168.937454 , 0.137990 ], + [ 172.872471 , 170.174723 , 1.585282 ], + [ 181.530751 , 180.595670 , 0.517776 ], + [ 180.340962 , 161.777322 , 11.474810 ], + [ 172.565436 , 139.416628 , 23.776797 ], + [ 162.247156 , 119.914803 , 35.302024 ], + [ 74.172585 , 61.368583 , 20.864099 ], + [ 100.626570 , 99.252149 , 1.384777 ], + [ 118.719023 , 122.849829 , 3.362484 ], + [ 132.735321 , 137.637329 , 3.561540 ], + [ 143.164628 , 147.875713 , 3.185841 ], + [ 151.813418 , 154.781404 , 1.917534 ], + [ 158.832697 , 160.084818 , 0.782161 ], + [ 164.984854 , 165.269065 , 0.171969 ], + [ 169.170571 , 168.580130 , 0.350243 ], + [ 172.872471 , 170.856618 , 1.179851 ], + [ 181.530751 , 181.485729 , 0.024807 ], + [ 180.340962 , 161.795624 , 11.462200 ], + [ 172.565436 , 139.412376 , 23.780571 ], + [ 162.247156 , 119.914803 , 35.302024 ], + [ 74.172585 , 58.655078 , 26.455521 ], + [ 100.626570 , 95.973733 , 4.848031 ], + [ 118.719023 , 119.408556 , 0.577457 ], + [ 132.735321 , 134.902103 , 1.606189 ], + [ 143.164628 , 145.442875 , 1.566421 ], + [ 151.813418 , 153.303090 , 0.971717 ], + [ 158.832697 , 158.972444 , 0.087907 ], + [ 164.984854 , 165.290371 , 0.184837 ], + [ 169.170571 , 168.326957 , 0.501176 ], + [ 172.872471 , 172.681440 , 0.110626 ], + [ 181.530751 , 182.061213 , 0.291365 ], + [ 180.340962 , 161.805228 , 11.455584 ], + [ 172.565436 , 139.451166 , 23.746141 ], + [ 162.247156 , 119.902772 , 35.315600 ], + [ 74.172585 , 54.317928 , 36.552677 ], + [ 100.626570 , 90.924762 , 10.670150 ], + [ 118.719023 , 115.804615 , 2.516660 ], + [ 132.735321 , 131.667834 , 0.810742 ], + [ 143.164628 , 143.353504 , 0.131756 ], + [ 151.813418 , 151.871055 , 0.037951 ], + [ 158.832697 , 158.972444 , 0.087907 ], + [ 164.984854 , 165.332970 , 0.210555 ], + [ 169.170571 , 169.958627 , 0.463675 ], + [ 172.872471 , 174.591476 , 0.984587 ], + [ 181.530751 , 182.627862 , 0.600736 ], + [ 180.340962 , 161.791994 , 11.464700 ], + [ 172.565436 , 139.366537 , 23.821284 ], + [ 162.247156 , 119.882956 , 35.337967 ], + [ 74.172585 , 51.415081 , 44.262312 ], + [ 100.626570 , 88.139705 , 14.167127 ], + [ 118.719023 , 113.272969 , 4.807903 ], + [ 132.735321 , 129.285558 , 2.668328 ], + [ 143.164628 , 141.639008 , 1.077118 ], + [ 151.813418 , 151.139856 , 0.445654 ], + [ 158.832697 , 159.077811 , 0.154085 ], + [ 164.984854 , 166.349944 , 0.820614 ], + [ 169.170571 , 171.699296 , 1.472764 ], + [ 172.872471 , 176.724544 , 2.179704 ], + [ 181.530751 , 183.033936 , 0.821260 ], + [ 180.340962 , 161.805228 , 11.455584 ], + [ 172.565436 , 139.341880 , 23.843195 ], + [ 162.247156 , 119.866098 , 35.357001 ], + [ 74.172585 , 49.394757 , 50.162869 ], + [ 100.626570 , 85.483070 , 17.715203 ], + [ 118.719023 , 110.722034 , 7.222582 ], + [ 132.735321 , 128.407529 , 3.370356 ], + [ 143.164628 , 140.690570 , 1.758510 ], + [ 151.813418 , 151.038030 , 0.513372 ], + [ 158.832697 , 159.896627 , 0.665386 ], + [ 164.984854 , 168.125416 , 1.867988 ], + [ 169.170571 , 173.579086 , 2.539774 ], + [ 172.872471 , 178.889185 , 3.363375 ], + [ 181.530751 , 183.044146 , 0.826792 ], + [ 180.340962 , 161.778554 , 11.473961 ], + [ 172.565436 , 139.305384 , 23.875640 ], + [ 162.247156 , 119.868276 , 35.354542 ], + [ 74.172585 , 48.150355 , 54.043693 ], + [ 100.626570 , 83.680300 , 20.251205 ], + [ 118.719023 , 108.828031 , 9.088644 ], + [ 132.735321 , 126.982834 , 4.530130 ], + [ 143.164628 , 140.271822 , 2.062285 ], + [ 151.813418 , 151.871055 , 0.037951 ], + [ 158.832697 , 161.228617 , 1.486039 ], + [ 164.984854 , 169.848150 , 2.863320 ], + [ 169.170571 , 175.507928 , 3.610867 ], + [ 172.872471 , 180.935750 , 4.456432 ], + [ 181.530751 , 183.039043 , 0.824028 ], + [ 180.340962 , 161.705481 , 11.524334 ], + [ 172.565436 , 139.273208 , 23.904259 ], + [ 162.247156 , 119.959075 , 35.252090 ], + [ 74.172585 , 47.566884 , 55.933243 ], + [ 100.626570 , 82.699087 , 21.677969 ], + [ 118.719023 , 107.658511 , 10.273700 ], + [ 132.735321 , 126.233454 , 5.150669 ], + [ 143.164628 , 140.576453 , 1.841116 ], + [ 151.813418 , 152.719787 , 0.593485 ], + [ 158.832697 , 162.995553 , 2.553969 ], + [ 164.984854 , 171.857872 , 3.999246 ], + [ 169.170571 , 177.664858 , 4.781073 ], + [ 172.872471 , 182.786539 , 5.423850 ], + [ 181.530751 , 184.309522 , 1.507666 ], + [ 180.340962 , 161.643543 , 11.567068 ], + [ 172.565436 , 139.231253 , 23.941595 ], + [ 162.247156 , 119.965390 , 35.244969 ], + [ 74.172585 , 43.226030 , 71.592407 ], + [ 100.626570 , 77.234542 , 30.287003 ], + [ 118.719023 , 103.998937 , 14.154074 ], + [ 132.735321 , 124.711169 , 6.434189 ], + [ 143.164628 , 139.489096 , 2.634995 ], + [ 151.813418 , 152.376815 , 0.369740 ], + [ 158.832697 , 162.771016 , 2.419546 ], + [ 164.984854 , 171.399588 , 3.742561 ], + [ 169.170571 , 176.519214 , 4.163084 ], + [ 172.872471 , 180.536313 , 4.245041 ], + [ 181.530751 , 180.178093 , 0.750734 ], + [ 180.340962 , 160.074815 , 12.660422 ], + [ 172.565436 , 138.305476 , 24.771224 ], + [ 162.247156 , 119.353334 , 35.938520 ], + [ 74.172585 , 43.304897 , 71.279901 ], + [ 100.626570 , 78.454597 , 28.260897 ], + [ 118.719023 , 105.606244 , 12.416671 ], + [ 132.735321 , 125.994568 , 5.350034 ], + [ 143.164628 , 141.582230 , 1.117653 ], + [ 151.813418 , 153.343235 , 0.997643 ], + [ 158.832697 , 162.893544 , 2.492946 ], + [ 164.984854 , 170.999163 , 3.517157 ], + [ 169.170571 , 175.833917 , 3.789568 ], + [ 172.872471 , 179.068771 , 3.460291 ], + [ 181.530751 , 176.723990 , 2.719926 ], + [ 180.340962 , 157.752190 , 14.319149 ], + [ 172.565436 , 137.392795 , 25.600062 ], + [ 162.247156 , 118.903128 , 36.453228 ], + [ 74.172585 , 43.462616 , 70.658354 ], + [ 100.626570 , 78.912756 , 27.516228 ], + [ 118.719023 , 106.612590 , 11.355539 ], + [ 132.735321 , 126.403955 , 5.008836 ], + [ 143.164628 , 142.375639 , 0.554160 ], + [ 151.813418 , 153.724089 , 1.242923 ], + [ 158.832697 , 162.443649 , 2.222895 ], + [ 164.984854 , 169.949698 , 2.921361 ], + [ 169.170571 , 173.598830 , 2.550858 ], + [ 172.872471 , 176.799304 , 2.221068 ], + [ 181.530751 , 173.447298 , 4.660467 ], + [ 180.340962 , 156.392633 , 15.312952 ], + [ 172.565436 , 136.374905 , 26.537530 ], + [ 162.247156 , 118.714142 , 36.670453 ], + [ 1403.330455 , 876.885316 , 60.035803 ], + [ 1901.397958 , 1587.638861 , 19.762624 ], + [ 2232.562804 , 2124.580533 , 5.082522 ], + [ 2471.970560 , 2509.129235 , 1.480939 ], + [ 2650.891041 , 2819.187942 , 5.969694 ], + [ 2785.299006 , 3044.948789 , 8.527230 ], + [ 2886.144180 , 3196.018358 , 9.695632 ], + [ 2960.257561 , 3339.851753 , 11.365600 ], + [ 3012.875689 , 3435.052610 , 12.290261 ], + [ 3047.821242 , 3482.652710 , 12.485640 ], + [ 3044.984927 , 3448.098035 , 11.690883 ], + [ 2877.611282 , 3105.329082 , 7.333129 ], + [ 2641.365086 , 2736.951332 , 3.492435 ], + [ 2382.949281 , 2378.093534 , 0.204187 ] + ] +} diff --git a/InterestCalib/CppOpenCL/FindBestKer.h b/benchmarks/InterestCalib/implementations/cpp_opencl/FindBestKer.h similarity index 97% rename from InterestCalib/CppOpenCL/FindBestKer.h rename to benchmarks/InterestCalib/implementations/cpp_opencl/FindBestKer.h index 084157d..acd8124 100644 --- a/InterestCalib/CppOpenCL/FindBestKer.h +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/FindBestKer.h @@ -59,7 +59,7 @@ class FindBestKer { clReleaseKernel(ker2); } - void run ( int& best_ind, REAL& best_val ) { + void run ( int& best_ind, real_t& best_val ) { cl_int ciErr1; //printf("Before run kernel 1 (LWG,GWG,UNROLL): (%ld,%ld,%d)\n", LWG, GWG, UNROLL); @@ -87,7 +87,7 @@ class FindBestKer { { // Finally, read-back the histogram result! ciErr1 |= clEnqueueReadBuffer ( ocl.getCommandQueue(), res_val, CL_TRUE, 0, - sizeof(REAL), &best_val, 0, NULL, NULL + sizeof(real_t), &best_val, 0, NULL, NULL ); ciErr1 |= clEnqueueReadBuffer ( ocl.getCommandQueue(), res_ind, CL_TRUE, 0, diff --git a/InterestCalib/CppOpenCL/GenAlgFlat.h b/benchmarks/InterestCalib/implementations/cpp_opencl/GenAlgFlat.h similarity index 88% rename from InterestCalib/CppOpenCL/GenAlgFlat.h rename to benchmarks/InterestCalib/implementations/cpp_opencl/GenAlgFlat.h index 79b0b35..c7d0d62 100644 --- a/InterestCalib/CppOpenCL/GenAlgFlat.h +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/GenAlgFlat.h @@ -15,14 +15,14 @@ /** * Printing Swaption / Calibrated Price / Black Price / RMS - * The result is an array REAL[NUM_SWAP_QUOTES, 3] recording + * The result is an array real_t[NUM_SWAP_QUOTES, 3] recording * for each swaption the calibrated price, the black price * and the percentagewise difference between the two. */ -REAL* makeSummary(uint winner, CpuArrays& arrs) { - REAL* res = (REAL*) malloc( 3*NUM_SWAP_QUOTES*sizeof(REAL) ); +real_t* makeSummary(uint winner, CpuArrays& arrs) { + real_t* res = (real_t*) malloc( 3*NUM_SWAP_QUOTES*sizeof(real_t) ); - REAL rms = 0.0; + real_t rms = 0.0; fprintf(stderr, "\n\nCALIBRATION RESULT: best genome is at index %d: ", winner); fprintf(stderr, "{ a = %f, b = %f, sigma = %f, nu = %f, rho = %f }, Likelihood: %f!\n", @@ -31,9 +31,9 @@ REAL* makeSummary(uint winner, CpuArrays& arrs) { fprintf(stderr, "\nPer-Swaption Approximation w.r.t. Black Price:\n\n"); for( int i = 0; i < NUM_SWAP_QUOTES; i ++ ) { - REAL black_price = arrs.get_quote(winner)[i]; - REAL calib_price = arrs.get_price(winner)[i]; - REAL err_ratio = (calib_price - black_price) / black_price; + real_t black_price = arrs.get_quote(winner)[i]; + real_t calib_price = arrs.get_price(winner)[i]; + real_t err_ratio = (calib_price - black_price) / black_price; res[3*i + 0] = 10000.0*calib_price; res[3*i + 1] = 10000.0*black_price; @@ -58,7 +58,7 @@ REAL* makeSummary(uint winner, CpuArrays& arrs) { * scans the logLik array and fill in the index and likelihood * of the best genome. */ -void find_best(const REAL* logLik, int& best_ind, REAL& best_lik) { +void find_best(const real_t* logLik, int& best_ind, real_t& best_lik) { bool sanity = true; best_lik = -INFINITY; @@ -67,7 +67,7 @@ void find_best(const REAL* logLik, int& best_ind, REAL& best_lik) { // this is in fact a reduction, but POP_SIZE is // not big enough to warrant a parallel execution. for ( UINT i = 0; i < POP_SIZE; i++ ) { // parallel reduction with MAX - REAL val = logLik[i]; + real_t val = logLik[i]; sanity = !( isnan(val) || isinf(val) ); assert( sanity && "val is NaN in find_best" ); @@ -78,8 +78,8 @@ void find_best(const REAL* logLik, int& best_ind, REAL& best_lik) { void find_best_GPU( FindBestKer& bestker, OclObjects& ocl_objs, - OclBuffers& ocl_arrs, const REAL* logLik, - int& best_ind, REAL& best_lik + OclBuffers& ocl_arrs, const real_t* logLik, + int& best_ind, real_t& best_lik ) { bool sanity = true; @@ -89,10 +89,10 @@ void find_best_GPU( assert( sanity && "val is NaN in find_best" ); } -Move_Type selectMoveType(REAL move_selected) { +Move_Type selectMoveType(real_t move_selected) { Move_Type move_type = NONE; - REAL prob; + real_t prob; Move_Type type; UINT k = 0; do { @@ -119,19 +119,19 @@ Move_Type selectMoveType(REAL move_selected) { * price, the black price and the percentage * difference between the two. */ -REAL* mainKernelGPU(REAL& wg_a, - REAL& wg_b, - REAL& wg_sigma, - REAL& wg_nu, - REAL& wg_rho, - REAL& wg_logLik +real_t* mainKernelGPU(real_t& wg_a, + real_t& wg_b, + real_t& wg_sigma, + real_t& wg_nu, + real_t& wg_rho, + real_t& wg_logLik ) { uint FLAT_SZ; short* shape = getIregShapeAdjusted( LWG_EG, FLAT_SZ ); int * start_inds = getStartInd( FLAT_SZ, shape, NUM_SWAP_QUOTES ); CpuArrays cpu_arrs(FLAT_SZ, shape); - REAL *g_a, *g_b, *g_rho, *g_nu, *g_sigma, *logLik, *bf_rat; + real_t *g_a, *g_b, *g_rho, *g_nu, *g_sigma, *logLik, *bf_rat; { // getting the cpu arrays g_a = cpu_arrs.get_a (); g_b = cpu_arrs.get_b (); @@ -162,7 +162,7 @@ REAL* mainKernelGPU(REAL& wg_a, #else for( int i = 0; i < POP_SIZE; i++ ) { - REAL r01, tmp; + real_t r01, tmp; r01 = getRandRandNorm(); tmp = r01 * ( g_maxs[0] - g_mins[0]) + g_mins[0]; @@ -215,7 +215,7 @@ REAL* mainKernelGPU(REAL& wg_a, // select which move to perform: BEGIN // Note: this block can also be a loop (in fixed order) // over the various move types - REAL move_selected = getRandUnifNorm(); + real_t move_selected = getRandUnifNorm(); Move_Type move_type = selectMoveType(move_selected); #if ( GPU_VERSION == 2 && WITH_SOBOL == 0 ) @@ -273,11 +273,11 @@ REAL* mainKernelGPU(REAL& wg_a, for ( int i = 0; i < POP_SIZE; i++ ) { // parallel // Metropolis: get a random U[0,1) for each candidate // rand=N.random.uniform() - REAL rand = getRandUnifNorm(); + real_t rand = getRandUnifNorm(); // selection: dimensions considered independent // acceptance = min( 1, N.exp(c.logLik_proposal-c.logLik) * c.backward_forward_ratio ) - REAL acceptance = std::min( 1.0, exp( logLik[i+POP_SIZE] - logLik[i] ) * bf_rat[i] ); + real_t acceptance = std::min( 1.0, exp( logLik[i+POP_SIZE] - logLik[i] ) * bf_rat[i] ); // if acceptance criterion is met then p->p' else does nothing if ( rand < acceptance ) accept( i, g_a, g_b, g_rho, g_nu, g_sigma, logLik ); @@ -287,14 +287,14 @@ REAL* mainKernelGPU(REAL& wg_a, // print best candidate for the current iteration: #if (GPU_VERSION == 2) if ( (j % 16) == 0 ) { - int best_ind; REAL best_lik; + int best_ind; real_t best_lik; find_best_GPU( bestker, ocl_objs, ocl_arrs, logLik, best_ind, best_lik ); fprintf(stderr, "\n Iteration: %d: Best Likelihood: %f, genome index: %d!\n", j, best_lik, best_ind ); } #else if ( (j % 16) == 0 ){ - int best_ind; REAL best_lik; + int best_ind; real_t best_lik; find_best(logLik, best_ind, best_lik); fprintf(stderr, "\n Iteration: %d: Best Likelihood: %f, genome index: %d!\n", j, best_lik, best_ind ); @@ -304,7 +304,7 @@ REAL* mainKernelGPU(REAL& wg_a, #if (GPU_VERSION == 2) { // copy back genomes - uint cur_size = 12 * POP_SIZE * sizeof(REAL); + uint cur_size = 12 * POP_SIZE * sizeof(real_t); uint ciErr; cl_command_queue& cmd_queue = ocl_objs.getCommandQueue(); ciErr = clEnqueueReadBuffer(cmd_queue, ocl_arrs.genomes, CL_TRUE, 0, cur_size, cpu_arrs.genomes, 0, NULL, NULL); @@ -312,9 +312,9 @@ REAL* mainKernelGPU(REAL& wg_a, } #endif - REAL* result; + real_t* result; { // print best candidate for the current iteration: - int best_ind; REAL best_lik; + int best_ind; real_t best_lik; find_best(logLik, best_ind, best_lik); // recompute the calibrated price and the black price sequentially! diff --git a/InterestCalib/CppOpenCL/GenAlgKers.h b/benchmarks/InterestCalib/implementations/cpp_opencl/GenAlgKers.h similarity index 97% rename from InterestCalib/CppOpenCL/GenAlgKers.h rename to benchmarks/InterestCalib/implementations/cpp_opencl/GenAlgKers.h index 545297e..d45486a 100644 --- a/InterestCalib/CppOpenCL/GenAlgKers.h +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/GenAlgKers.h @@ -260,7 +260,7 @@ class GenAlgKers { ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(uint), &sobol_offset ); ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(uint), &dim_j ); - ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(REAL), &MOVES_UNIF_AMPL_RATIO ); + ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(real_t), &MOVES_UNIF_AMPL_RATIO ); ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(uint), &POP_SIZE ); oclCheckError( ciErr1, CL_SUCCESS ); @@ -272,8 +272,8 @@ class GenAlgKers { UINT counter = 0; cl_int ciErr1; - const REAL gamma_avg = 2.38 / sqrt(2.0*GENOME_DIM); - const REAL ampl_ratio = 0.1 * MOVES_UNIF_AMPL_RATIO; + const real_t gamma_avg = 2.38 / sqrt(2.0*GENOME_DIM); + const real_t ampl_ratio = 0.1 * MOVES_UNIF_AMPL_RATIO; kernel = clCreateKernel( ocl_objs.program, "mcmc_DE", &ciErr1 ); @@ -285,8 +285,8 @@ class GenAlgKers { ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(cl_mem), (void*)&gpu_buffs.sobol_dir_vct ); ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(uint), &sobol_offset ); - ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(REAL), &gamma_avg ); - ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(REAL), &l_ratio ); + ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(real_t), &gamma_avg ); + ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(real_t), &l_ratio ); ciErr1 |= clSetKernelArg( kernel, counter++, sizeof(uint), &POP_SIZE ); oclCheckError( ciErr1, CL_SUCCESS ); diff --git a/InterestCalib/CppOpenCL/MainKer.h b/benchmarks/InterestCalib/implementations/cpp_opencl/MainKer.h similarity index 94% rename from InterestCalib/CppOpenCL/MainKer.h rename to benchmarks/InterestCalib/implementations/cpp_opencl/MainKer.h index c607f33..39368db 100644 --- a/InterestCalib/CppOpenCL/MainKer.h +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/MainKer.h @@ -172,7 +172,7 @@ class MainKer { size_t cur_size; cl_command_queue& cmd_queue = ocl_objs.getCommandQueue(); - cur_size = 13 * POP_SIZE * sizeof(REAL); + cur_size = 13 * POP_SIZE * sizeof(real_t); ciErr |= clEnqueueWriteBuffer(cmd_queue, gpu_buffs.genomes, CL_TRUE, 0, cur_size, cpu_arrs.genomes, 0, NULL, NULL); oclCheckError(ciErr, CL_SUCCESS); @@ -183,13 +183,13 @@ class MainKer { size_t cur_size; cl_command_queue& cmd_queue = ocl_objs.getCommandQueue(); - cur_size = 4 * cpu_arrs.SS * POP_SIZE * sizeof(REAL); + cur_size = 4 * cpu_arrs.SS * POP_SIZE * sizeof(real_t); ciErr |= clEnqueueReadBuffer(cmd_queue, gpu_buffs.ci_t1cs_scale, CL_TRUE, 0, cur_size, cpu_arrs.ci_t1cs_scale, 0, NULL, NULL); - cur_size = NUM_SWAP_QUOTES * POP_SIZE * sizeof(REAL); // need only to write back the quotes (not the prices) + cur_size = NUM_SWAP_QUOTES * POP_SIZE * sizeof(real_t); // need only to write back the quotes (not the prices) ciErr |= clEnqueueReadBuffer(cmd_queue, gpu_buffs.new_quote_price, CL_TRUE, 0, cur_size, cpu_arrs.new_quote_price, 0, NULL, NULL); - cur_size = 8 * NUM_SWAP_QUOTES * POP_SIZE * sizeof(REAL); + cur_size = 8 * NUM_SWAP_QUOTES * POP_SIZE * sizeof(real_t); ciErr |= clEnqueueReadBuffer(cmd_queue, gpu_buffs.scalars, CL_TRUE, 0, cur_size, cpu_arrs.scalars, 0, NULL, NULL); } @@ -198,7 +198,7 @@ class MainKer { size_t cur_size; cl_command_queue& cmd_queue = ocl_objs.getCommandQueue(); - cur_size = NUM_SWAP_QUOTES * NUM_HERMITE * POP_SIZE * sizeof(REAL); + cur_size = NUM_SWAP_QUOTES * NUM_HERMITE * POP_SIZE * sizeof(real_t); ciErr |= clEnqueueReadBuffer(cmd_queue, gpu_buffs.accum0, CL_TRUE, 0, cur_size, cpu_arrs.accum0, 0, NULL, NULL); } @@ -207,14 +207,14 @@ class MainKer { size_t cur_size, offset; cl_command_queue& cmd_queue = ocl_objs.getCommandQueue(); - cur_size = POP_SIZE * sizeof(REAL); - offset = 11 * POP_SIZE * sizeof(REAL); + cur_size = POP_SIZE * sizeof(real_t); + offset = 11 * POP_SIZE * sizeof(real_t); ciErr |= clEnqueueReadBuffer(cmd_queue, gpu_buffs.genomes, CL_TRUE, offset, cur_size, cpu_arrs.get_logLik() + POP_SIZE, 0, NULL, NULL); -// cur_size = 13 * POP_SIZE * sizeof(REAL); +// cur_size = 13 * POP_SIZE * sizeof(real_t); // ciErr |= clEnqueueReadBuffer(cmd_queue, gpu_buffs.genomes, CL_TRUE, 0, cur_size, cpu_arrs.genomes, 0, NULL, NULL); -// cur_size = 2 * NUM_SWAP_QUOTES * POP_SIZE * sizeof(REAL); // need only to write back the quotes (not the prices) +// cur_size = 2 * NUM_SWAP_QUOTES * POP_SIZE * sizeof(real_t); // need only to write back the quotes (not the prices) // ciErr |= clEnqueueReadBuffer(cmd_queue, gpu_buffs.new_quote_price, CL_TRUE, 0, cur_size, cpu_arrs.new_quote_price, 0, NULL, NULL); } }; diff --git a/benchmarks/InterestCalib/implementations/cpp_opencl/Makefile b/benchmarks/InterestCalib/implementations/cpp_opencl/Makefile new file mode 100644 index 0000000..5c0f9a4 --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/Makefile @@ -0,0 +1,42 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +# Default to double if nothing else defined. +HIPERMARK_CONFIG_REAL_TYPE ?= double + +include $(HIPERMARK_LIB_DIR)/setup.mk +include $(HIPERMARK_LIB_DIR)/setup_real_type.mk + +# FIXME - this should not even exist! +include $(HIPERMARK_LIB_DIR)/platform.mk + +INCLUDES += -I$(HIPERMARK_BENCHMARK_LIB_DIR)/include +INCLUDES += -I$(HIPERMARK_LIB_DIR)/include + +GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -D GPU_DEV_ID=$(GPU_DEVICE_ID) \ + -D GPU_LOC_MEM=$(GPU_LOCAL_MEM) -D GPU_CONST_MEM=$(GPU_CONST_MEM) \ + -D GPU_REG_MEM=$(GPU_REG_MEM) -D GPU_GLB_MEM=$(GPU_DEVICE_MEM) \ + -D GPU_TILE=$(GPU_LOCAL_MEM_PER_TH) -D GPU_CORES=$(GPU_NUM_CORES) \ + -D CURR_DIR_PATH='"$(MAKE_DIR)"' + +SOURCES_CPP =SwapCalib.cpp +HELPERS =$(HIPERMARK_BENCHMARK_LIB_DIR)/include/ParseInput.h +OBJECTS =SwapCalib.o +EXECUTABLE =SwapCalib + + +default: $(EXECUTABLE) + +%.o: $(HIPERMARK_IMPLEMENTATION_DIR)/%.cpp $(HELPERS) + $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< + +$(EXECUTABLE): $(OBJECTS) + cp -r $(HIPERMARK_IMPLEMENTATION_DIR)/SrcCL . + $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) $(LIB) + +clean: + rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) + +HIPERMARK_DATA_FIELDS=population_size convergence_iterations num_swaption_quotes swaption_quotes num_hermite_coefficients hermite_coefficients hermite_coefficient_weights sobol_num_bits sobol_dir_vs +HIPERMARK_RUN_ENVIRONMENT= +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/InterestCalib/CppOpenCL/SrcCL/BestIndValRedKer.cl b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/BestIndValRedKer.cl similarity index 76% rename from InterestCalib/CppOpenCL/SrcCL/BestIndValRedKer.cl rename to benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/BestIndValRedKer.cl index 5be7b32..a495ff8 100644 --- a/InterestCalib/CppOpenCL/SrcCL/BestIndValRedKer.cl +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/BestIndValRedKer.cl @@ -2,11 +2,11 @@ /********* FIND_BEST KERNEL and HELPERS ***************/ /******************************************************/ -inline REAL2 OP_BEST(REAL2 iv1, REAL2 iv2) { +inline real2_t OP_BEST(real2_t iv1, real2_t iv2) { return ( ( iv1.y > iv2.y ) ? iv1 : iv2 ); } -inline REAL2 reduce_best_warp( __local volatile REAL2* sh_data ) { +inline real2_t reduce_best_warp( __local volatile real2_t* sh_data ) { const uint th_id = get_local_id(0) & (WARP-1); if( th_id >= 1 ) sh_data[th_id] = OP_BEST( sh_data[th_id], sh_data[th_id-1 ] ); @@ -19,9 +19,9 @@ inline REAL2 reduce_best_warp( __local volatile REAL2* sh_data ) { return sh_data[th_id]; } -inline void reduce_best_local ( __local volatile REAL2* sh_data ) { +inline void reduce_best_local ( __local volatile real2_t* sh_data ) { // perform scan at warp level - REAL2 res = reduce_best_warp( sh_data + WARP_FST ); + real2_t res = reduce_best_warp( sh_data + WARP_FST ); barrier( CLK_LOCAL_MEM_FENCE ); // gather per-warp results in the first WARP elements @@ -39,18 +39,18 @@ inline void reduce_best_local ( __local volatile REAL2* sh_data ) { __kernel void redbest_ker1 ( - __global REAL *arr, + __global real_t *arr, __global uint *res_ind, - __global REAL *res_val, + __global real_t *res_val, uint offset, uint N, uint U ) { - __local REAL2 locred[ LWG_FB ]; + __local real2_t locred[ LWG_FB ]; arr += offset; - REAL2 seqbest = (REAL2) ( 0.0, -INFTY ); + real2_t seqbest = (real2_t) ( 0.0F, -INFTY ); uint i = get_group_id(0) * (U * get_local_size(0)) + get_local_id(0); @@ -60,7 +60,7 @@ redbest_ker1 ( if( B > N ) { B = N; } for( ; i < B; i += get_local_size(0) ) { - REAL2 cur = (REAL2) ( (REAL)i, arr[i] ); + real2_t cur = (real2_t) ( (real_t)i, arr[i] ); seqbest = OP_BEST(seqbest, cur); } @@ -70,7 +70,7 @@ redbest_ker1 ( reduce_best_local ( locred ); if ( get_local_id(0) == get_local_size(0) - 1 ) { - REAL2 res = locred[WARP-1]; + real2_t res = locred[WARP-1]; res_ind[ get_group_id(0) ] = (uint) res.x; res_val[ get_group_id(0) ] = res.y; } @@ -82,18 +82,18 @@ redbest_ker1 ( __kernel void redbest_ker2 ( __global uint *arr_ind, - __global REAL *arr_val, + __global real_t *arr_val, uint N ) { - __local REAL2 locred[ LWG_FB ]; + __local real2_t locred[ LWG_FB ]; uint th_id = get_local_id(0); if ( th_id >= N ) { - REAL2 tmp = (REAL2) ( 0.0, -INFTY ); + real2_t tmp = (real2_t) ( 0.0F, -INFTY ); locred[ th_id ] = tmp; } else { - REAL2 tmp = (REAL2) ( (REAL)arr_ind[th_id], arr_val[th_id] ); + real2_t tmp = (real2_t) ( (real_t)arr_ind[th_id], arr_val[th_id] ); locred[ th_id ] = tmp; } @@ -101,7 +101,7 @@ redbest_ker2 ( reduce_best_local( locred ); if ( th_id == get_local_size(0) - 1 ) { - REAL2 res = locred[ WARP-1 ]; + real2_t res = locred[ WARP-1 ]; arr_ind[ 0 ] = (uint) res.x; arr_val[ 0 ] = res.y; } diff --git a/InterestCalib/CppOpenCL/SrcCL/CalibKers.cl b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/CalibKers.cl similarity index 66% rename from InterestCalib/CppOpenCL/SrcCL/CalibKers.cl rename to benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/CalibKers.cl index cd35060..46fc053 100644 --- a/InterestCalib/CppOpenCL/SrcCL/CalibKers.cl +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/CalibKers.cl @@ -1,33 +1,24 @@ -// BOP is a generic binary associative operator, +// BOP is a generic binary associative operator, // e.g., +, *, AND, OR -//#define BOP(a,b) ( (a)+(b) ) - - -#include "KerConsts.h" +//#define BOP(a,b) ( (a)+(b) ) -#define TH_ID (get_local_id(0)) +#include "real.h" +#include "KerConsts.h" + +#define TH_ID (get_local_id(0)) #define WARP_ID (TH_ID >> lgWARP) #define WARP_FST (WARP_ID << lgWARP) #define WARP_LST (WARP_FST + (WARP-1)) +inline real_t minR(real_t a, real_t b) { return ( (a <= b) ? a : b ); } +inline real_t maxR(real_t a, real_t b) { return ( (a <= b) ? b : a ); } -#if WITH_FLOAT - typedef float2 REAL2; - typedef float4 REAL4; -#else - typedef double2 REAL2; - typedef double4 REAL4; -#endif - -inline REAL minR(REAL a, REAL b) { return ( (a <= b) ? a : b ); } -inline REAL maxR(REAL a, REAL b) { return ( (a <= b) ? b : a ); } +#include "GenAlg.cl" +#include "BestIndValRedKer.cl" -#include "GenAlg.cl" -#include "BestIndValRedKer.cl" - /******************************************************/ /********* EVAL_GENOME KERNELS and HELPERS ************/ -/******************************************************/ +/******************************************************/ /** Assumes global shape has the following layout: * 1. flags, i.e., 1 if start of segment, -1 if iddle thread, and 0 otherwise @@ -40,7 +31,7 @@ inline REAL maxR(REAL a, REAL b) { return ( (a <= b) ? b : a ); } * 3. index as short in iota(n_schedi), * 4. swaption's global index as short * 5. size fo the current segment as short - */ + */ inline bool fillShapeMeta(__global short* shape, __local short* sh_mem, @@ -54,12 +45,12 @@ bool fillShapeMeta(__global short* shape, __local uchar* shape_meta = (__local uchar*) sh_mem; shape_meta[ loc_ind ] = ( tmp != 0 ) ? (uchar) 1 : (uchar) 0; - loc_ind += get_local_size(0); + loc_ind += get_local_size(0); shape_meta[ loc_ind ] = (uchar) 0; } glb_ind += Nshp; - sh_mem[ loc_ind ] = shape[ glb_ind ]; // setting iota(n_schedi) + sh_mem[ loc_ind ] = shape[ glb_ind ]; // setting iota(n_schedi) loc_ind += get_local_size(0); glb_ind += Nshp; @@ -68,7 +59,7 @@ bool fillShapeMeta(__global short* shape, loc_ind += get_local_size(0); glb_ind += Nshp; tmp = shape[ glb_ind ]; - if( tmp < 0 ) { iddle = true; tmp = -tmp; } + if( tmp < 0 ) { iddle = true; tmp = -tmp; } sh_mem[loc_ind] = tmp; barrier(CLK_LOCAL_MEM_FENCE); @@ -76,19 +67,19 @@ bool fillShapeMeta(__global short* shape, } inline -short getIotaInd (__local short* shape) { +short getIotaInd (__local short* shape) { return shape[ TH_ID + get_local_size(0) ]; -} +} inline short getSwapGlbInd(__local short* shape) { - return shape[ (get_local_size(0) << 1) + TH_ID ]; + return shape[ (get_local_size(0) << 1) + TH_ID ]; } -inline +inline short getSwapLocInd(__local short* shape) { short res = getSwapGlbInd(shape) - shape[ get_local_size(0) << 1 ]; return res; } -inline +inline short getSgmSize (__local short* shape ) { return shape[ (get_local_size(0) << 1) + get_local_size(0) + TH_ID ]; } @@ -100,35 +91,35 @@ short getSgmSize (__local short* shape ) { /** - * Two-dimensional kernel: - * 1. the outer dimension is POP_SIZE, - * 2. the inner dimension is Nshp, i.e., an approximation - * (with idde threads) of the flattened parallelism + * Two-dimensional kernel: + * 1. the outer dimension is POP_SIZE, + * 2. the inner dimension is Nshp, i.e., an approximation + * (with idde threads) of the flattened parallelism * of the loop of count `NUM_SWAP_QUOTES'. */ -__kernel __attribute__((reqd_work_group_size(LWG_EG, 1, 1))) +__kernel __attribute__((reqd_work_group_size(LWG_EG, 1, 1))) void eval_genome_main ( __global short *glb_shape, - __global REAL *SwaptionQuotes, - __global REAL *genomes, - __global REAL *glb_arrs, // ci ++ t1_cs ++ scale ++ bbi - __global REAL *new_quote_price, // [POP_SIZE * NUM_SWAP_QUOTES * 2] - __global REAL *interm_scalars, // [POP_SIZE * NUM_SWAP_QUOTES * 8] - // { mux, muy, sqrt_sigmax = sqrt(2.0) * sigmax, - // t2 = rhoxy / (sigmax*rhoxycs), sigmay_rhoxycs, zc_mat, f, df } + __global real_t *SwaptionQuotes, + __global real_t *genomes, + __global real_t *glb_arrs, // ci ++ t1_cs ++ scale ++ bbi + __global real_t *new_quote_price, // [POP_SIZE * NUM_SWAP_QUOTES * 2] + __global real_t *interm_scalars, // [POP_SIZE * NUM_SWAP_QUOTES * 8] + // { mux, muy, sqrt_sigmax = sqrt(2.0) * sigmax, + // t2 = rhoxy / (sigmax*rhoxycs), sigmay_rhoxycs, zc_mat, f, df } uint Nswap, uint Npop, uint Nshp -) { - REAL4 tmp4; - +) { + real4_t tmp4; + __local short shape_meta [ (LWG_EG << 2) ]; - __local REAL4 sh_mem4 [ LWG_EG + (LWG_EG >> 1) ]; + __local real4_t sh_mem4 [ LWG_EG + (LWG_EG >> 1) ]; bool iddle = fillShapeMeta( glb_shape, shape_meta, Nshp ); - REAL swap_freq = 1.0, maturity = 1.0, tmat0 = 1.0; uint n_schedi; + real_t swap_freq = 1.0, maturity = 1.0, tmat0 = 1.0; uint n_schedi; if( !iddle ) { int ttt = getSwapGlbInd(shape_meta); swap_freq = SwaptionQuotes[ (ttt<<2) + 1 ]; @@ -137,13 +128,13 @@ void eval_genome_main ( tmat0 = date_act_365( maturity, TODAY ); } - REAL strike, beg_date, end_date; + real_t strike, beg_date, end_date; { // BLACK PRICE COMPUTATION. __local uchar* flags = (__local uchar*) shape_meta; - tmp4 = (REAL4) (0.0, MAX_DATE, MIN_DATE, 1.0); + tmp4 = (real4_t) (0.0, MAX_DATE, MIN_DATE, 1.0); if(!iddle) { - tmp4.w = (REAL) getIotaInd(shape_meta); // i + tmp4.w = (real_t) getIotaInd(shape_meta); // i tmp4.y = add_months( maturity, swap_freq*tmp4.w ); // t0 tmp4.z = add_months( tmp4.y, swap_freq ); // tn tmp4.x = zc(tmp4.z) * date_act_365(tmp4.z,tmp4.y); // lvl @@ -157,8 +148,8 @@ void eval_genome_main ( int last_ind = TH_ID - getIotaInd( shape_meta ); if(!iddle) last_ind += n_schedi - 1; tmp4 = sh_mem4[last_ind]; // the reduction result! - barrier(CLK_LOCAL_MEM_FENCE); - + barrier(CLK_LOCAL_MEM_FENCE); + strike = ( zc(tmp4.y) - zc(tmp4.z) ) / tmp4.x; if( flags[TH_ID] && (!iddle) ) { // if thread is the start of a segment @@ -166,16 +157,16 @@ void eval_genome_main ( int ttt = getSwapGlbInd(shape_meta); tmp4.y = 0.5 * SwaptionQuotes[ (ttt<<2) + 3 ] * tmat0; // was get_group_id(1) - new_quote_price[ get_global_id(1)*Nswap + ttt ] = + new_quote_price[ get_global_id(1)*Nswap + ttt ] = tmp4.x * strike * ( uGaussian_P(tmp4.y) - uGaussian_P(-tmp4.y) ); } } // END BLACK PRICE. { // PRICER OF SWAPTION COMPUTATION - REAL y0, y1, eps, eps_contrib, mux, t4, t1_cs_first; + real_t y0, y1, eps, eps_contrib, mux, t4, t1_cs_first; { - REAL a, b, rho, nu, sigma; + real_t a, b, rho, nu, sigma; { uint tmp_ind = get_global_id(1) + Npop; uint Npop2 = (Npop << 1); @@ -186,8 +177,8 @@ void eval_genome_main ( sigma = genomes[ tmp_ind ]; tmp_ind += Npop2; } // - { - REAL v0_mat, v0_end, vt_end, baii, bbii, tmp; + { + real_t v0_mat, v0_end, vt_end, baii, bbii, tmp; tmp4 = bigv( a, b, rho, nu, sigma, tmat0 ); v0_mat = tmp4.x; // @@ -197,17 +188,17 @@ void eval_genome_main ( // tmp = date_act_365(end_date, maturity); tmp4 = bigv( a, b, rho, nu, sigma, tmp ); - vt_end = tmp4.x; + vt_end = tmp4.x; //baii = tmp4.y; //bbii = tmp4.z; tmp4.w = 0.5 * ( vt_end - v0_end + v0_mat ); // expo_aici tmp4.x = date_act_365( end_date, beg_date ) * strike; // res } // - { + { //bool is_first = ((__local uchar*)shape_meta)[TH_ID] && (!iddle); bool is_first = (!iddle) && ( (TH_ID == get_local_size(0)-1) || (((__local uchar*)shape_meta)[TH_ID+1]==1) ); // actually is_last! - REAL muy, rhoxy, sigmax, sigmay, rhoxyc, rhoxycs, zc_mat, tmp1, tmp2; + real_t muy, rhoxy, sigmax, sigmay, rhoxyc, rhoxycs, zc_mat, tmp1, tmp2; uint gind = get_global_id(1)*Nswap + getSwapGlbInd(shape_meta), offset = Npop*Nswap; // was get_group_id(1) // mux = - bigmx( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); @@ -216,24 +207,24 @@ void eval_genome_main ( muy = - bigmy( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); if(is_first) interm_scalars[ gind ] = muy; gind += offset; // - tmp1 = sqrt( b_fun(2.0*a, tmat0) ); // sqrt_bfun_a + tmp1 = sqrt( (real_t)b_fun(2.0*a, tmat0) ); // sqrt_bfun_a sigmax = sigma * tmp1; - if(is_first) interm_scalars[ gind ] = sqrt(2.0) * sigmax; gind += offset; + if(is_first) interm_scalars[ gind ] = sqrt((real_t)2.0) * sigmax; gind += offset; // - tmp2 = sqrt( b_fun(2.0*b, tmat0) ); // sqrt_bfun_b + tmp2 = sqrt( (real_t)b_fun(2.0*b, tmat0) ); // sqrt_bfun_b sigmay = nu * tmp2; - rhoxy = rho * b_fun(a+b, tmat0) / (tmp1 * tmp2); + rhoxy = rho * b_fun(a+b, tmat0) / (tmp1 * tmp2); t4 = (rhoxy * sigmay) / sigmax; // rhoxyc = 1.0 - rhoxy * rhoxy; // used in reduction kernel - rhoxycs = sqrt( rhoxyc ); // used in reduction kernel + rhoxycs = sqrt( (real_t)rhoxyc ); // used in reduction kernel if(is_first) interm_scalars[ gind ] = rhoxy / (sigmax*rhoxycs); gind += offset; if(is_first) interm_scalars[ gind ] = sigmay * rhoxycs; gind += offset; // zc_mat = zc(maturity); if(is_first) tmp4.x += 1.0; //cii tmp4.x *= zc(end_date) / zc_mat; // fact_aici - if(is_first) interm_scalars[ gind ] = zc_mat; gind += offset; + if(is_first) interm_scalars[ gind ] = zc_mat; gind += offset; // t1_cs_first = tmp4.z * (mux * t4 - (muy - 0.5*rhoxyc*sigmay*sigmay*tmp4.z) ); eps = 0.5 * sigmax; @@ -242,54 +233,54 @@ void eval_genome_main ( y1 = muy - y0; y0 += muy - ( rhoxyc / b ); } - } + } { - { // save to global arrays, ci, t1_cs, scale, bbi, and + { // save to global arrays, ci, t1_cs, scale, bbi, and // store (aici, baii, bbii, log_aici) in tmp4! - uint gind = get_global_id(1) * Nshp + get_global_id(0), offset = Nshp * Npop; - REAL fact_aici = tmp4.x; - - if( !iddle ) glb_arrs[gind] = fact_aici; gind += offset; // ci [i] + uint gind = get_global_id(1) * Nshp + get_global_id(0), offset = Nshp * Npop; + real_t fact_aici = tmp4.x; + + if( !iddle ) glb_arrs[gind] = fact_aici; gind += offset; // ci [i] if( !iddle ) glb_arrs[gind] = t1_cs_first + tmp4.w; gind += offset; // t1_cs[i] if( !iddle ) glb_arrs[gind] = - ( tmp4.y + tmp4.z * t4 ); gind += offset; // scale[i] if( !iddle ) glb_arrs[gind] = tmp4.z; // bbi [i] - tmp4.x *= exp(tmp4.w); // aici - tmp4.w += log(fact_aici); // log_aici - - sh_mem4[ TH_ID ] = tmp4; - barrier(CLK_LOCAL_MEM_FENCE); - } + tmp4.x *= exp(tmp4.w); // aici + tmp4.w += log(fact_aici); // log_aici - { // finally call `exactYhat', and store `f' and `df' to global memory. - REAL f, g, h, df; - uint gind = getSwapGlbInd(shape_meta); - __local uchar* flags = (__local uchar*)shape_meta; - //uint n_schedi = (iddle) ? 1 : (uint)(12.0 * SwaptionQuotes[ (gind<<2) + 2 ] / swap_freq); + sh_mem4[ TH_ID ] = tmp4; + barrier(CLK_LOCAL_MEM_FENCE); + } + + { // finally call `exactYhat', and store `f' and `df' to global memory. + real_t f, g, h, df; + uint gind = getSwapGlbInd(shape_meta); + __local uchar* flags = (__local uchar*)shape_meta; + //uint n_schedi = (iddle) ? 1 : (uint)(12.0 * SwaptionQuotes[ (gind<<2) + 2 ] / swap_freq); - f = exactYhat( iddle, flags, n_schedi, y0, y1, sh_mem4, mux ); + f = exactYhat( iddle, flags, n_schedi, y0, y1, sh_mem4, mux ); if( flags[TH_ID] && (!iddle) ) { // start of segment - uint offset = Npop*Nswap; - gind += get_global_id(1)*Nswap + 6*offset; // was get_group_id(1) - interm_scalars[ gind ] = f; - gind += offset; - } - - y0 += eps_contrib; - y1 += eps_contrib; + uint offset = Npop*Nswap; + gind += get_global_id(1)*Nswap + 6*offset; // was get_group_id(1) + interm_scalars[ gind ] = f; + gind += offset; + } + + y0 += eps_contrib; + y1 += eps_contrib; mux+= eps; g = exactYhat( iddle, flags, n_schedi, y0, y1, sh_mem4, mux ); - y0 -= 2.0*eps_contrib; + y0 -= 2.0*eps_contrib; y1 -= 2.0*eps_contrib; mux-= 2.0*eps; h = exactYhat( iddle, flags, n_schedi, y0, y1, sh_mem4, mux ); if( flags[TH_ID] && (!iddle) ) { // start of segment interm_scalars[ gind ] = 0.5 * ( g - h ) / eps; // i.e., df - } + } } } } @@ -299,7 +290,7 @@ void eval_genome_main ( /*************** Main Reduction kernel 1 ****************/ /********************************************************/ /** - * Two-dimensional kernel: + * Two-dimensional kernel: * 1. the outermost dimension is POP_SIZE, * 2. the middle dimension is Gauss_DIM * 2. the inner dimension is Nshp, i.e., an approximation @@ -310,39 +301,39 @@ void eval_genome_main ( __kernel __attribute__((reqd_work_group_size(LWG_EG, 1, 1))) void eval_genome_red1 ( __global short *glb_shape, - __constant REAL *gauss_coefs, // [Gauss_DIM] - __constant REAL *gauss_weights, // [Gauss_DIM] + __constant real_t *gauss_coefs, // [Gauss_DIM] + __constant real_t *gauss_weights, // [Gauss_DIM] - __global REAL *glb_arrs, // ci ++ t1_cs ++ scale ++ bbi - __global REAL *interm_scalars, // [POP_SIZE * NUM_SWAP_QUOTES * 8] - // { mux, muy, sqrt_sigmax = sqrt(2.0) * sigmax, - // t2 = rhoxy / (sigmax*rhoxycs), sigmay_rhoxycs, zc_mat, f, df } + __global real_t *glb_arrs, // ci ++ t1_cs ++ scale ++ bbi + __global real_t *interm_scalars, // [POP_SIZE * NUM_SWAP_QUOTES * 8] + // { mux, muy, sqrt_sigmax = sqrt((real_t)2.0) * sigmax, + // t2 = rhoxy / (sigmax*rhoxycs), sigmay_rhoxycs, zc_mat, f, df } - __global REAL *accum0, // [ POP_SIZE * NUM_SWAP_QUOTES * Gauss_DIM ] + __global real_t *accum0, // [ POP_SIZE * NUM_SWAP_QUOTES * Gauss_DIM ] uint Nswap, uint Nshp -) { +) { __local short shape_meta [ LWG_EG << 2 ]; - __local REAL sh_mem [ LWG_EG ]; + __local real_t sh_mem [ LWG_EG ]; bool iddle; { - iddle = fillShapeMeta( glb_shape, shape_meta, Nshp ); + iddle = fillShapeMeta( glb_shape, shape_meta, Nshp ); } - REAL x_quad = gauss_coefs [get_global_id(1)]; + real_t x_quad = gauss_coefs [get_global_id(1)]; - REAL sigmay_rhoxycs, x, h1; + real_t sigmay_rhoxycs, x, h1; if(!iddle){ - REAL mux, muy, sqrt2sigmax, t2, f, df, yhat_x; // Npop == POP_SIZE = get_global_size(2) + real_t mux, muy, sqrt2sigmax, t2, f, df, yhat_x; // Npop == POP_SIZE = get_global_size(2) uint gind = get_global_id(2) * Nswap + getSwapGlbInd(shape_meta), offset = get_global_size(2) * Nswap; mux = interm_scalars[ gind ]; gind += offset; muy = interm_scalars[ gind ]; gind += offset; // x = sqrt2sigmax * x_quad + mux; - sqrt2sigmax = interm_scalars[ gind ]; gind += offset; // + sqrt2sigmax = interm_scalars[ gind ]; gind += offset; // x = sqrt2sigmax * x_quad + mux; t2 = interm_scalars[ gind ]; gind += offset; @@ -357,16 +348,16 @@ void eval_genome_red1 ( if(!iddle){ uint gind = get_global_id(2) * Nshp + get_global_id(0), offset = Nshp * get_global_size(2); - gind += 3 * offset; - REAL bbi = glb_arrs[gind]; gind -= offset; - REAL h2 = h1 + bbi * sigmay_rhoxycs; - - REAL scale = glb_arrs[gind]; gind -= offset; - REAL t1_cs = glb_arrs[gind]; gind -= offset; - REAL expo_aici = t1_cs + scale*x; - - REAL expo_part = uGaussian_P_withExpFactor( -h2, expo_aici ); - + gind += 3 * offset; + real_t bbi = glb_arrs[gind]; gind -= offset; + real_t h2 = h1 + bbi * sigmay_rhoxycs; + + real_t scale = glb_arrs[gind]; gind -= offset; + real_t t1_cs = glb_arrs[gind]; gind -= offset; + real_t expo_aici = t1_cs + scale*x; + + real_t expo_part = uGaussian_P_withExpFactor( -h2, expo_aici ); + x = glb_arrs[gind] * expo_part; } @@ -374,33 +365,33 @@ void eval_genome_red1 ( __local uchar* flags = (__local uchar*) shape_meta; bool is_last = (!iddle) && ( (TH_ID == get_local_size(0)-1) || ( flags[TH_ID+1] == 1) ); - - sh_mem[TH_ID] = (iddle) ? 0.0 : x; + + sh_mem[TH_ID] = (iddle) ? 0.0 : x; barrier(CLK_LOCAL_MEM_FENCE); segm_reduce_plus( sh_mem, flags ); if( is_last ) { - REAL accum = sh_mem[TH_ID]; - REAL tmp = sqrt(2.0) * x_quad; //(x - mux) / sigmax; - tmp = exp( - 0.5 * tmp * tmp ); + real_t accum = sh_mem[TH_ID]; + real_t tmp = sqrt((real_t)2.0) * x_quad; //(x - mux) / sigmax; + tmp = exp( (real_t)- 0.5 * tmp * tmp ); - REAL w_quad = gauss_weights[get_global_id(1)]; + real_t w_quad = gauss_weights[get_global_id(1)]; - REAL res = w_quad * tmp * ( uGaussian_P(-h1) - accum ); + real_t res = w_quad * tmp * ( uGaussian_P(-h1) - accum ); //uint GaussDIM = get_global_size(1); #if 0 - uint gind = get_global_id(2) * get_global_size(1) * Nswap + + uint gind = get_global_id(2) * get_global_size(1) * Nswap + getSwapGlbInd(shape_meta) * get_global_size(1) + get_global_id(1) ; - accum0[gind] = res; + accum0[gind] = res; #else // accum0 is put it in transposed form, i.e., - // accum0[ j * Nswap + ttt ] and is used in + // accum0[ j * Nswap + ttt ] and is used in // this way by the next kernel - uint gind = get_global_id(2) * get_global_size(1) * Nswap + + uint gind = get_global_id(2) * get_global_size(1) * Nswap + get_global_id(1) * Nswap + getSwapGlbInd(shape_meta); - accum0[gind] = res; + accum0[gind] = res; #endif } } @@ -411,23 +402,23 @@ void eval_genome_red1 ( /********************************************************/ /*************** Main Reduction kernel 2 ****************/ /********************************************************/ -inline REAL cauchy_pdf( REAL z, REAL mu, REAL gamma ) { - REAL x = (z-mu) / gamma; +inline real_t cauchy_pdf( real_t z, real_t mu, real_t gamma ) { + real_t x = (z-mu) / gamma; return 1.0 / ( PI * gamma * (1.0+x*x) ); } -inline REAL logLikelihood_cauchy( REAL y_ref, REAL y ) { - REAL LLHOOD_CAUCHY_OFFS = 5.0; - REAL gamma = ( fabs(y_ref) / 50.0 ) * LLHOOD_CAUCHY_OFFS + 0.01; - REAL pdfs = cauchy_pdf( y, y_ref, gamma ); +inline real_t logLikelihood_cauchy( real_t y_ref, real_t y ) { + real_t LLHOOD_CAUCHY_OFFS = 5.0; + real_t gamma = ( fabs(y_ref) / 50.0 ) * LLHOOD_CAUCHY_OFFS + 0.01; + real_t pdfs = cauchy_pdf( y, y_ref, gamma ); pdfs += 1.0e-20; // avoid NaNs return log(pdfs); } /** - * Two-dimensional kernel: + * Two-dimensional kernel: * 1. the outermost global dimension is POP_SIZE, - * 2. the innermost global dimension is equal to the local - * dimension, i.e., LWG_EG, which is an overapproximation + * 2. the innermost global dimension is equal to the local + * dimension, i.e., LWG_EG, which is an overapproximation * of NUM_SWAP_QUOTES. * Each local groups process exactly NUM_SWAP_QUOTES elements, * and the rest of the htreads are iddle. @@ -436,32 +427,32 @@ inline REAL logLikelihood_cauchy( REAL y_ref, REAL y ) { __kernel __attribute__((reqd_work_group_size(LWG_EG, 1, 1))) void eval_genome_red2 ( - __global REAL *genomes, - __global REAL *interm_scalars, // [POP_SIZE * NUM_SWAP_QUOTES * 8] - // { mux, muy, sqrt_sigmax = sqrt(2.0) * sigmax, - // t2 = rhoxy / (sigmax*rhoxycs), sigmay_rhoxycs, zc_mat, f, df } - __global REAL *accum0, // [ POP_SIZE * NUM_SWAP_QUOTES * Gauss_DIM ] - __global REAL *new_quote_price, // [POP_SIZE * NUM_SWAP_QUOTES * 2] + __global real_t *genomes, + __global real_t *interm_scalars, // [POP_SIZE * NUM_SWAP_QUOTES * 8] + // { mux, muy, sqrt_sigmax = sqrt((real_t)2.0) * sigmax, + // t2 = rhoxy / (sigmax*rhoxycs), sigmay_rhoxycs, zc_mat, f, df } + __global real_t *accum0, // [ POP_SIZE * NUM_SWAP_QUOTES * Gauss_DIM ] + __global real_t *new_quote_price, // [POP_SIZE * NUM_SWAP_QUOTES * 2] uint Nswap, uint GaussDIM -) { - __local REAL sh_mem [ LWG_EG ]; +) { + __local real_t sh_mem [ LWG_EG ]; - bool iddle = ( TH_ID >= Nswap ); + bool iddle = ( TH_ID >= Nswap ); - REAL lik = 0.0; - if (!iddle) { - REAL accum = 0.0; + real_t lik = 0.0; + if (!iddle) { + real_t accum = 0.0; uint gid = get_global_id(1) * GaussDIM * Nswap + get_global_id(0); for( uint j = 0; j < GaussDIM; j++, gid += Nswap ) { - accum += accum0[ gid ]; - } + accum += accum0[ gid ]; + } - gid = get_global_id(1) * Nswap + TH_ID; - REAL zc_mat = interm_scalars[ gid + (5 * get_global_size(1) * Nswap) ]; + gid = get_global_id(1) * Nswap + TH_ID; + real_t zc_mat = interm_scalars[ gid + (5 * get_global_size(1) * Nswap) ]; - REAL nprice = zc_mat * ( accum / sqrt( PI ) ); + real_t nprice = zc_mat * ( accum / sqrt( PI ) ); new_quote_price[ gid + get_global_size(1)*Nswap ] = nprice; lik = logLikelihood_cauchy( new_quote_price[gid], nprice ); @@ -470,8 +461,7 @@ void eval_genome_red2 ( sh_mem[ TH_ID ] = lik; barrier(CLK_LOCAL_MEM_FENCE); - REAL rms = reduce_reg_plus( sh_mem ); + real_t rms = reduce_reg_plus( sh_mem ); if(TH_ID == 0) genomes[ 11*get_global_size(1) + get_global_id(1) ] = rms; } - diff --git a/InterestCalib/CppOpenCL/SrcCL/Date.cl b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/Date.cl similarity index 91% rename from InterestCalib/CppOpenCL/SrcCL/Date.cl rename to benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/Date.cl index 19080cb..7159857 100644 --- a/InterestCalib/CppOpenCL/SrcCL/Date.cl +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/Date.cl @@ -93,13 +93,13 @@ bool check_date(int year, int month, int day) { } inline -REAL days_between(REAL t1, REAL t2) { +real_t days_between(real_t t1, real_t t2) { return ( (t1 - t2) / MINUTES_IN_DAY ); } inline -REAL date_act_365(REAL t1, REAL t2) { - return ( days_between(t1, t2) / 365.0 ); +real_t date_act_365(real_t t1, real_t t2) { + return ( days_between(t1, t2) / 365.0F ); } inline @@ -117,7 +117,7 @@ int end_of_month( int year, int month ) { } inline -REAL add_months ( REAL time, REAL rnbmonths ) { +real_t add_months ( real_t time, real_t rnbmonths ) { int nbmonths = convert_int(rnbmonths); //(int) rnbmonths; Date date = gregorian_of_date( convert_int( time ) ); @@ -135,12 +135,12 @@ REAL add_months ( REAL time, REAL rnbmonths ) { date.hour = 12; date.min = 0; - return (REAL) ( date_of_gregorian( date ) ); + return (real_t) ( date_of_gregorian( date ) ); } inline -REAL add_years( REAL date, REAL nbyears ) { - return add_months( date, nbyears * 12.0 ); +real_t add_years( real_t date, real_t nbyears ) { + return add_months( date, nbyears * 12.0F ); } #endif // ifndef GREG_CALEND diff --git a/InterestCalib/CppOpenCL/SrcCL/ExactYhat.cl b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/ExactYhat.cl similarity index 68% rename from InterestCalib/CppOpenCL/SrcCL/ExactYhat.cl rename to benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/ExactYhat.cl index d66d7dd..c054fd9 100644 --- a/InterestCalib/CppOpenCL/SrcCL/ExactYhat.cl +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/ExactYhat.cl @@ -1,14 +1,14 @@ // reduction with + -REAL to_solve( bool iddle, +real_t to_solve( bool iddle, uint n_schedi, __local uchar* flags, - __local REAL * sh_mem, + __local real_t * sh_mem, - REAL scale, - REAL bbi, - REAL yhat + real_t scale, + real_t bbi, + real_t yhat ) { - REAL accum; + real_t accum; sh_mem[TH_ID] = (iddle) ? 0.0 : scale * exp( - bbi * yhat ); barrier(CLK_LOCAL_MEM_FENCE); @@ -27,25 +27,25 @@ REAL to_solve( bool iddle, /** * root finding by Brent's method. */ -//REAL2 tmp2 = rootFinding_Brent(iddle, shape, sh_mem4, scales, uplo.y, uplo.x, 1.0e-4, 1000); +//real2_t tmp2 = rootFinding_Brent(iddle, shape, sh_mem4, scales, uplo.y, uplo.x, 1.0e-4, 1000); //rootFinding_Brent(1, n_schedi, scales, bbi, root_lb, root_ub, 1.0e-4, 1000, root, iter, error); inline -REAL2 rootFinding_Brent( bool iddle, +real2_t rootFinding_Brent( bool iddle, uint n_schedi, __local uchar* flags, - __local REAL * sh_mem, - REAL bbi, //sh_mem4[TH_ID].z; - REAL scale, - REAL a, //lb, - REAL b, //ub, - REAL tol, + __local real_t * sh_mem, + real_t bbi, //sh_mem4[TH_ID].z; + real_t scale, + real_t a, //lb, + real_t b, //ub, + real_t tol, uint iter_max - // (root, fb) : (REAL, REAL) + // (root, fb) : (real_t, real_t) ) { - REAL2 res; + real2_t res; - REAL fa = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, a); - REAL fb = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, b); + real_t fa = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, a); + real_t fb = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, b); if( (!iddle) && fa*fb >= 0.0 ) { res.x = 0.0; @@ -53,11 +53,11 @@ REAL2 rootFinding_Brent( bool iddle, iddle = true; } - if( fabs(fa) < fabs(fb) ) { REAL tmp = fa; fa = fb; fb = tmp; tmp = a; a = b; b = tmp; } + if( fabs(fa) < fabs(fb) ) { real_t tmp = fa; fa = fb; fb = tmp; tmp = a; a = b; b = tmp; } - REAL c = a, fc = fa; + real_t c = a, fc = fa; bool mflag = true; - REAL d = 0.0; + real_t d = 0.0; uchar ok = 0; int i = 0; do { @@ -81,14 +81,14 @@ REAL2 rootFinding_Brent( bool iddle, // the loop's body if( !ok ) { - REAL s; + real_t s; if( !iddle ) { if( fa == fc || fb == fc ) { s = b - fb * (b - a) / (fb - fa); } else { - REAL s1 = (a*fb*fc)/( (fa-fb)*(fa-fc) ); - REAL s2 = (b*fa*fc)/( (fb-fa)*(fb-fc) ); - REAL s3 = (c*fa*fb)/( (fc-fa)*(fc-fb) ); + real_t s1 = (a*fb*fc)/( (fa-fb)*(fa-fc) ); + real_t s2 = (b*fa*fc)/( (fb-fa)*(fb-fc) ); + real_t s3 = (c*fa*fb)/( (fc-fa)*(fc-fb) ); s = s1 + s2 + s3; } @@ -106,7 +106,7 @@ REAL2 rootFinding_Brent( bool iddle, mflag = false; } } - REAL fs = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, s); + real_t fs = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, s); if( !iddle ) { // d is assigned for the first time here: @@ -118,7 +118,7 @@ REAL2 rootFinding_Brent( bool iddle, else { a = s; fa = fs; } if( fabs(fa) < fabs(fb) ) { - REAL tmp; + real_t tmp; tmp = a; a = b; b = tmp; tmp = fa; fa = fb; fb = tmp; } @@ -134,22 +134,22 @@ REAL2 rootFinding_Brent( bool iddle, /*********************************************/ inline -REAL2 rootBisection( bool iddle, +real2_t rootBisection( bool iddle, uint n_schedi, __local uchar* flags, - __local REAL * sh_mem, - REAL bbi, //sh_mem4[TH_ID].z; - REAL scale, - REAL a, //lb, - REAL b, //ub, - REAL tol, + __local real_t * sh_mem, + real_t bbi, //sh_mem4[TH_ID].z; + real_t scale, + real_t a, //lb, + real_t b, //ub, + real_t tol, uint iter_max - // (root, fb) : (REAL, REAL) + // (root, fb) : (real_t, real_t) ) { - REAL2 res; + real2_t res; - REAL fa = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, a); - REAL fb = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, b); + real_t fa = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, a); + real_t fb = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, b); if( (!iddle) && fa*fb >= 0.0 ) { res.x = 0.0; @@ -157,7 +157,7 @@ REAL2 rootBisection( bool iddle, iddle = true; } - REAL x = b, fx = fb; + real_t x = b, fx = fb; uchar ok = 0; int i = 0; do { @@ -181,11 +181,11 @@ REAL2 rootBisection( bool iddle, // the loop's body if( !ok ) { - REAL s; + real_t s; x=(a+b)/2.0; - REAL fx = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, x); + real_t fx = to_solve(iddle, n_schedi, flags, sh_mem, scale, bbi, x); if( !iddle ) { if ( fa*fx > 0.0 ) { a = x; fa = fx; } @@ -205,26 +205,26 @@ REAL2 rootBisection( bool iddle, /** * Computes Yhat */ -REAL exactYhat( bool iddle, +real_t exactYhat( bool iddle, __local uchar* flags, uint n_schedi, - REAL y0, - REAL y1, - __local REAL4* sh_mem4, - REAL x + real_t y0, + real_t y1, + __local real4_t* sh_mem4, + real_t x ) { - REAL res = 0.0, scales; - REAL2 uplo; + real_t res = 0.0, scales; + real2_t uplo; { // the first reduction (+,max) bool is_last; short lind; - __local REAL2* sh_mem2 = (__local REAL2*) (sh_mem4 + LWG_EG); + __local real2_t* sh_mem2 = (__local real2_t*) (sh_mem4 + LWG_EG); if( iddle ) { - uplo = (REAL2) ( 0.0, -INFTY ); + uplo = (real2_t) ( 0.0, -INFTY ); } else { - REAL4 tmp4 = sh_mem4[ TH_ID ]; - REAL baix = tmp4.y * x; + real4_t tmp4 = sh_mem4[ TH_ID ]; + real_t baix = tmp4.y * x; uplo.x = tmp4.x * exp( -baix ); uplo.y = ( tmp4.w - baix ) / tmp4.z; @@ -252,8 +252,8 @@ REAL exactYhat( bool iddle, if(!iddle) { // adjust `up' int lfind = TH_ID - getIotaInd( (__local short*)flags ) + n_schedi - 1; - REAL log_s = log(uplo.x); - REAL tmp = log_s / sh_mem4[ lfind ].z; //bbi[n_schedi-1]; + real_t log_s = log(uplo.x); + real_t tmp = log_s / sh_mem4[ lfind ].z; //bbi[n_schedi-1]; lfind += 1 - n_schedi; if ( tmp <= 0.0 ) { @@ -265,8 +265,8 @@ REAL exactYhat( bool iddle, } } -// const REAL yl = lo - EPS; -// const REAL yu = up + EPS; +// const real_t yl = lo - EPS; +// const real_t yu = up + EPS; if ( (!iddle) && (y1 <= uplo.y - EPS) ) { // yhat is greater than y1 => 1 - phi(h_i(x, yhat)) < EPS @@ -287,14 +287,14 @@ REAL exactYhat( bool iddle, // tmp2 = (root, error); //UINT iter; #if 1 - REAL2 tmp2 = rootFinding_Brent( - iddle, n_schedi, flags, (__local REAL*) (sh_mem4+LWG_EG), + real2_t tmp2 = rootFinding_Brent( + iddle, n_schedi, flags, (__local real_t*) (sh_mem4+LWG_EG), sh_mem4[TH_ID].z, scales, uplo.y, uplo.x, 1.0e-4, 1000 ); #else - REAL2 tmp2 = rootBisection( - iddle, n_schedi, flags, (__local REAL*) (sh_mem4+LWG_EG), + real2_t tmp2 = rootBisection( + iddle, n_schedi, flags, (__local real_t*) (sh_mem4+LWG_EG), sh_mem4[TH_ID].z, scales, uplo.y, uplo.x, 1.0e-4, 1000 ); diff --git a/InterestCalib/CppOpenCL/SrcCL/G2ppUtil.cl b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/G2ppUtil.cl similarity index 65% rename from InterestCalib/CppOpenCL/SrcCL/G2ppUtil.cl rename to benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/G2ppUtil.cl index b3544d8..0f2a482 100644 --- a/InterestCalib/CppOpenCL/SrcCL/G2ppUtil.cl +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/G2ppUtil.cl @@ -15,8 +15,8 @@ // http://people.math.sfu.ca/~cbm/aands/frameindex.htm inline -REAL erff1( REAL x ) { - REAL poly = 0.0, t, t2; +real_t erff1( real_t x ) { + real_t poly = 0.0F, t, t2; t = 1.0 / (1.0 + 0.3275911*x); poly += 0.254829592 * t; @@ -31,14 +31,14 @@ REAL erff1( REAL x ) { return ( 1.0 - poly * exp(-(x*x)) ); -// REAL p = 0.3275911; -// REAL a1 = 0.254829592, a2 = -0.284496736, a3 = 1.421413741, a4 = -1.453152027, a5 = 1.061405429; +// real_t p = 0.3275911; +// real_t a1 = 0.254829592, a2 = -0.284496736, a3 = 1.421413741, a4 = -1.453152027, a5 = 1.061405429; // -// REAL t = 1.0/(1.0+p*x); -// REAL t2 = t * t; -// REAL t3 = t * t2; -// REAL t4 = t2 * t2; -// REAL t5 = t2 * t3; +// real_t t = 1.0/(1.0+p*x); +// real_t t2 = t * t; +// real_t t3 = t * t2; +// real_t t4 = t2 * t2; +// real_t t5 = t2 * t3; // return ( 1.0 - (a1*t + a2*t2 + a3*t3 + a4*t4 + a5*t5) * exp(-(x*x)) ); } @@ -47,16 +47,16 @@ REAL erff1( REAL x ) { // Cumulative Distribution Function for a standard normal distribution inline -REAL uGaussian_P( REAL x ) { - REAL u = x / sqrt(2.0); - REAL e = ( u < 0.0 ) ? -erff1(-u) : erff1(u); +real_t uGaussian_P( real_t x ) { + real_t u = x / sqrt((real_t)2.0); + real_t e = ( u < 0.0 ) ? -erff1(-u) : erff1(u); return ( 0.5 * (1.0 + e) ); } inline -REAL erff_poly_only( REAL x ) { - REAL poly = 0.0, t, t2; +real_t erff_poly_only( real_t x ) { + real_t poly = 0.0, t, t2; t = 1.0 / (1.0 + 0.3275911*x); poly += 0.254829592 * t; @@ -73,11 +73,11 @@ REAL erff_poly_only( REAL x ) { } inline -REAL uGaussian_P_withExpFactor( REAL x, REAL exp_factor ) { - REAL u = fabs( x / sqrt(2.0) ); - REAL e = erff_poly_only(u); +real_t uGaussian_P_withExpFactor( real_t x, real_t exp_factor ) { + real_t u = fabs( x / sqrt((real_t)2.0) ); + real_t e = erff_poly_only(u); - REAL res = 0.5 * e * exp(exp_factor-u*u); + real_t res = 0.5 * e * exp(exp_factor-u*u); if( x >= 0.0 ) { res = exp(exp_factor) - res; @@ -91,19 +91,19 @@ REAL uGaussian_P_withExpFactor( REAL x, REAL exp_factor ) { ///////////////////////// inline -REAL zc( REAL t ) { - return exp( - R * date_act_365( t, TODAY ) ); +real_t zc( real_t t ) { + return exp( (real_t)(- R * date_act_365( t, TODAY )) ); } inline -REAL b_fun( REAL z0, REAL tau ) { +real_t b_fun( real_t z0, real_t tau ) { return ( 1.0 - exp(-z0*tau) ) / z0; } inline -REAL t_fun( REAL sigma, REAL x0, REAL tau ) { - REAL expxtau = exp( -x0*tau ) ; - REAL exp2xtau = expxtau*expxtau; +real_t t_fun( real_t sigma, real_t x0, real_t tau ) { + real_t expxtau = exp( -x0*tau ) ; + real_t exp2xtau = expxtau*expxtau; return sigma*sigma/(x0*x0) * ( tau + 2.0/x0*expxtau-1.0/(2.0*x0)*exp2xtau-3.0/(2.0*x0) ); } @@ -118,14 +118,14 @@ REAL t_fun( REAL sigma, REAL x0, REAL tau ) { /////////////////////////////////////////////////////////////////// //res = (v, bai, bbi, _) inline -REAL4 bigv( REAL g_a, - REAL g_b, - REAL g_rho, - REAL g_nu, - REAL g_sig, - REAL tau +real4_t bigv( real_t g_a, + real_t g_b, + real_t g_rho, + real_t g_nu, + real_t g_sig, + real_t tau ) { - REAL4 res4; + real4_t res4; res4.w = g_sig; //(g_sig == 0.0) ? 1.0e-10 : g_sig; // g_sigma res4.y = b_fun(g_a, tau); @@ -148,25 +148,25 @@ REAL4 bigv( REAL g_a, // the result is: x drift term in tmat-forward measure /////////////////////////////////////////////////////////////////// inline -REAL bigmx( REAL a, - REAL b, - REAL rho, - REAL nu, - REAL sigma, // ends genome - REAL today, - REAL tmat, - REAL s, - REAL t +real_t bigmx( real_t a, + real_t b, + real_t rho, + real_t nu, + real_t sigma, // ends genome + real_t today, + real_t tmat, + real_t s, + real_t t ) { - REAL ts = date_act_365(t, s) ; - REAL tmatt = date_act_365(tmat, t) ; + real_t ts = date_act_365(t, s) ; + real_t tmatt = date_act_365(tmat, t) ; - REAL tmat0 = date_act_365(tmat, today); - REAL tmats = date_act_365(tmat, s) ; - REAL t0 = date_act_365(t, today); - REAL s0 = date_act_365(s, today); + real_t tmat0 = date_act_365(tmat, today); + real_t tmats = date_act_365(tmat, s) ; + real_t t0 = date_act_365(t, today); + real_t s0 = date_act_365(s, today); - REAL tmp, res = 0.0; + real_t tmp, res = 0.0; tmp = (sigma*sigma)/(a*a)+(sigma*rho*nu)/(a*b); tmp *= ( 1.0 - exp(- a * ts) ); @@ -193,24 +193,24 @@ REAL bigmx( REAL a, // the result is: y drift term in tmat-forward measure /////////////////////////////////////////////////////////////////// inline -REAL bigmy( REAL a, - REAL b, - REAL rho, - REAL nu, - REAL sigma, // ends genome - REAL today, - REAL tmat, - REAL s, - REAL t +real_t bigmy( real_t a, + real_t b, + real_t rho, + real_t nu, + real_t sigma, // ends genome + real_t today, + real_t tmat, + real_t s, + real_t t ) { - REAL ts = date_act_365(t, s ); - REAL tmatt = date_act_365(tmat, t ); - REAL tmat0 = date_act_365(tmat, today); - REAL tmats = date_act_365(tmat, s ); - REAL t0 = date_act_365(t, today); - REAL s0 = date_act_365(s, today); - - REAL tmp, res = 0.0; + real_t ts = date_act_365(t, s ); + real_t tmatt = date_act_365(tmat, t ); + real_t tmat0 = date_act_365(tmat, today); + real_t tmats = date_act_365(tmat, s ); + real_t t0 = date_act_365(t, today); + real_t s0 = date_act_365(s, today); + + real_t tmp, res = 0.0; tmp = nu*nu/(b*b)+sigma*rho*nu/(a*b); tmp *= 1.0 - exp(-b * ts); diff --git a/InterestCalib/CppOpenCL/SrcCL/GenAlg.cl b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/GenAlg.cl similarity index 69% rename from InterestCalib/CppOpenCL/SrcCL/GenAlg.cl rename to benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/GenAlg.cl index 381a92e..508a5a1 100644 --- a/InterestCalib/CppOpenCL/SrcCL/GenAlg.cl +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/GenAlg.cl @@ -2,7 +2,7 @@ #ifndef GEN_ALG_KERNELS #define GEN_ALG_KERNELS -REAL getSobolNum( uint n, __constant int* SOBOL_DIR_VCT ) { +real_t getSobolNum( uint n, __constant int* SOBOL_DIR_VCT ) { int n_gray = (n >> 1) ^ n; int res = 0; for( int i=0; i < SOBOL_BITS_NUM; i++ ) { @@ -12,7 +12,7 @@ REAL getSobolNum( uint n, __constant int* SOBOL_DIR_VCT ) { res = res ^ SOBOL_DIR_VCT[i]; } } - REAL rres = ((REAL)res) / ( (1< 0.0 ) ? (backward_range / forward_range) : 1.0; + real_t bf_fact = ( semiamplitude > 0.0F ) ? (backward_range / forward_range) : 1.0F; // assign p' - REAL diff = amplitude * r01 - semiamplitude; - return (REAL2) (gene + diff, bf_fact); + real_t diff = amplitude * r01 - semiamplitude; + return (real2_t) (gene + diff, bf_fact); } inline -REAL constrain_gene( REAL gene, REAL lb, REAL ub ) { +real_t constrain_gene( real_t gene, real_t lb, real_t ub ) { return maxR( lb, minR( ub, gene ) ); } @@ -167,12 +167,12 @@ REAL constrain_gene( REAL gene, REAL lb, REAL ub ) { * Dimension is POP_SIZE (LWG = GWG) */ __kernel void -mutate_dims ( __global REAL* genomes, //[13, POP_SIZE] - __constant REAL* lub, //[2, 5]. i.e., [lower,upper] gene range +mutate_dims ( __global real_t* genomes, //[13, POP_SIZE] + __constant real_t* lub, //[2, 5]. i.e., [lower,upper] gene range __constant int * SOBOL_DIR_VCT, //[SOBOL_BITS_NUM == 30] uint sob_offset, uint dim_j, - REAL amplitude_ratio, // = MOVES_UNIF_AMPL_RATIO + real_t amplitude_ratio, // = MOVES_UNIF_AMPL_RATIO uint Npop // POP_SIZE ) { uint gid = get_global_id(0); @@ -182,20 +182,20 @@ mutate_dims ( __global REAL* genomes, //[13, POP_SIZE] uint gidr = gid + sob_offset; #endif uint offset = ( Npop << 1 ); - REAL fb_rat = 1.0; - REAL2 tmp; + real_t fb_rat = 1.0F; + real2_t tmp; if( gid < Npop ) { gid += Npop; for(int i=0; i < 5; i++) { - REAL lb = lub[i], ub = lub[i+5]; - REAL r01 = getSobolNum(gidr, SOBOL_DIR_VCT); + real_t lb = lub[i], ub = lub[i+5]; + real_t r01 = getSobolNum(gidr, SOBOL_DIR_VCT); - REAL ampl = (dim_j > 4 || dim_j == i) ? amplitude_ratio : 0.0; + real_t ampl = (dim_j > 4 || dim_j == i) ? amplitude_ratio : 0.0F; tmp = mutate_helper( genomes[gid-Npop], genomes[gid], lb, ub, r01, ampl ); - REAL val = constrain_gene(tmp.x, lb, ub); + real_t val = constrain_gene(tmp.x, lb, ub); genomes[gid] = val; //(i == 2 && val == 0.0) ? EPS0 : val; fb_rat *= tmp.y; @@ -216,27 +216,27 @@ mutate_dims ( __global REAL* genomes, //[13, POP_SIZE] /************* Crossover MCMC_DE **************/ /**********************************************/ -inline REAL getRandUnifNorm(REAL r) { +inline real_t getRandUnifNorm(real_t r) { return r; } //Returns a (pseudo) random integer in [0, ub) -inline uint getRandIntNorm(uint ub, REAL r01) { +inline uint getRandIntNorm(uint ub, real_t r01) { return (uint) (r01 * ub); } inline -REAL perturbation( REAL gene, - REAL gene_k, - REAL gene_l, - REAL r01, - REAL lb, - REAL ub, - REAL gamma1, - REAL amplitude_ratio //= MOVES_UNIF_AMPL_RATIO +real_t perturbation( real_t gene, + real_t gene_k, + real_t gene_l, + real_t r01, + real_t lb, + real_t ub, + real_t gamma1, + real_t amplitude_ratio //= MOVES_UNIF_AMPL_RATIO ) { - REAL amplitude = fabs( (ub - lb) * amplitude_ratio ); - REAL semiamplitude = amplitude / 2.0; - REAL perturb = ( amplitude * r01 - semiamplitude ); + real_t amplitude = fabs( (ub - lb) * amplitude_ratio ); + real_t semiamplitude = amplitude / 2.0F; + real_t perturb = ( amplitude * r01 - semiamplitude ); return ( gene + perturb + gamma1 * ( gene_k - gene_l ) ); } @@ -245,15 +245,15 @@ REAL perturbation( REAL gene, * One-Dimensional of size POP_SIZE = LWG = GWG */ __kernel void -mcmc_DE( __global REAL *genomes, - __constant REAL *lub, // [2, 5]. i.e., [lower,upper] gene range +mcmc_DE( __global real_t *genomes, + __constant real_t *lub, // [2, 5]. i.e., [lower,upper] gene range __constant int *SOBOL_DIR_VCT, // [SOBOL_BITS_NUM == 30] uint sob_offset, - REAL gamma_avg, // 2.38 / sqrt(2.0*GENOME_DIM), - REAL ampl_ratio, // 0.1 * MOVES_UNIF_AMPL_RATIO + real_t gamma_avg, // 2.38 / sqrt(2.0*GENOME_DIM), + real_t ampl_ratio, // 0.1 * MOVES_UNIF_AMPL_RATIO uint Npop ) { - REAL r01; + real_t r01; uint gid = get_global_id(0); #if (SOBOL_TRANSP == 1) @@ -286,13 +286,13 @@ mcmc_DE( __global REAL *genomes, // random.uniform: is it supposed to be Sobol or such ? Does C++ rand() works? // gamma = N.random.uniform( gamma_avg-0.5, gamma_avg+0.5 ) r01 = getSobolNum(gidr, SOBOL_DIR_VCT ); gidr += rinc; - REAL gamma1 = gamma_avg - 0.5 + getRandUnifNorm( r01 ); + real_t gamma1 = gamma_avg - 0.5F + getRandUnifNorm( r01 ); for( int j = 0; j < 5; j ++ ) { - REAL lb = lub[j], ub = lub[j+5]; + real_t lb = lub[j], ub = lub[j+5]; r01 = getSobolNum(gidr, SOBOL_DIR_VCT ); - REAL val = perturbation ( genomes[gid], genomes[k], genomes[l], r01, lb, ub, gamma1, ampl_ratio ); + real_t val = perturbation ( genomes[gid], genomes[k], genomes[l], r01, lb, ub, gamma1, ampl_ratio ); val = constrain_gene( val, lb, ub ); genomes[ gid + Npop ] = val; //( j == 2 && val == 0.0 ) ? EPS0 : val; @@ -304,7 +304,7 @@ mcmc_DE( __global REAL *genomes, } gid += offset; - genomes[gid] = 1.0; // TODO: fix + genomes[gid] = 1.0F; // TODO: fix } } diff --git a/InterestCalib/CppOpenCL/SrcCL/Reductions.cl b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/Reductions.cl similarity index 89% rename from InterestCalib/CppOpenCL/SrcCL/Reductions.cl rename to benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/Reductions.cl index 200c5ef..f9026a1 100644 --- a/InterestCalib/CppOpenCL/SrcCL/Reductions.cl +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/SrcCL/Reductions.cl @@ -63,8 +63,8 @@ uchar reduce_reg_and ( __local volatile uchar* sh_data ) { /*************************************************/ inline -REAL reduce_reg_plus_warp( - __local volatile REAL* sh_data +real_t reduce_reg_plus_warp( + __local volatile real_t* sh_data ) { const uint th_id = get_local_id(0) & (WARP-1); @@ -79,9 +79,9 @@ REAL reduce_reg_plus_warp( } inline -REAL reduce_reg_plus ( __local volatile REAL* sh_data ) { +real_t reduce_reg_plus ( __local volatile real_t* sh_data ) { // perform scan at warp level - REAL res = reduce_reg_plus_warp( sh_data + WARP_FST ); + real_t res = reduce_reg_plus_warp( sh_data + WARP_FST ); barrier( CLK_LOCAL_MEM_FENCE ); // gather per-warp results in the first WARP elements @@ -114,8 +114,8 @@ REAL reduce_reg_plus ( __local volatile REAL* sh_data ) { /*** Irregular, Segmented Reduction With Op. + ***/ /*************************************************/ -inline REAL segm_reduce_plus_warp( - __local volatile REAL* ptr, +inline real_t segm_reduce_plus_warp( + __local volatile real_t* ptr, __local volatile uchar* hd ) { const uint th_id = TH_ID & (WARP-1); @@ -145,7 +145,7 @@ inline REAL segm_reduce_plus_warp( } inline void segm_reduce_plus( - __local volatile REAL *ptr, + __local volatile real_t *ptr, __local volatile uchar *hd ) { // 1a: record whether this warp begins @@ -155,10 +155,10 @@ inline void segm_reduce_plus( barrier(CLK_LOCAL_MEM_FENCE); // 1b: intra-warp segmented scan for each warp - REAL val = segm_reduce_plus_warp( ptr + WARP_FST, hd + WARP_FST ); + real_t val = segm_reduce_plus_warp( ptr + WARP_FST, hd + WARP_FST ); // 2a: the last value is the correct partial result - REAL warp_total = ptr[WARP_LST]; + real_t warp_total = ptr[WARP_LST]; // 2b: warp_flag is the OR-reduction of the flags // in a warp, and is computed indirectly from @@ -200,12 +200,12 @@ inline void segm_reduce_plus( /*** Irregular, Segmented Reduce With Op. (+,max) ***/ /****************************************************/ -inline REAL2 OP_PLUS_MAX(REAL2 a, REAL2 b) { - return (REAL2) ( a.x + b.x, maxR(a.y, b.y) ); +inline real2_t OP_PLUS_MAX(real2_t a, real2_t b) { + return (real2_t) ( a.x + b.x, maxR(a.y, b.y) ); } -inline REAL2 segm_reduce_plusmax_warp( - __local volatile REAL2* ptr, +inline real2_t segm_reduce_plusmax_warp( + __local volatile real2_t* ptr, __local volatile uchar* hd ) { const uint th_id = TH_ID & (WARP-1); @@ -235,7 +235,7 @@ inline REAL2 segm_reduce_plusmax_warp( } inline void segm_reduce_plusmax( - __local volatile REAL2 *ptr, + __local volatile real2_t *ptr, __local volatile uchar *hd ) { // 1a: record whether this warp begins @@ -245,10 +245,10 @@ inline void segm_reduce_plusmax( barrier(CLK_LOCAL_MEM_FENCE); // 1b: intra-warp segmented scan for each warp - REAL2 val = segm_reduce_plusmax_warp( ptr + WARP_FST, hd + WARP_FST ); + real2_t val = segm_reduce_plusmax_warp( ptr + WARP_FST, hd + WARP_FST ); // 2a: the last value is the correct partial result - REAL2 warp_total = ptr[WARP_LST]; + real2_t warp_total = ptr[WARP_LST]; // 2b: warp_flag is the OR-reduction of the flags // in a warp, and is computed indirectly from @@ -291,12 +291,12 @@ inline void segm_reduce_plusmax( /*** Irregular, Segmented Reduce With Op. (+,max) ***/ /****************************************************/ -inline REAL4 OP_PLUS_MIN_MAX( REAL4 a, REAL4 b ) { - return ( REAL4 ) ( a.x + b.x, minR(a.y, b.y), maxR(a.z, b.z), 1.0 ); +inline real4_t OP_PLUS_MIN_MAX( real4_t a, real4_t b ) { + return ( real4_t ) ( a.x + b.x, minR(a.y, b.y), maxR(a.z, b.z), 1.0 ); } -inline REAL4 segm_reduce_plusminmax_warp( - __local volatile REAL4* ptr, +inline real4_t segm_reduce_plusminmax_warp( + __local volatile real4_t* ptr, __local volatile uchar* hd ) { const uint th_id = TH_ID & (WARP-1); @@ -326,7 +326,7 @@ inline REAL4 segm_reduce_plusminmax_warp( } inline void segm_reduce_plusminmax( - __local volatile REAL4 *ptr, + __local volatile real4_t *ptr, __local volatile uchar *hd ) { // 1a: record whether this warp begins @@ -336,10 +336,10 @@ inline void segm_reduce_plusminmax( barrier(CLK_LOCAL_MEM_FENCE); // 1b: intra-warp segmented scan for each warp - REAL4 val = segm_reduce_plusminmax_warp( ptr + WARP_FST, hd + WARP_FST ); + real4_t val = segm_reduce_plusminmax_warp( ptr + WARP_FST, hd + WARP_FST ); // 2a: the last value is the correct partial result - REAL4 warp_total = ptr[WARP_LST]; + real4_t warp_total = ptr[WARP_LST]; // 2b: warp_flag is the OR-reduction of the flags // in a warp, and is computed indirectly from diff --git a/InterestCalib/CppOpenCL/SwapCalib.cpp b/benchmarks/InterestCalib/implementations/cpp_opencl/SwapCalib.cpp similarity index 57% rename from InterestCalib/CppOpenCL/SwapCalib.cpp rename to benchmarks/InterestCalib/implementations/cpp_opencl/SwapCalib.cpp index 98ab15a..652de3a 100644 --- a/InterestCalib/CppOpenCL/SwapCalib.cpp +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/SwapCalib.cpp @@ -13,13 +13,13 @@ #include "Constants.h" #include "ParseInput.h" #include "GenAlgFlat.h" - +#include "WriteResult.h" int main() { - REAL wg_a = 0.0, wg_b = 0.0, wg_sigma = 0.0, - wg_nu = 0.0, wg_rho = 0.0, wg_logLik = 0.0; - REAL* calib_arr = NULL; + real_t wg_a = 0.0, wg_b = 0.0, wg_sigma = 0.0, + wg_nu = 0.0, wg_rho = 0.0, wg_logLik = 0.0; + real_t* calib_arr = NULL; printf("\n// Running GPU-Parallel Swaption-Calibration Benchmark\n"); @@ -29,7 +29,7 @@ int main() NUM_SOBOL_BITS, SobolDirVct ); - unsigned long int elapsed = 0; + unsigned long int elapsed_usec = 0; { // Main Computational Kernel struct timeval t_start, t_end, t_diff; gettimeofday(&t_start, NULL); @@ -38,15 +38,27 @@ int main() gettimeofday(&t_end, NULL); timeval_subtract(&t_diff, &t_end, &t_start); - elapsed = t_diff.tv_sec*1e6+t_diff.tv_usec; + elapsed_usec = t_diff.tv_sec*1e6+t_diff.tv_usec; } - { // validation and writeback of the result - bool is_valid = validate( wg_logLik, calib_arr, NUM_SWAP_QUOTES ); - writeStatsAndResult( is_valid, wg_a, wg_b, wg_sigma, wg_nu, wg_rho, - wg_logLik, calib_arr, NUM_SWAP_QUOTES, - true, GPU_CORES, elapsed ); + { // writeback of the result + FILE* runtime = fopen(getenv("HIPERMARK_RUNTIME"), "w"); + FILE* result = fopen(getenv("HIPERMARK_RESULT"), "w"); + const int Ps = get_CPU_num_threads(); + fprintf(runtime, "%d\n", elapsed_usec); + fclose(runtime); + + writeResult(result, + wg_a, + wg_b, + wg_sigma, + wg_nu, + wg_rho, + wg_logLik, + calib_arr); + + fclose(result); } - return 1; + return 0; } diff --git a/InterestCalib/CppOpenCL/UtilGPGPU.h b/benchmarks/InterestCalib/implementations/cpp_opencl/UtilGPGPU.h similarity index 73% rename from InterestCalib/CppOpenCL/UtilGPGPU.h rename to benchmarks/InterestCalib/implementations/cpp_opencl/UtilGPGPU.h index bb18d8e..d877ce3 100644 --- a/InterestCalib/CppOpenCL/UtilGPGPU.h +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/UtilGPGPU.h @@ -25,33 +25,33 @@ struct CpuArrays { // [13 * POP_SIZE] = // { a, a_p, b, b_p, rho, rho_p, nu, nu_p, // sigma, sigma_p, logLik, logLik_p, bf_rat } - REAL* genomes; + real_t* genomes; // [ 4 * SS * POP_SIZE ] - REAL* ci_t1cs_scale; + real_t* ci_t1cs_scale; // [ 2 * NUM_SWAP_QUOTES * POP_SIZE ] - REAL* new_quote_price; + real_t* new_quote_price; // [ NUM_SWAP_QUOTES*NUM_HERMITE ] - REAL* accum0; + real_t* accum0; // [ 8 * NUM_SWAP_QUOTES * POP_SIZE ] // { mux, muy, sqrt_sigmax = sqrt(2.0) * sigmax, // t2 = rhoxy / (sigmax*rhoxycs), sigmay_rhoxycs, zc_mat, f, df } - REAL* scalars; + real_t* scalars; - REAL gene_ranges[10]; + real_t gene_ranges[10]; CpuArrays (const uint n, short* shp) : SS(n) { shape = shp; - genomes = new REAL[ 13 * POP_SIZE ]; - ci_t1cs_scale = new REAL[ 4 * SS * POP_SIZE ]; - scalars = new REAL[ 8 * NUM_SWAP_QUOTES * POP_SIZE ]; + genomes = new real_t[ 13 * POP_SIZE ]; + ci_t1cs_scale = new real_t[ 4 * SS * POP_SIZE ]; + scalars = new real_t[ 8 * NUM_SWAP_QUOTES * POP_SIZE ]; - new_quote_price = new REAL [ 2 * NUM_SWAP_QUOTES * POP_SIZE ]; - accum0 = new REAL [ NUM_SWAP_QUOTES * NUM_HERMITE * POP_SIZE ]; + new_quote_price = new real_t [ 2 * NUM_SWAP_QUOTES * POP_SIZE ]; + accum0 = new real_t [ NUM_SWAP_QUOTES * NUM_HERMITE * POP_SIZE ]; for(int i=0; i<5; i++) { gene_ranges[i] = g_mins[i]; } for(int i=0; i<5; i++) { gene_ranges[i+5] = g_maxs[i]; } @@ -67,39 +67,39 @@ struct CpuArrays { } // genome helpers - REAL* get_a () { return genomes; } - REAL* get_b () { return genomes + POP_SIZE*2; } - REAL* get_rho () { return genomes + POP_SIZE*4; } - REAL* get_nu () { return genomes + POP_SIZE*6; } - REAL* get_sigma () { return genomes + POP_SIZE*8; } - REAL* get_logLik() { return genomes + POP_SIZE*10;} - REAL* get_bf_rat() { return genomes + POP_SIZE*12;} + real_t* get_a () { return genomes; } + real_t* get_b () { return genomes + POP_SIZE*2; } + real_t* get_rho () { return genomes + POP_SIZE*4; } + real_t* get_nu () { return genomes + POP_SIZE*6; } + real_t* get_sigma () { return genomes + POP_SIZE*8; } + real_t* get_logLik() { return genomes + POP_SIZE*10;} + real_t* get_bf_rat() { return genomes + POP_SIZE*12;} // get the shape of the irregular array (for one genome) short* get_shape (){ return shape; } // get the start iterator into arrays ci, t1cs, scale for genome i - REAL* get_ci (int i) { return ci_t1cs_scale + SS*i; } - REAL* get_t1cs (int i) { return ci_t1cs_scale + SS*i + SS*POP_SIZE; } - REAL* get_scale (int i) { return ci_t1cs_scale + SS*i + 2*SS*POP_SIZE; } - REAL* get_bbi (int i) { return ci_t1cs_scale + SS*i + 3*SS*POP_SIZE; } + real_t* get_ci (int i) { return ci_t1cs_scale + SS*i; } + real_t* get_t1cs (int i) { return ci_t1cs_scale + SS*i + SS*POP_SIZE; } + real_t* get_scale (int i) { return ci_t1cs_scale + SS*i + 2*SS*POP_SIZE; } + real_t* get_bbi (int i) { return ci_t1cs_scale + SS*i + 3*SS*POP_SIZE; } // get the start iterator into array-expanded scalars for genome i - REAL* get_mux (int i) { return scalars + i * NUM_SWAP_QUOTES ; } - REAL* get_muy (int i) { return scalars + i * NUM_SWAP_QUOTES + NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_sqsigx(int i) { return scalars + i * NUM_SWAP_QUOTES + 2 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_t2 (int i) { return scalars + i * NUM_SWAP_QUOTES + 3 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_sigrho(int i) { return scalars + i * NUM_SWAP_QUOTES + 4 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_zcmat (int i) { return scalars + i * NUM_SWAP_QUOTES + 5 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_f (int i) { return scalars + i * NUM_SWAP_QUOTES + 6 * NUM_SWAP_QUOTES * POP_SIZE; } - REAL* get_df (int i) { return scalars + i * NUM_SWAP_QUOTES + 7 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_mux (int i) { return scalars + i * NUM_SWAP_QUOTES ; } + real_t* get_muy (int i) { return scalars + i * NUM_SWAP_QUOTES + NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_sqsigx(int i) { return scalars + i * NUM_SWAP_QUOTES + 2 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_t2 (int i) { return scalars + i * NUM_SWAP_QUOTES + 3 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_sigrho(int i) { return scalars + i * NUM_SWAP_QUOTES + 4 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_zcmat (int i) { return scalars + i * NUM_SWAP_QUOTES + 5 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_f (int i) { return scalars + i * NUM_SWAP_QUOTES + 6 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_df (int i) { return scalars + i * NUM_SWAP_QUOTES + 7 * NUM_SWAP_QUOTES * POP_SIZE; } // get the quotes prices for genome i - REAL* get_quote (int i) { return new_quote_price + i * NUM_SWAP_QUOTES; } - REAL* get_price (int i) { return new_quote_price + i * NUM_SWAP_QUOTES + NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_quote (int i) { return new_quote_price + i * NUM_SWAP_QUOTES; } + real_t* get_price (int i) { return new_quote_price + i * NUM_SWAP_QUOTES + NUM_SWAP_QUOTES * POP_SIZE; } // get the accumulator for the irregular array for genome i - REAL* get_accum (int i) { return accum0 + i * NUM_SWAP_QUOTES * NUM_HERMITE; } + real_t* get_accum (int i) { return accum0 + i * NUM_SWAP_QUOTES * NUM_HERMITE; } }; /**************************************/ @@ -177,7 +177,7 @@ struct OclObjects { /*** Filling the OpenCL data structures ***/ /******************************************/ void compileGPUprog( OclObjects& objs ) { - char compile_option[512]; + char compile_option[1024]; #ifdef MAC // Build the program with 'mad' Optimization option @@ -186,10 +186,12 @@ void compileGPUprog( OclObjects& objs ) { char flags[] = ""; #endif - //sprintf( compile_option, "-I. -I SrcCL -D TODAY=%10f -D LWG_FB=%d -D INFTY=%f", TODAY, LWG_FB, INFTY ); - sprintf( compile_option, "%s -I. -I SrcCL -I../includeC -D lgWARP=%d -D TODAY=%10f -D LWG_FB=%d -D INFTY=%f -D MAX_DATE=%f -D MIN_DATE=%f -D SOBOL_BITS_NUM=%d", - flags, lgWARP, TODAY, LWG_FB, INFTY, MAX_DATE, MIN_DATE, NUM_SOBOL_BITS ); + sprintf( compile_option, "%s -D lgWARP=%d -D TODAY=%10f -D LWG_FB=%d -D INFTY=%f -D MAX_DATE=%f -D MIN_DATE=%f -D SOBOL_BITS_NUM=%d -D%s -I%s/include -I%s/include -I%s/SrcCL", + flags, lgWARP, TODAY, LWG_FB, INFTY, MAX_DATE, MIN_DATE, NUM_SOBOL_BITS, + REAL_FLAG, + HIPERMARK_BENCHMARK_LIB_DIR, HIPERMARK_LIB_DIR, HIPERMARK_IMPLEMENTATION_DIR); + fprintf(stderr, "compiling like this: %s\n", compile_option); objs.dev_id = 0; cl_uint nDevice; build_for_GPU( @@ -210,7 +212,7 @@ void makeOclBuffers ( CpuArrays& cpu_arrs, OclObjects& ocl_objs, OclBuffers& ocl size_t cur_size; cl_command_queue& cmd_queue = ocl_objs.getCommandQueue(); - cur_size = LWG_FB * sizeof(REAL); + cur_size = LWG_FB * sizeof(real_t); ocl_arrs.best_val = clCreateBuffer( ocl_objs.context, CL_MEM_READ_WRITE, cur_size, NULL, &ciErr2); ciErr |= ciErr2; cur_size = LWG_FB * sizeof(uint); @@ -222,17 +224,17 @@ void makeOclBuffers ( CpuArrays& cpu_arrs, OclObjects& ocl_objs, OclBuffers& ocl ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.shape, CL_TRUE, 0, cur_size, cpu_arrs.shape, 0, NULL, NULL); // swaption quotes - cur_size = 4 * NUM_SWAP_QUOTES * sizeof(REAL); + cur_size = 4 * NUM_SWAP_QUOTES * sizeof(real_t); ocl_arrs.swap_quotes = clCreateBuffer( ocl_objs.context, CL_MEM_READ_ONLY, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.swap_quotes, CL_TRUE, 0, cur_size, SwaptionQuotes, 0, NULL, NULL); // gene ranges - cur_size = 10 * sizeof(REAL); + cur_size = 10 * sizeof(real_t); ocl_arrs.gene_ranges = clCreateBuffer( ocl_objs.context, CL_MEM_READ_ONLY, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.gene_ranges, CL_TRUE, 0, cur_size, cpu_arrs.gene_ranges, 0, NULL, NULL); // sobol direction vector - cur_size = 30 * sizeof(REAL); + cur_size = 30 * sizeof(real_t); ocl_arrs.sobol_dir_vct = clCreateBuffer( ocl_objs.context, CL_MEM_READ_ONLY, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.sobol_dir_vct, CL_TRUE, 0, cur_size, SobolDirVct, 0, NULL, NULL); @@ -241,29 +243,29 @@ void makeOclBuffers ( CpuArrays& cpu_arrs, OclObjects& ocl_objs, OclBuffers& ocl ocl_arrs.accept_cond = clCreateBuffer( ocl_objs.context, CL_MEM_READ_WRITE, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; // GaussHermite coefficients and weights! - cur_size = NUM_HERMITE * sizeof(REAL); + cur_size = NUM_HERMITE * sizeof(real_t); ocl_arrs.gauss_coefs = clCreateBuffer( ocl_objs.context, CL_MEM_READ_ONLY, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.gauss_coefs, CL_TRUE, 0, cur_size, HermiteCoeffs, 0, NULL, NULL); ocl_arrs.gauss_weights = clCreateBuffer( ocl_objs.context, CL_MEM_READ_ONLY, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.gauss_weights, CL_TRUE, 0, cur_size, HermiteWeights, 0, NULL, NULL); - cur_size = 13 * POP_SIZE * sizeof(REAL); + cur_size = 13 * POP_SIZE * sizeof(real_t); ocl_arrs.genomes = clCreateBuffer( ocl_objs.context, CL_MEM_READ_WRITE, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; // ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.genomes, CL_TRUE, 0, cur_size, cpu_arrs.genomes, 0, NULL, NULL); - cur_size = 4 * cpu_arrs.SS * POP_SIZE * sizeof(REAL); + cur_size = 4 * cpu_arrs.SS * POP_SIZE * sizeof(real_t); ocl_arrs.ci_t1cs_scale = clCreateBuffer( ocl_objs.context, CL_MEM_READ_WRITE, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; // ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.ci_t1cs_scale, CL_TRUE, 0, cur_size, cpu_arrs.ci_t1cs_scale, 0, NULL, NULL); - cur_size = 2 * NUM_SWAP_QUOTES * POP_SIZE * sizeof(REAL); + cur_size = 2 * NUM_SWAP_QUOTES * POP_SIZE * sizeof(real_t); ocl_arrs.new_quote_price = clCreateBuffer( ocl_objs.context, CL_MEM_READ_WRITE, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; // ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.new_quote_price, CL_TRUE, 0, cur_size, cpu_arrs.new_quote_price, 0, NULL, NULL); - cur_size = 8 * NUM_SWAP_QUOTES * POP_SIZE * sizeof(REAL); + cur_size = 8 * NUM_SWAP_QUOTES * POP_SIZE * sizeof(real_t); ocl_arrs.scalars = clCreateBuffer( ocl_objs.context, CL_MEM_READ_WRITE, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; // ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.scalars, CL_TRUE, 0, cur_size, cpu_arrs.scalars, 0, NULL, NULL); - cur_size = NUM_SWAP_QUOTES * NUM_HERMITE * POP_SIZE * sizeof(REAL); + cur_size = NUM_SWAP_QUOTES * NUM_HERMITE * POP_SIZE * sizeof(real_t); ocl_arrs.accum0 = clCreateBuffer( ocl_objs.context, CL_MEM_READ_WRITE, cur_size, NULL, &ciErr2 ); ciErr |= ciErr2; // ciErr |= clEnqueueWriteBuffer(cmd_queue, ocl_arrs.accum0, CL_TRUE, 0, cur_size, cpu_arrs.accum0, 0, NULL, NULL); diff --git a/benchmarks/InterestCalib/implementations/cpp_opencl/static_configuration_template.json b/benchmarks/InterestCalib/implementations/cpp_opencl/static_configuration_template.json new file mode 100644 index 0000000..00bdffb --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_opencl/static_configuration_template.json @@ -0,0 +1,3 @@ +{ + "REAL_TYPE" : ["float", "double"] +} diff --git a/benchmarks/InterestCalib/implementations/cpp_openmp/.gitignore b/benchmarks/InterestCalib/implementations/cpp_openmp/.gitignore new file mode 100644 index 0000000..cd95011 --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_openmp/.gitignore @@ -0,0 +1 @@ +GenPricing diff --git a/InterestCalib/CppOpenMP/GenAlgFlat.h b/benchmarks/InterestCalib/implementations/cpp_openmp/GenAlgFlat.h similarity index 87% rename from InterestCalib/CppOpenMP/GenAlgFlat.h rename to benchmarks/InterestCalib/implementations/cpp_openmp/GenAlgFlat.h index 4dac1f3..257cd0d 100644 --- a/InterestCalib/CppOpenMP/GenAlgFlat.h +++ b/benchmarks/InterestCalib/implementations/cpp_openmp/GenAlgFlat.h @@ -11,14 +11,14 @@ /** * Printing Swaption / Calibrated Price / Black Price / RMS - * The result is an array REAL[NUM_SWAP_QUOTES, 3] recording + * The result is an array real_t[NUM_SWAP_QUOTES, 3] recording * for each swaption the calibrated price, the black price * and the percentagewise difference between the two. */ -REAL* makeSummary(uint winner, CpuArrays& arrs) { - REAL* res = (REAL*) malloc( 3*NUM_SWAP_QUOTES*sizeof(REAL) ); +real_t* makeSummary(uint winner, CpuArrays& arrs) { + real_t* res = (real_t*) malloc( 3*NUM_SWAP_QUOTES*sizeof(real_t) ); - REAL rms = 0.0; + real_t rms = 0.0; fprintf(stderr, "\n\nCALIBRATION RESULT: best genome is at index %d: ", winner); fprintf(stderr, "{ a = %f, b = %f, sigma = %f, nu = %f, rho = %f }, Likelihood: %f!\n", @@ -27,9 +27,9 @@ REAL* makeSummary(uint winner, CpuArrays& arrs) { fprintf(stderr, "\nPer-Swaption Approximation w.r.t. Black Price:\n\n"); for( int i = 0; i < NUM_SWAP_QUOTES; i ++ ) { - REAL black_price = arrs.get_quote(winner)[i]; - REAL calib_price = arrs.get_price(winner)[i]; - REAL err_ratio = (calib_price - black_price) / black_price; + real_t black_price = arrs.get_quote(winner)[i]; + real_t calib_price = arrs.get_price(winner)[i]; + real_t err_ratio = (calib_price - black_price) / black_price; res[3*i + 0] = 10000.0*calib_price; res[3*i + 1] = 10000.0*black_price; @@ -54,7 +54,7 @@ REAL* makeSummary(uint winner, CpuArrays& arrs) { * scans the logLik array and fill in the index and likelihood * of the best genome. */ -void find_best(const REAL* logLik, int& best_ind, REAL& best_lik) { +void find_best(const real_t* logLik, int& best_ind, real_t& best_lik) { bool sanity = true; best_lik = -INFINITY; @@ -63,7 +63,7 @@ void find_best(const REAL* logLik, int& best_ind, REAL& best_lik) { // this is in fact a reduction, but POP_SIZE is // not big enough to warrant a parallel execution. for ( UINT i = 0; i < POP_SIZE; i++ ) { // parallel reduction with MAX - REAL val = logLik[i]; + real_t val = logLik[i]; sanity = !( isnan(val) || isinf(val) ); assert( sanity && "val is NaN in find_best" ); @@ -72,10 +72,10 @@ void find_best(const REAL* logLik, int& best_ind, REAL& best_lik) { } } -Move_Type selectMoveType(REAL move_selected) { +Move_Type selectMoveType(real_t move_selected) { Move_Type move_type = NONE; - REAL prob; + real_t prob; Move_Type type; UINT k = 0; do { @@ -102,19 +102,19 @@ Move_Type selectMoveType(REAL move_selected) { * price, the black price and the percentage * difference between the two. */ -REAL* mainKernelCPU(REAL& wg_a, - REAL& wg_b, - REAL& wg_sigma, - REAL& wg_nu, - REAL& wg_rho, - REAL& wg_logLik +real_t* mainKernelCPU(real_t& wg_a, + real_t& wg_b, + real_t& wg_sigma, + real_t& wg_nu, + real_t& wg_rho, + real_t& wg_logLik ) { uint FLAT_SZ; short* shape = getIregShapeAdjusted( LWG_EG, FLAT_SZ ); int * start_inds = getStartInd( FLAT_SZ, shape, NUM_SWAP_QUOTES ); CpuArrays cpu_arrs(FLAT_SZ, shape); - REAL *g_a, *g_b, *g_rho, *g_nu, *g_sigma, *logLik, *bf_rat; + real_t *g_a, *g_b, *g_rho, *g_nu, *g_sigma, *logLik, *bf_rat; { // getting the cpu arrays g_a = cpu_arrs.get_a (); g_b = cpu_arrs.get_b (); @@ -131,7 +131,7 @@ REAL* mainKernelCPU(REAL& wg_a, // initialized the genomes with random numbers inside // their acceptable bounds => requires 5*POP_SIZE randoms for( int i = 0; i < POP_SIZE; i++ ) { - REAL r01, tmp; + real_t r01, tmp; r01 = getRandRandNorm(); tmp = r01 * ( g_maxs[0] - g_mins[0]) + g_mins[0]; @@ -177,7 +177,7 @@ REAL* mainKernelCPU(REAL& wg_a, // select which move to perform. // Note: this block can also be a loop (in fixed order) // over the various move types - REAL move_selected = getRandUnifNorm(); + real_t move_selected = getRandUnifNorm(); Move_Type move_type = selectMoveType(move_selected); if ( move_type == DIMS_ALL ) { @@ -214,11 +214,11 @@ REAL* mainKernelCPU(REAL& wg_a, // obtained by mutating/crossover of the individual. for ( int i = 0; i < POP_SIZE; i++ ) { // parallel // Metropolis: get a random U[0,1) for each candidate - REAL rand = getRandUnifNorm(); + real_t rand = getRandUnifNorm(); // selection: dimensions considered independent // acceptance = min( 1, N.exp(c.logLik_proposal-c.logLik) * c.backward_forward_ratio ) - REAL acceptance = std::min( 1.0, exp( logLik[i+POP_SIZE] - logLik[i] ) * bf_rat[i] ); + real_t acceptance = std::min( 1.0, exp( logLik[i+POP_SIZE] - logLik[i] ) * bf_rat[i] ); // if acceptance criterion is met then p->p' else does nothing if ( rand < acceptance ) accept( i, g_a, g_b, g_rho, g_nu, g_sigma, logLik ); @@ -226,16 +226,16 @@ REAL* mainKernelCPU(REAL& wg_a, // print best candidate for the current iteration: if ( (j % 16) == 0 ){ - int best_ind; REAL best_lik; + int best_ind; real_t best_lik; find_best(logLik, best_ind, best_lik); fprintf(stderr, "\n Iteration: %d: Best Likelihood: %f, genome index: %d!\n", j, best_lik, best_ind ); } } - REAL* result; + real_t* result; { // print best candidate for the current iteration: - int best_ind; REAL best_lik; + int best_ind; real_t best_lik; find_best(logLik, best_ind, best_lik); // recompute the calibrated price and the black price! diff --git a/benchmarks/InterestCalib/implementations/cpp_openmp/Makefile b/benchmarks/InterestCalib/implementations/cpp_openmp/Makefile new file mode 100644 index 0000000..da969e5 --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_openmp/Makefile @@ -0,0 +1,36 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +# Default to double if nothing else defined. +HIPERMARK_CONFIG_REAL_TYPE ?= double + +include $(HIPERMARK_LIB_DIR)/setup.mk +include $(HIPERMARK_LIB_DIR)/setup_real_type.mk + +INCLUDES += -I$(HIPERMARK_BENCHMARK_LIB_DIR)/include +INCLUDES += -I$(HIPERMARK_LIB_DIR)/include +INCLUDES += -I$(HIPERMARK_IMPLEMENTATION_DIR) + +#-fno-unsafe-math-optimizations -fno-finite-math-only +#-fmath-errno -ftrapping-math -fno-rounding-math -fsignaling-nans + +HELPERS =$(HIPERMARK_BENCHMARK_LIB_DIR)/include/ParseInput.h +OBJECTS =SwapCalib.o +EXECUTABLE =SwapCalib + +default: $(EXECUTABLE) + +%.o: $(HIPERMARK_IMPLEMENTATION_DIR)/%.cpp $(HELPERS) + $(CXX) $(CXXFLAGS) $(INCLUDES) -c -o $@ $< + +$(EXECUTABLE): $(OBJECTS) + $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) + +clean: + rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) + +HIPERMARK_DATA_FIELDS=population_size convergence_iterations num_swaption_quotes swaption_quotes num_hermite_coefficients hermite_coefficients hermite_coefficient_weights sobol_num_bits sobol_dir_vs +ifdef HIPERMARK_CONFIG_NUM_THREADS + HIPERMARK_RUN_ENVIRONMENT=OMP_NUM_THREADS=$(HIPERMARK_CONFIG_NUM_THREADS) +endif +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/benchmarks/InterestCalib/implementations/cpp_openmp/SwapCalib b/benchmarks/InterestCalib/implementations/cpp_openmp/SwapCalib new file mode 100755 index 0000000..e3164b7 Binary files /dev/null and b/benchmarks/InterestCalib/implementations/cpp_openmp/SwapCalib differ diff --git a/InterestCalib/CppOpenMP/SwapCalib.cpp b/benchmarks/InterestCalib/implementations/cpp_openmp/SwapCalib.cpp similarity index 57% rename from InterestCalib/CppOpenMP/SwapCalib.cpp rename to benchmarks/InterestCalib/implementations/cpp_openmp/SwapCalib.cpp index 231217d..34487f9 100644 --- a/InterestCalib/CppOpenMP/SwapCalib.cpp +++ b/benchmarks/InterestCalib/implementations/cpp_openmp/SwapCalib.cpp @@ -5,29 +5,30 @@ /*** (sequential) by LexiFi ***/ /*** and a sequential Python implem ***/ /*** using a different genetic alg.***/ -/*** by Christian Andreetta ***/ -/****************************************/ +/*** by Christian Andreetta ***/ +/****************************************/ #include "Util.h" #include "Constants.h" #include "ParseInput.h" #include "GenAlgFlat.h" +#include "WriteResult.h" int main() { - REAL wg_a = 0.0, wg_b = 0.0, wg_sigma = 0.0, - wg_nu = 0.0, wg_rho = 0.0, wg_logLik = 0.0; - REAL* calib_arr = NULL; + real_t wg_a = 0.0, wg_b = 0.0, wg_sigma = 0.0, + wg_nu = 0.0, wg_rho = 0.0, wg_logLik = 0.0; + real_t* calib_arr = NULL; printf("\n// Running Original (CPU Parallel) Swaption-Calibration Benchmark\n"); readDataSet( POP_SIZE, MCMC_LOOPS, - NUM_SWAP_QUOTES, SwaptionQuotes, + NUM_SWAP_QUOTES, SwaptionQuotes, NUM_HERMITE, HermiteCoeffs, HermiteWeights, NUM_SOBOL_BITS, SobolDirVct - ); + ); - unsigned long int elapsed = 0; + unsigned long int elapsed_usec = 0; { // Main Computational Kernel struct timeval t_start, t_end, t_diff; gettimeofday(&t_start, NULL); @@ -36,18 +37,29 @@ int main() gettimeofday(&t_end, NULL); timeval_subtract(&t_diff, &t_end, &t_start); - elapsed = t_diff.tv_sec*1e6+t_diff.tv_usec; + elapsed_usec = t_diff.tv_sec*1e6+t_diff.tv_usec; } { // validation and writeback of the result + FILE* runtime = fopen(getenv("HIPERMARK_RUNTIME"), "w"); + FILE* result = fopen(getenv("HIPERMARK_RESULT"), "w"); const int Ps = get_CPU_num_threads(); - bool is_valid = validate( wg_logLik, calib_arr, NUM_SWAP_QUOTES ); - writeStatsAndResult( is_valid, wg_a, wg_b, wg_sigma, wg_nu, wg_rho, - wg_logLik, calib_arr, NUM_SWAP_QUOTES, - false, Ps, elapsed ); + fprintf(runtime, "%d\n", elapsed_usec); + fclose(runtime); + + writeResult(result, + wg_a, + wg_b, + wg_sigma, + wg_nu, + wg_rho, + wg_logLik, + calib_arr); + + fclose(result); } - return 1; + return 0; } @@ -59,4 +71,3 @@ void test_all() { test_pricer_of_swaption(); } #endif - diff --git a/benchmarks/InterestCalib/implementations/cpp_openmp/UtilCPU.h b/benchmarks/InterestCalib/implementations/cpp_openmp/UtilCPU.h new file mode 100644 index 0000000..096451e --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_openmp/UtilCPU.h @@ -0,0 +1,102 @@ +#ifndef CPU_UTILITIES +#define CPU_UTILITIES + +/************************/ +/*** Helper Functions ***/ +/************************/ +bool is_pow2(uint n) { + uint c = 1; + while(c < n) { + c = c << 1; + } + return (c == n); +} + + +struct CpuArrays { + // size of the shape array + const uint SS; + + // shape of the irregular arrays for one genome + short* shape; + + // [13 * POP_SIZE] = + // { a, a_p, b, b_p, rho, rho_p, nu, nu_p, + // sigma, sigma_p, logLik, logLik_p, bf_rat } + real_t* genomes; + + // [ 4 * SS * POP_SIZE ] + real_t* ci_t1cs_scale; + + // [ 2 * NUM_SWAP_QUOTES * POP_SIZE ] + real_t* new_quote_price; + + // [ NUM_SWAP_QUOTES*NUM_HERMITE ] + real_t* accum0; + + // [ 8 * NUM_SWAP_QUOTES * POP_SIZE ] + // { mux, muy, sqrt_sigmax = sqrt(2.0) * sigmax, + // t2 = rhoxy / (sigmax*rhoxycs), sigmay_rhoxycs, zc_mat, f, df } + real_t* scalars; + + real_t gene_ranges[10]; + + CpuArrays (const uint n, short* shp) : SS(n) { + shape = shp; + + genomes = new real_t[ 13 * POP_SIZE ]; + ci_t1cs_scale = new real_t[ 4 * SS * POP_SIZE ]; + scalars = new real_t[ 8 * NUM_SWAP_QUOTES * POP_SIZE ]; + + new_quote_price = new real_t [ 2 * NUM_SWAP_QUOTES * POP_SIZE ]; + accum0 = new real_t [ NUM_SWAP_QUOTES * NUM_HERMITE * POP_SIZE ]; + + for(int i=0; i<5; i++) { gene_ranges[i] = g_mins[i]; } + for(int i=0; i<5; i++) { gene_ranges[i+5] = g_maxs[i]; } + } + + void releaseResources() { + delete[] shape; + delete[] genomes; + delete[] ci_t1cs_scale; + delete[] scalars; + delete[] new_quote_price; + delete[] accum0; + } + + // genome helpers + real_t* get_a () { return genomes; } + real_t* get_b () { return genomes + POP_SIZE*2; } + real_t* get_rho () { return genomes + POP_SIZE*4; } + real_t* get_nu () { return genomes + POP_SIZE*6; } + real_t* get_sigma () { return genomes + POP_SIZE*8; } + real_t* get_logLik() { return genomes + POP_SIZE*10;} + real_t* get_bf_rat() { return genomes + POP_SIZE*12;} + + // get the shape of the irregular array (for one genome) + short* get_shape (){ return shape; } + + // get the start iterator into arrays ci, t1cs, scale for genome i + real_t* get_ci (int i) { return ci_t1cs_scale + SS*i; } + real_t* get_t1cs (int i) { return ci_t1cs_scale + SS*i + SS*POP_SIZE; } + real_t* get_scale (int i) { return ci_t1cs_scale + SS*i + 2*SS*POP_SIZE; } + real_t* get_bbi (int i) { return ci_t1cs_scale + SS*i + 3*SS*POP_SIZE; } + + // get the start iterator into array-expanded scalars for genome i + real_t* get_mux (int i) { return scalars + i * NUM_SWAP_QUOTES ; } + real_t* get_muy (int i) { return scalars + i * NUM_SWAP_QUOTES + NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_sqsigx(int i) { return scalars + i * NUM_SWAP_QUOTES + 2 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_t2 (int i) { return scalars + i * NUM_SWAP_QUOTES + 3 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_sigrho(int i) { return scalars + i * NUM_SWAP_QUOTES + 4 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_zcmat (int i) { return scalars + i * NUM_SWAP_QUOTES + 5 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_f (int i) { return scalars + i * NUM_SWAP_QUOTES + 6 * NUM_SWAP_QUOTES * POP_SIZE; } + real_t* get_df (int i) { return scalars + i * NUM_SWAP_QUOTES + 7 * NUM_SWAP_QUOTES * POP_SIZE; } + + // get the quotes prices for genome i + real_t* get_quote (int i) { return new_quote_price + i * NUM_SWAP_QUOTES; } + real_t* get_price (int i) { return new_quote_price + i * NUM_SWAP_QUOTES + NUM_SWAP_QUOTES * POP_SIZE; } + + // get the accumulator for the irregular array for genome i + real_t* get_accum (int i) { return accum0 + i * NUM_SWAP_QUOTES * NUM_HERMITE; } +}; +#endif // CPU_UTILITIES diff --git a/benchmarks/InterestCalib/implementations/cpp_openmp/dynamic_configuration_template.json b/benchmarks/InterestCalib/implementations/cpp_openmp/dynamic_configuration_template.json new file mode 100644 index 0000000..713ae01 --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_openmp/dynamic_configuration_template.json @@ -0,0 +1 @@ +{ "NUM_THREADS": "ncpus" } diff --git a/benchmarks/InterestCalib/implementations/cpp_openmp/instantiate b/benchmarks/InterestCalib/implementations/cpp_openmp/instantiate new file mode 100755 index 0000000..2e76ab2 --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_openmp/instantiate @@ -0,0 +1,26 @@ +#!/bin/sh + +set -e + +cp $HIPERMARK_LIB_DIR/setup.mk . +cp $HIPERMARK_LIB_DIR/include/ParserC.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/ParseInput.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/WriteResult.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/Constants.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/KerConsts.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/GenAlgUtil.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/Date.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/Candidate.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/IrregShape.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/EvalGenomeInl.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/G2PP.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/G2ppUtil.h . +cp $HIPERMARK_BENCHMARK_LIB_DIR/include/MathModule.h . +cp $HIPERMARK_IMPLEMENTATION_DIR/*cpp $HIPERMARK_IMPLEMENTATION/*h $HIPERMARK_IMPLEMENTATION/Makefile . +cp $HIPERMARK_IMPLEMENTATION_DIR/run . +cp $HIPERMARK_LIB_DIR/include/Util.h . + + +$HIPERMARK_LIB_DIR/generate_platform_mk.py $HIPERMARK_PLATFORM > platform.mk + +make diff --git a/benchmarks/InterestCalib/implementations/cpp_openmp/static_configuration_template.json b/benchmarks/InterestCalib/implementations/cpp_openmp/static_configuration_template.json new file mode 100644 index 0000000..00bdffb --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_openmp/static_configuration_template.json @@ -0,0 +1,3 @@ +{ + "REAL_TYPE" : ["float", "double"] +} diff --git a/benchmarks/InterestCalib/implementations/cpp_sequential/EvalGenomeOrig.h b/benchmarks/InterestCalib/implementations/cpp_sequential/EvalGenomeOrig.h new file mode 100644 index 0000000..a315ca4 --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_sequential/EvalGenomeOrig.h @@ -0,0 +1,155 @@ +#ifndef EVAL_GENOME_INLINED +#define EVAL_GENOME_INLINED + +#include "Constants.h" +#include "GenAlgUtil.h" +#include "G2PP.h" +#include "G2PPorig.h" + + +/** + * MOST IMPORTANTLY: GENOME EVALUATION By Pricer of Swaption & BLACK PRICE + */ +void eval_genome_new ( + const real_t& a, + const real_t& b, + const real_t& rho, + const real_t& nu, + const real_t& sigma, + const real_t* swaption, + IntermElem* tmp_arrs, + real_t& new_quote, // output + real_t& new_price // output +) { + bool sanity = true; + + const real_t swap_freq = swaption[1]; + const real_t maturity = add_years( TODAY, swaption[0] ); + const UINT n_schedi = static_cast(12.0 * swaption[2] / swap_freq); + const real_t tmat0 = date_act_365( maturity, TODAY ); + + real_t strike; + { // BLACK PRICE computation + real_t lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; + + for(UINT i = 0; i < n_schedi; i++) { // reduce o map + // Map computes a1 and a2 (depends on i) + const real_t a1 = add_months( maturity, swap_freq*i ); + const real_t a2 = add_months( a1, swap_freq ); + + // Reduction( lvl: +, t0 : min, tn : max ) + lvl += zc(a2) * date_act_365(a2, a1); + t0 = std::min(t0, a1); + tn = std::max(tn, a2); + } + + strike = ( zc(t0) - zc(tn) ) / lvl; + const real_t d1 = 0.5 * swaption[3] * tmat0; + new_quote = lvl * strike * ( uGaussian_P(d1) - uGaussian_P(-d1) ); + } // END BLACK PRICE + + { // PRICER OF SWAPTION COMPUTATION + real_t v0_mat, dummy1, dummy2; + bigv( a, b, rho, nu, sigma, tmat0, v0_mat, dummy1, dummy2); +// + const real_t mux = - bigmx( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); + const real_t muy = - bigmy( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); +// + const real_t zc_mat = zc(maturity); +// + const real_t sqrt_bfun_a = sqrt( b_fun(2.0*a, tmat0) ); + const real_t sqrt_bfun_b = sqrt( b_fun(2.0*b, tmat0) ); + const real_t rhoxy = rho * b_fun(a+b, tmat0) / (sqrt_bfun_a * sqrt_bfun_b); + const real_t sigmax = sigma * sqrt_bfun_a; + const real_t sigmay = nu * sqrt_bfun_b; + + const real_t rhoxyc = 1.0 - rhoxy * rhoxy; // used in reduction kernel + const real_t rhoxycs = sqrt( rhoxyc ); // used in reduction kernel + const real_t sigmay_rhoxycs = sigmay * rhoxycs; + const real_t t4 = (rhoxy * sigmay) / sigmax; + + for( UINT i = 0; i < n_schedi; i++ ) { + const real_t beg_date = add_months( maturity, swap_freq*i ); //scheduleix[i]; + const real_t end_date = add_months( beg_date, swap_freq ); //scheduleiy[i]; + const real_t res = date_act_365( end_date, beg_date ) * strike; + + const real_t cii = ( i == n_schedi-1 ) ? 1.0 + res : res; + + real_t v0_end, vt_end, baii, bbii, date_tod1, date_tod2; + date_tod1 = date_act_365(end_date, TODAY); + bigv( a, b, rho, nu, sigma, date_tod1, v0_end, dummy1, dummy2 ); + date_tod2 = date_act_365(end_date, maturity); + bigv( a, b, rho, nu, sigma, date_tod2, vt_end, baii, bbii ); + + const real_t expo_aici = 0.5 * (vt_end - v0_end + v0_mat); + const real_t fact_aici = cii * zc(end_date) / zc_mat; + tmp_arrs[i].ci = fact_aici; // reuse the space to hold the factor of t1_cs + tmp_arrs[i].t1_cs = bbii * (mux * t4 - (muy - 0.5*rhoxyc*sigmay*sigmay*bbii) ) + expo_aici; + // hold only the exponent of the original t1_cs; + + tmp_arrs[i].bai = baii; + tmp_arrs[i].bbi = bbii; + tmp_arrs[i].aici = fact_aici * exp( expo_aici ); + tmp_arrs[i].log_aici = log( fact_aici ) + expo_aici; + tmp_arrs[i].scale = - ( baii + bbii * t4 ); + + sanity = ! ( isinf(tmp_arrs[i].aici) || isnan(tmp_arrs[i].aici) ); + assert(sanity && "Nan aici in pricer of swaption. Exiting!\n"); + } + + const real_t eps = 0.5 * sigmax; + + const real_t f = exactYhatOrig( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, + mux, muy, tmp_arrs, mux ); + + const real_t g = exactYhatOrig( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, + mux, muy, tmp_arrs, mux + eps ); + + const real_t h = exactYhatOrig( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, + mux, muy, tmp_arrs, mux - eps ); + + const real_t df = 0.5 * ( g - h ) / eps; + + const real_t sqrt2sigmax = sqrt(2.0) * sigmax;; + const real_t t2 = rhoxy / (sigmax*rhoxycs);; + + real_t accum = 0.0; + + for( UINT j = 0; j < NUM_HERMITE; j++ ) { + const real_t x_quad = HermiteCoeffs [j]; + const real_t w_quad = HermiteWeights[j]; + + const real_t x = sqrt2sigmax * x_quad + mux; + const real_t yhat_x = f + df*(x - mux); + const real_t h1 = ( (yhat_x - muy) / sigmay_rhoxycs ) - t2*( x - mux ); + + real_t accum1 = 0.0; + for( UINT i = 0; i < n_schedi; i++ ) { + const real_t h2 = h1 + tmp_arrs[i].bbi * sigmay_rhoxycs; + + const real_t expo_aici = tmp_arrs[i].t1_cs + tmp_arrs[i].scale*x; + const real_t fact_aici = tmp_arrs[i].ci; + const real_t expo_part = uGaussian_P_withExpFactor( -h2, expo_aici ); + accum1 += fact_aici * expo_part; + } + + sanity = ! ( isnan(accum1) || isinf(accum1) ); + assert(sanity && "Nan accum1 in pricer of swaption. Exiting!\n"); + + real_t tmp = sqrt(2.0) * x_quad; //(x - mux) / sigmax; + const real_t t1 = exp( - 0.5 * tmp * tmp ); + + accum += w_quad * t1 * ( uGaussian_P(-h1) - accum1 ); + } + + sanity = ! ( isnan(accum) || isinf(accum) ); + assert(sanity && "Nan accum1 in pricer of swaption. Exiting!\n"); + + new_price = zc_mat * ( accum / sqrt( PI ) ); + } +} + + + +#endif // end ifndef EVAL_GENOME_INLINED + diff --git a/InterestCalib/OrigCpp/G2PPorig.h b/benchmarks/InterestCalib/implementations/cpp_sequential/G2PPorig.h similarity index 61% rename from InterestCalib/OrigCpp/G2PPorig.h rename to benchmarks/InterestCalib/implementations/cpp_sequential/G2PPorig.h index 5f324a4..1e11294 100644 --- a/InterestCalib/OrigCpp/G2PPorig.h +++ b/benchmarks/InterestCalib/implementations/cpp_sequential/G2PPorig.h @@ -8,10 +8,10 @@ #include "GenAlgUtil.h" -REAL to_solve_orig( const UINT& N, +real_t to_solve_orig( const UINT& N, const IntermElem* tmp_arrs, - const REAL& yhat ) { - REAL accum = 0.0; + const real_t& yhat ) { + real_t accum = 0.0; for( UINT i = 0; i < N; i++ ) { accum += tmp_arrs[i].hat_scale * exp( - tmp_arrs[i].bbi * yhat ); } @@ -25,20 +25,20 @@ REAL to_solve_orig( const UINT& N, void rootFinding_Brent_orig ( const UINT& N, IntermElem* tmp_arrs, - const REAL& lb, - const REAL& ub, - const REAL& toll, + const real_t& lb, + const real_t& ub, + const real_t& toll, const UINT& it_mx, - REAL& root, // result + real_t& root, // result UINT& it, - REAL& fb + real_t& fb ) { - const REAL tol = (toll <= 0.0) ? 1.0e-9 : toll; - const REAL iter_max = (it_mx <= 0 ) ? IT_MAX : it_mx; + const real_t tol = (toll <= 0.0) ? 1.0e-9 : toll; + const real_t iter_max = (it_mx <= 0 ) ? IT_MAX : it_mx; - REAL a = lb, b = ub; + real_t a = lb, b = ub; - REAL fa = to_solve_orig(N, tmp_arrs, a); + real_t fa = to_solve_orig(N, tmp_arrs, a); fb = to_solve_orig(N, tmp_arrs, b); if( fa*fb >= 0.0 ) { @@ -48,22 +48,22 @@ void rootFinding_Brent_orig ( return; } - if( fabs(fa) < fabs(fb) ) { REAL tmp = fa; fa = fb; fb = tmp; tmp = a; a = b; b = tmp; } + if( fabs(fa) < fabs(fb) ) { real_t tmp = fa; fa = fb; fb = tmp; tmp = a; a = b; b = tmp; } - REAL c = a, fc = fa; + real_t c = a, fc = fa; bool mflag = true; - REAL d = 0.0; + real_t d = 0.0; it = 0; for( UINT i = 0; i < iter_max; i++ ) { if ( fb != 0.0 && fabs(b-a) >= tol ) { - REAL s; + real_t s; if( fa == fc || fb == fc ) { s = b - fb * (b - a) / (fb - fa); } else { - REAL s1 = (a*fb*fc)/( (fa-fb)*(fa-fc) ); - REAL s2 = (b*fa*fc)/( (fb-fa)*(fb-fc) ); - REAL s3 = (c*fa*fb)/( (fc-fa)*(fc-fb) ); + real_t s1 = (a*fb*fc)/( (fa-fb)*(fa-fc) ); + real_t s2 = (b*fa*fc)/( (fb-fa)*(fb-fc) ); + real_t s3 = (c*fa*fb)/( (fc-fa)*(fc-fb) ); s = s1 + s2 + s3; } @@ -78,7 +78,7 @@ void rootFinding_Brent_orig ( mflag = false; } - REAL fs = to_solve_orig(N, tmp_arrs, s); + real_t fs = to_solve_orig(N, tmp_arrs, s); // d is assigned for the first time here: // it's not used above because mflag is set @@ -89,7 +89,7 @@ void rootFinding_Brent_orig ( else { a = s; fa = fs; } if( fabs(fa) < fabs(fb) ) { - REAL tmp; + real_t tmp; tmp = a; a = b; b = tmp; tmp = fa; fa = fb; fb = tmp; } @@ -108,29 +108,29 @@ void rootFinding_Brent_orig ( //return BrentRes(b, it, fb); } -REAL exactYhatOrig( +real_t exactYhatOrig( const UINT& n_schedi, - const REAL& b, // scals begins - const REAL& sigmax, - const REAL& sigmay, - const REAL& rhoxy, - const REAL& rhoxyc, - const REAL& rhoxycs, - const REAL& mux, - const REAL& muy, // scals ends + const real_t& b, // scals begins + const real_t& sigmax, + const real_t& sigmay, + const real_t& rhoxy, + const real_t& rhoxyc, + const real_t& rhoxycs, + const real_t& mux, + const real_t& muy, // scals ends IntermElem* tmp_arrs, - const REAL& x // output + const real_t& x // output ) { // ugaussian_Pinv(k)=1.0e~4 - const REAL k = - 3.71901648545568; + const real_t k = - 3.71901648545568; - REAL up = 0.0, lo = -INFTY; + real_t up = 0.0, lo = -INFTY; for( UINT i = 0; i < n_schedi; i++ ) { - REAL baix = tmp_arrs[i].bai * x; + real_t baix = tmp_arrs[i].bai * x; - REAL up_term = tmp_arrs[i].aici * exp( -baix ); + real_t up_term = tmp_arrs[i].aici * exp( -baix ); tmp_arrs[i].hat_scale = up_term; up += up_term; lo = std::max( lo, ( tmp_arrs[i].log_aici - baix ) / tmp_arrs[i].bbi ); @@ -138,8 +138,8 @@ REAL exactYhatOrig( // CHECKING uplo!!!! - const REAL log_s = log(up); - REAL tmp = log_s / tmp_arrs[n_schedi-1].bbi; + const real_t log_s = log(up); + real_t tmp = log_s / tmp_arrs[n_schedi-1].bbi; if ( tmp <= 0.0 ) { up = tmp; @@ -149,20 +149,20 @@ REAL exactYhatOrig( else up = - INFTY; } - const REAL yl = lo - EPS; - const REAL yu = up + EPS; + const real_t yl = lo - EPS; + const real_t yu = up + EPS; - const REAL y0 = sigmay * ( rhoxy * (x-mux) / sigmax + k * rhoxycs ) - rhoxyc/b + muy; - const REAL y1 = sigmay * ( rhoxy * (x-mux) / sigmax - k * rhoxycs ) + muy; + const real_t y0 = sigmay * ( rhoxy * (x-mux) / sigmax + k * rhoxycs ) - rhoxyc/b + muy; + const real_t y1 = sigmay * ( rhoxy * (x-mux) / sigmax - k * rhoxycs ) + muy; - REAL res; + real_t res; if ( y1 <= yl ) res = y1 + 1.0; // yhat is greater than y1 => 1 - phi(h_i(x, yhat)) < EPS else if ( yu <= y0 ) res = y0 - 1.0; // yhat is lower than y0 => phi(h_i(x, yhat)) < EPS) else { - const REAL root_lb = std::max( yl, y0 ); - const REAL root_ub = std::min( yu, y1 ); + const real_t root_lb = std::max( yl, y0 ); + const real_t root_ub = std::min( yu, y1 ); - REAL root, error; UINT iter; + real_t root, error; UINT iter; rootFinding_Brent_orig(n_schedi, tmp_arrs, root_lb, root_ub, 1.0e-4, 1000, root, iter, error); //rootBisection(1, n_schedi, scales, bbi, root_lb, root_ub, 1.0e-4, 1000, root, iter, error); diff --git a/benchmarks/InterestCalib/implementations/cpp_sequential/GenAlgFlat.h b/benchmarks/InterestCalib/implementations/cpp_sequential/GenAlgFlat.h new file mode 100644 index 0000000..b8d3bde --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_sequential/GenAlgFlat.h @@ -0,0 +1,280 @@ +#ifndef GEN_ALG_FLAT +#define GEN_ALG_FLAT + +using namespace std; + +#include "Constants.h" +#include "GenAlgUtil.h" +#include "Genome.h" +#include "UtilCPU.h" +#include "EvalGenomeOrig.h" + + +/** + * Printing Swaption / Calibrated Price / Black Price / RMS + * The result is an array real_t[NUM_SWAP_QUOTES, 3] recording + * for each swaption the calibrated price, the black price + * and the percentagewise difference between the two. + */ +void makeSummary( const int winner, + const Genome& wgene, + const real_t* new_quote, + const real_t* new_price, + real_t* result // output + ) { + real_t rms = 0.0; + + fprintf(stderr, "\n\nCALIBRATION RESULT: best genome is at index %d: ", winner); + fprintf(stderr, "{ a = %f, b = %f, sigma = %f, nu = %f, rho = %f }, Likelihood: %f!\n", + wgene.a, wgene.b, wgene.sigma, wgene.nu, wgene.rho, wgene.logLik ); + fprintf(stderr, "\nPer-Swaption Approximation w.r.t. Black Price:\n\n"); + + for( int i = 0; i < NUM_SWAP_QUOTES; i ++ ) { + real_t black_price = new_quote[i]; + real_t calib_price = new_price[i]; + real_t err_ratio = (calib_price - black_price) / black_price; + + result[3*i + 0] = 10000.0*calib_price; + result[3*i + 1] = 10000.0*black_price; + result[3*i + 2] = 100.0*fabs(err_ratio); + + rms += err_ratio * err_ratio; + + fprintf(stderr,"Swaption %d: {{%f, %f, %f},%f}, CalibratedPrice: %f, BlackPrice: %f, DiffPerc: %f\n", + i, SwaptionQuotes[4*i+0], SwaptionQuotes[4*i+1], SwaptionQuotes[4*i+2], SwaptionQuotes[4*i+3], + result[3*i + 0], result[3*i + 1], result[3*i + 2] ); + } + + rms = 100.0 * sqrt ( rms / NUM_SWAP_QUOTES ); + fprintf(stderr, "\n\n Best Genome RMS: %f\n\n", rms); +} + + +/** + * Utility function: find the genome with the best likelihood: + * scans the logLik array and fill in the index and likelihood + * of the best genome. + */ +void find_best(const Genome* genomes, int& best_ind, real_t& best_lik) { + bool sanity = true; + + best_lik = -INFINITY; + best_ind = 0; + + // this is in fact a reduction, but POP_SIZE is + // not big enough to warrant a parallel execution. + for ( UINT i = 0; i < POP_SIZE; i++ ) { // parallel reduction with MAX + real_t val = genomes[i].logLik; + + sanity = !( isnan(val) || isinf(val) ); + assert( sanity && "val is NaN in find_best" ); + + if( val > best_lik ) { best_ind = i; best_lik = val; } + } +} + +Move_Type selectMoveType(real_t move_selected) { + Move_Type move_type = NONE; + + real_t prob; + Move_Type type; + UINT k = 0; + do { + prob = mcmc_moves_selection_cumdensfct[k].fst; + type = mcmc_moves_selection_cumdensfct[k].snd; + + if( move_selected <= prob ) { + move_type = type; + } + k ++; + } while ( move_selected > prob && k < CUMDENSFCT_CARD ); + + assert(move_type != NONE && "MOVE_TYPE == NONE is ILLEGAL!"); + + return move_type; +} + +/** + * Main Entry Point for Swaption Calibration + * The (out) arguments are in fact the resulted + * winning genome result & its likelihood. + * The array result has size 3*NUM_SWAP_QUOTES + * and records for each swaption the calibrated + * price, the black price and the percentage + * difference between the two. + */ +real_t* mainKernelSeqCPU( Genome& winner ) { + + UINT n_schedi_max = 0; + for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { + const UINT n_schedi = static_cast(12.0 * SwaptionQuotes[4*ttt+2] / SwaptionQuotes[4*ttt+1]); + n_schedi_max = max(n_schedi_max, n_schedi); + } + + SeqArrays cpu_arrs(n_schedi_max); + Genome* genomes = cpu_arrs.genomes; + + srand ( SEED ); + srand48 ( SEED ); + + // initialized the genomes with random numbers inside + // their acceptable bounds => requires 5*POP_SIZE randoms + for( int i = 0; i < POP_SIZE; i++ ) { + real_t r01, tmp; + + r01 = getRandRandNorm(); + tmp = r01 * ( g_maxs[0] - g_mins[0]) + g_mins[0]; + genomes[i].a = genomes[i+POP_SIZE].a = tmp; + + r01 = getRandRandNorm(); + tmp = r01 * ( g_maxs[1] - g_mins[1]) + g_mins[1]; + genomes[i].b = genomes[i+POP_SIZE].b = tmp; + + r01 = getRandRandNorm(); + tmp = r01 * ( g_maxs[2] - g_mins[2]) + g_mins[2]; + genomes[i].rho = genomes[i+POP_SIZE].rho = tmp; + + r01 = getRandRandNorm(); + tmp = r01 * ( g_maxs[3] - g_mins[3]) + g_mins[3]; + genomes[i].nu = genomes[i+POP_SIZE].nu = tmp; + + r01 = getRandRandNorm(); + tmp = r01 * ( g_maxs[4] - g_mins[4]) + g_mins[4]; + genomes[i].sigma = genomes[i+POP_SIZE].sigma = tmp; + + // genomes[i].fbRat = genomes[i+POP_SIZE].fbRat = 1.0; + } + + // Initial evaluation of the genomes! + real_t quote, price; + for( int i = 0; i < POP_SIZE; i++ ) { + Genome& gene = genomes[i]; + real_t rms = 0.0; + for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { + eval_genome_new ( + gene.a, gene.b, gene.rho, gene.nu, gene.sigma, + SwaptionQuotes+4*ttt, cpu_arrs.tmp_arrs, quote, price + ); + rms += logLikelihood( quote, price ); + } + gene.logLik = rms; + } + + // convergence loop that runs the genetic algorithms + // (takes a population and returns a population) + for( int j = 0; j < MCMC_LOOPS; j++ ) { + + // select which move to perform. + // Note: this block can also be a loop (in fixed order) + // over the various move types + real_t move_selected = getRandUnifNorm(); + Move_Type move_type = selectMoveType(move_selected); + + if ( move_type == DIMS_ALL ) { + for( int i = 0; i < POP_SIZE; i++ ) { + genomes[i+POP_SIZE].mutate_dims_all( genomes[i] ); + } + + } else if ( move_type == DIMS_ONE ) { + + UINT dim_j = getRandIntNorm(GENOME_DIM); + + for( int i = 0; i < POP_SIZE; i++ ) { + genomes[i+POP_SIZE].mutate_dims_one( genomes[i], dim_j ); + } + } else /* if ( move_type == DEMCMC ) */ { + + for ( int i = 0; i < POP_SIZE; i++ ) { // parallel modulo random nums + // compute the k^th and the l^th genes + UINT cand_UB = POP_SIZE - 1; + UINT k = getRandIntNorm(cand_UB); // random in [0,pop_size-1) + if ( k == i ) { + k = cand_UB; + cand_UB -= 1; + } + UINT l = getRandIntNorm(cand_UB); + if ( l == i || l == k ) { + l = cand_UB; + } + + // do DEMCMC base on k^th and l^th genomes + genomes[i+POP_SIZE].mcmc_DE( genomes[i], genomes[k], genomes[l] ); + } + } + + // evaluate the proposals + for( int i = 0; i < POP_SIZE; i++ ) { + Genome& gene = genomes[i+POP_SIZE]; + + real_t rms = 0.0; + for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { + eval_genome_new ( + gene.a, gene.b, gene.rho, gene.nu, gene.sigma, + SwaptionQuotes+4*ttt, cpu_arrs.tmp_arrs, quote, price + ); + rms += logLikelihood( quote, price ); + } + gene.logLik = rms; + } + + // mcmc_acceptance_rejection(); + // Deciding whether to accept or reject the proposal, + // obtained by mutating/crossover of the individual. + for ( int i = 0; i < POP_SIZE; i++ ) { // parallel + // Metropolis: get a random U[0,1) for each candidate + real_t rand = getRandUnifNorm(); + + Genome& orig = genomes[i]; + Genome& muta = genomes[i+POP_SIZE]; + // selection: dimensions considered independent + // acceptance = min( 1, N.exp(c.logLik_proposal-c.logLik) * c.backward_forward_ratio ) + real_t acceptance = std::min( 1.0, exp( muta.logLik - orig.logLik ) * muta.fbRat ); + + // if acceptance criterion is met then p->p' else does nothing + if ( rand < acceptance ) + orig = muta; + } + + // print best candidate for the current iteration: + if ( (j % 16) == 0 ){ + int best_ind; real_t best_lik; + find_best(genomes, best_ind, best_lik); + fprintf(stderr, "\n Iteration: %d: Best Likelihood: %f, genome index: %d!\n", + j, best_lik, best_ind ); + } + } + + real_t* result = new real_t[3*NUM_SWAP_QUOTES]; + { // print best candidate for the current iteration: + int best_ind; real_t best_lik; + find_best(genomes, best_ind, best_lik); + //winner = genomes[best_ind]; + winner.a = genomes[best_ind].a; winner.b = genomes[best_ind].b; + winner.rho = genomes[best_ind].rho; winner.nu = genomes[best_ind].nu; + winner.sigma = genomes[best_ind].sigma; winner.logLik = genomes[best_ind].logLik; + + // recompute the calibrated price and the black price! + real_t* quotes = cpu_arrs.get_quote(); + real_t* prices = cpu_arrs.get_price(); + for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { + eval_genome_new ( + winner.a, winner.b, winner.rho, winner.nu, winner.sigma, + SwaptionQuotes+4*ttt, cpu_arrs.tmp_arrs, quote, price + ); + quotes[ttt] = quote; + prices[ttt] = price; + } + + + + // write summary + makeSummary( best_ind, winner, quotes, prices, result ); + } + + // Releasing the CPU resources: + cpu_arrs.releaseResources(); + + return result; +} + +#endif // end ifndef GEN_ALG_FLAT diff --git a/InterestCalib/OrigCpp/Genome.h b/benchmarks/InterestCalib/implementations/cpp_sequential/Genome.h similarity index 73% rename from InterestCalib/OrigCpp/Genome.h rename to benchmarks/InterestCalib/implementations/cpp_sequential/Genome.h index a99d977..c7ce807 100644 --- a/InterestCalib/OrigCpp/Genome.h +++ b/benchmarks/InterestCalib/implementations/cpp_sequential/Genome.h @@ -28,28 +28,28 @@ * Genome min/max ranges and proposed initial values (not used) * { g_a, g_b, g_rho, g_nu, g_sigma } */ -const REAL g_mins [GENOME_DIM] = { EPS0, EPS0, -1.0+EPS0, EPS0, EPS0 }; -const REAL g_maxs [GENOME_DIM] = { 1.0-EPS0, 1.0-EPS0, 1.0-EPS0, 0.2, 0.2 }; -const REAL g_inis [GENOME_DIM] = { 0.02, 0.02, 0.0, 0.01, 0.04 }; -//const REAL Candidate::p_ref[GENOME_DIM] = { 1.0, -2.0, 0.5, -0.3, -0.5, 0.1 }; +const real_t g_mins [GENOME_DIM] = { EPS0, EPS0, -1.0+EPS0, EPS0, EPS0 }; +const real_t g_maxs [GENOME_DIM] = { 1.0-EPS0, 1.0-EPS0, 1.0-EPS0, 0.2, 0.2 }; +const real_t g_inis [GENOME_DIM] = { 0.02, 0.02, 0.0, 0.01, 0.04 }; +//const real_t Candidate::p_ref[GENOME_DIM] = { 1.0, -2.0, 0.5, -0.3, -0.5, 0.1 }; /** * perturbing a genome; requires one random uniform number in [0,1) */ inline -REAL perturbation( - const REAL gene, - const REAL gene_k, - const REAL gene_l, +real_t perturbation( + const real_t gene, + const real_t gene_k, + const real_t gene_l, const UINT i, - const REAL gamma1, - const REAL amplitude_ratio + const real_t gamma1, + const real_t amplitude_ratio ) { - REAL amplitude = fabs( (g_maxs[i] - g_mins[i]) * amplitude_ratio ); - REAL semiamplitude = amplitude / 2.0; - REAL r01 = getRandRandNorm(); - REAL perturb = ( amplitude * r01 - semiamplitude ); + real_t amplitude = fabs( (g_maxs[i] - g_mins[i]) * amplitude_ratio ); + real_t semiamplitude = amplitude / 2.0; + real_t r01 = getRandRandNorm(); + real_t perturb = ( amplitude * r01 - semiamplitude ); return ( gene + perturb + gamma1 * ( gene_k - gene_l ) ); } @@ -58,7 +58,7 @@ REAL perturbation( * contraining gene i to be within accepted bounds! */ inline -REAL constrain_dim1( const int i, const REAL gene ) { +real_t constrain_dim1( const int i, const real_t gene ) { return std::max( g_mins[i], std::min( g_maxs[i], gene ) ); } @@ -66,12 +66,12 @@ REAL constrain_dim1( const int i, const REAL gene ) { /** * Helper mutate function: requires one uniform random number */ -Tuple mutate_helper( const REAL gene, const REAL gene_prop, const int i, const REAL amplitude_ratio ) { - REAL forward_range, backward_range; - REAL tmp_min_max, tmp_max_min; +Tuple mutate_helper( const real_t gene, const real_t gene_prop, const int i, const real_t amplitude_ratio ) { + real_t forward_range, backward_range; + real_t tmp_min_max, tmp_max_min; - const REAL amplitude = fabs( (g_maxs[i] - g_mins[i]) * amplitude_ratio ); - const REAL semiamplitude = amplitude / 2.0; + const real_t amplitude = fabs( (g_maxs[i] - g_mins[i]) * amplitude_ratio ); + const real_t semiamplitude = amplitude / 2.0; tmp_min_max = std::min( g_maxs[i], gene + semiamplitude ); tmp_max_min = std::max( g_mins[i], gene - semiamplitude ); @@ -81,32 +81,32 @@ Tuple mutate_helper( const REAL gene, const REAL gene_prop, const int tmp_max_min = std::max( g_mins[i], gene_prop - semiamplitude ); backward_range = tmp_min_max - tmp_max_min; - const REAL bf_fact = ( semiamplitude > 0.0 ) ? (backward_range / forward_range) : 1.0; + const real_t bf_fact = ( semiamplitude > 0.0 ) ? (backward_range / forward_range) : 1.0; // assign p' - REAL r01 = getRandRandNorm(); - REAL diff = amplitude * r01 - semiamplitude; - return Tuple(gene + diff, bf_fact); + real_t r01 = getRandRandNorm(); + real_t diff = amplitude * r01 - semiamplitude; + return Tuple(gene + diff, bf_fact); } struct Genome { - REAL a; - REAL b; - REAL rho; - REAL nu; - REAL sigma; - REAL logLik; - REAL fbRat; - REAL padding; + real_t a; + real_t b; + real_t rho; + real_t nu; + real_t sigma; + real_t logLik; + real_t fbRat; + real_t padding; Genome() { this->a = 0.0; this->b = 0.0; this->rho = 0.0; this->nu = 0.0; this->sigma = 0.0; this->logLik = 0.0; this->fbRat = 0.0; } - Genome( const REAL a, const REAL b, const REAL rho, const REAL nu, - const REAL sigma, const REAL logLik, const REAL fbRat) { + Genome( const real_t a, const real_t b, const real_t rho, const real_t nu, + const real_t sigma, const real_t logLik, const real_t fbRat) { this->a = a; this->b = b; this->rho = rho; this->nu = nu; this->sigma = sigma; this->logLik = logLik; this->fbRat = fbRat; @@ -131,9 +131,9 @@ struct Genome { * done for all types of crossover/mutation/etc */ void mutate_dims_all( const Genome& orig, - const REAL amplitude_ratio = MOVES_UNIF_AMPL_RATIO ) { - REAL fb_rat = 1.0; - Tuple tmp(EPS0, 1.0); + const real_t amplitude_ratio = MOVES_UNIF_AMPL_RATIO ) { + real_t fb_rat = 1.0; + Tuple tmp(EPS0, 1.0); tmp = mutate_helper( orig.a, this->a, 0, amplitude_ratio ); this->a = constrain_dim1(0, tmp.fst); @@ -166,11 +166,11 @@ struct Genome { */ void mutate_dims_one( const Genome& orig, const int dim_j, - const REAL amplitude_ratio = MOVES_UNIF_AMPL_RATIO + const real_t amplitude_ratio = MOVES_UNIF_AMPL_RATIO ) { - REAL fb_rat = 1.0; + real_t fb_rat = 1.0; - Tuple tmp(EPS0, 1.0); + Tuple tmp(EPS0, 1.0); tmp = mutate_helper( orig.a, this->a, 0, (dim_j == 0) ? amplitude_ratio : 0.0 ); this->a = constrain_dim1(0, tmp.fst); fb_rat *= tmp.snd; @@ -200,13 +200,13 @@ struct Genome { void mcmc_DE( const Genome& orig, const Genome& gene_k, const Genome& gene_l, - const REAL gamma_avg = 2.38 / sqrt(2.0*GENOME_DIM), - const REAL ampl_ratio = 0.1 * MOVES_UNIF_AMPL_RATIO + const real_t gamma_avg = 2.38 / sqrt(2.0*GENOME_DIM), + const real_t ampl_ratio = 0.1 * MOVES_UNIF_AMPL_RATIO ) { // proposal // gamma: integrated out from the adviced // Multivariate Gaussian with Gaussian target (Braak, 2006) - REAL gamma1 = gamma_avg - 0.5 + getRandUnifNorm(); + real_t gamma1 = gamma_avg - 0.5 + getRandUnifNorm(); this->a = constrain_dim1( 0, perturbation( orig.a, gene_k.a, gene_l.a, 0, gamma1, ampl_ratio ) ); this->b = constrain_dim1( 1, perturbation( orig.b, gene_k.b, gene_l.b, 1, gamma1, ampl_ratio ) ); diff --git a/benchmarks/InterestCalib/implementations/cpp_sequential/Makefile b/benchmarks/InterestCalib/implementations/cpp_sequential/Makefile new file mode 100644 index 0000000..a177855 --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_sequential/Makefile @@ -0,0 +1,30 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +# Default to double if nothing else defined. +HIPERMARK_CONFIG_REAL_TYPE ?= double + +include $(HIPERMARK_LIB_DIR)/setup.mk +include $(HIPERMARK_LIB_DIR)/setup_real_type.mk + +INCLUDES += -I$(HIPERMARK_BENCHMARK_LIB_DIR)/include +INCLUDES += -I$(HIPERMARK_LIB_DIR)/include + +HELPERS =$(HIPERMARK_BENCHMARK_LIB_DIR)/include/ParseInput.h +OBJECTS =SwapCalib.o +EXECUTABLE =SwapCalib + +default: $(EXECUTABLE) + +%.o: $(HIPERMARK_IMPLEMENTATION_DIR)/%.cpp $(HELPERS) + $(CXX) $(CXXFLAGS) $(INCLUDES) -c -o $@ $< + +$(EXECUTABLE): $(OBJECTS) + $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) + +clean: + rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) + +HIPERMARK_DATA_FIELDS=population_size convergence_iterations num_swaption_quotes swaption_quotes num_hermite_coefficients hermite_coefficients hermite_coefficient_weights sobol_num_bits sobol_dir_vs +HIPERMARK_RUN_ENVIRONMENT= +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/InterestCalib/OrigCpp/SwapCalib.cpp b/benchmarks/InterestCalib/implementations/cpp_sequential/SwapCalib.cpp similarity index 59% rename from InterestCalib/OrigCpp/SwapCalib.cpp rename to benchmarks/InterestCalib/implementations/cpp_sequential/SwapCalib.cpp index 678a236..3d73a87 100644 --- a/InterestCalib/OrigCpp/SwapCalib.cpp +++ b/benchmarks/InterestCalib/implementations/cpp_sequential/SwapCalib.cpp @@ -11,11 +11,12 @@ #include "Constants.h" #include "ParseInput.h" #include "GenAlgFlat.h" +#include "WriteResult.h" int main() { Genome gene; - REAL* calib_arr = NULL; + real_t* calib_arr = NULL; printf("\n// Running Original Sequential Swaption-Calibration Benchmark\n"); @@ -25,7 +26,7 @@ int main() NUM_SOBOL_BITS, SobolDirVct ); - unsigned long int elapsed = 0; + unsigned long int elapsed_usec = 0; { // Main Computational Kernel struct timeval t_start, t_end, t_diff; gettimeofday(&t_start, NULL); @@ -34,16 +35,28 @@ int main() gettimeofday(&t_end, NULL); timeval_subtract(&t_diff, &t_end, &t_start); - elapsed = t_diff.tv_sec*1e6+t_diff.tv_usec; + elapsed_usec = t_diff.tv_sec*1e6+t_diff.tv_usec; } - { // validation and writeback of the result - bool is_valid = validate( gene.logLik, calib_arr, NUM_SWAP_QUOTES ); - writeStatsAndResult( is_valid, gene.a, gene.b, gene.sigma, gene.nu, gene.rho, - gene.logLik, calib_arr, NUM_SWAP_QUOTES, - false, 1, elapsed ); + { // writeback of the result + FILE* runtime = fopen(getenv("HIPERMARK_RUNTIME"), "w"); + FILE* result = fopen(getenv("HIPERMARK_RESULT"), "w"); + const int Ps = get_CPU_num_threads(); + fprintf(runtime, "%d\n", elapsed_usec); + fclose(runtime); + + writeResult(result, + gene.a, + gene.b, + gene.sigma, + gene.nu, + gene.rho, + gene.logLik, + calib_arr); + + fclose(result); } - return 1; + return 0; } diff --git a/InterestCalib/OrigCpp/UtilCPU.h b/benchmarks/InterestCalib/implementations/cpp_sequential/UtilCPU.h similarity index 63% rename from InterestCalib/OrigCpp/UtilCPU.h rename to benchmarks/InterestCalib/implementations/cpp_sequential/UtilCPU.h index c7d4640..b21da96 100644 --- a/InterestCalib/OrigCpp/UtilCPU.h +++ b/benchmarks/InterestCalib/implementations/cpp_sequential/UtilCPU.h @@ -2,14 +2,14 @@ #define CPU_UTILITIES struct IntermElem { - REAL ci; - REAL t1_cs; - REAL bai; - REAL bbi; - REAL aici; - REAL log_aici; - REAL scale; - REAL hat_scale; + real_t ci; + real_t t1_cs; + real_t bai; + real_t bbi; + real_t aici; + real_t log_aici; + real_t scale; + real_t hat_scale; IntermElem() { } }; @@ -26,13 +26,13 @@ struct SeqArrays { Genome* genomes; // [ 2 * NUM_SWAP_QUOTES ] - REAL* new_quote_price; + real_t* new_quote_price; SeqArrays (const uint m) : MaxSzTmpArrs(m) { genomes = new Genome[ 2 * POP_SIZE ]; tmp_arrs = new IntermElem[MaxSzTmpArrs]; - new_quote_price = new REAL [ 2 * NUM_SWAP_QUOTES ]; + new_quote_price = new real_t [ 2 * NUM_SWAP_QUOTES ]; } void releaseResources() { @@ -42,7 +42,7 @@ struct SeqArrays { } // get the quotes prices for genome i - REAL* get_quote () { return new_quote_price; } - REAL* get_price () { return new_quote_price + NUM_SWAP_QUOTES; } + real_t* get_quote () { return new_quote_price; } + real_t* get_price () { return new_quote_price + NUM_SWAP_QUOTES; } }; #endif // CPU_UTILITIES diff --git a/benchmarks/InterestCalib/implementations/cpp_sequential/static_configuration_template.json b/benchmarks/InterestCalib/implementations/cpp_sequential/static_configuration_template.json new file mode 100644 index 0000000..5087e27 --- /dev/null +++ b/benchmarks/InterestCalib/implementations/cpp_sequential/static_configuration_template.json @@ -0,0 +1,3 @@ +{ + "REAL_TYPE": ["float", "double"] +} diff --git a/InterestCalib/HaskellLH/Constants.hs b/benchmarks/InterestCalib/implementations/haskell_lh/Constants.hs similarity index 100% rename from InterestCalib/HaskellLH/Constants.hs rename to benchmarks/InterestCalib/implementations/haskell_lh/Constants.hs diff --git a/InterestCalib/HaskellLH/Date.hs b/benchmarks/InterestCalib/implementations/haskell_lh/Date.hs similarity index 100% rename from InterestCalib/HaskellLH/Date.hs rename to benchmarks/InterestCalib/implementations/haskell_lh/Date.hs diff --git a/InterestCalib/HaskellLH/EvalGenome.hs b/benchmarks/InterestCalib/implementations/haskell_lh/EvalGenome.hs similarity index 100% rename from InterestCalib/HaskellLH/EvalGenome.hs rename to benchmarks/InterestCalib/implementations/haskell_lh/EvalGenome.hs diff --git a/InterestCalib/HaskellLH/Genome.hs b/benchmarks/InterestCalib/implementations/haskell_lh/Genome.hs similarity index 100% rename from InterestCalib/HaskellLH/Genome.hs rename to benchmarks/InterestCalib/implementations/haskell_lh/Genome.hs diff --git a/benchmarks/InterestCalib/implementations/haskell_lh/Makefile b/benchmarks/InterestCalib/implementations/haskell_lh/Makefile new file mode 100644 index 0000000..3bc2035 --- /dev/null +++ b/benchmarks/InterestCalib/implementations/haskell_lh/Makefile @@ -0,0 +1,22 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +include $(HIPERMARK_LIB_DIR)/setup.mk + +SOURCES = SwapCalib.hs +EXECUTABLE = SwapCalib +OBJECTS = SwapCalib.hi SwapCalib.o + +GHC_FLAGS = -Wall -O2 -msse2 -rtsopts -i$(HIPERMARK_IMPLEMENTATION_DIR) + +default: $(EXECUTABLE) + +$(EXECUTABLE): $(HIPERMARK_IMPLEMENTATION_DIR)/$(SOURCES) + ghc $(HIPERMARK_IMPLEMENTATION_DIR)/$(SOURCES) $(GHC_FLAGS) -o $(EXECUTABLE) + +clean: + rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) + +HIPERMARK_DATA_FIELDS=population_size convergence_iterations num_swaption_quotes swaption_quotes num_hermite_coefficients hermite_coefficients hermite_coefficient_weights sobol_num_bits sobol_dir_vs +HIPERMARK_RUN_ENVIRONMENT= +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/InterestCalib/HaskellLH/MathMod.hs b/benchmarks/InterestCalib/implementations/haskell_lh/MathMod.hs similarity index 100% rename from InterestCalib/HaskellLH/MathMod.hs rename to benchmarks/InterestCalib/implementations/haskell_lh/MathMod.hs diff --git a/benchmarks/InterestCalib/implementations/haskell_lh/SwapCalib b/benchmarks/InterestCalib/implementations/haskell_lh/SwapCalib new file mode 100755 index 0000000..fd74e79 Binary files /dev/null and b/benchmarks/InterestCalib/implementations/haskell_lh/SwapCalib differ diff --git a/InterestCalib/HaskellLH/SwapCalib.hs b/benchmarks/InterestCalib/implementations/haskell_lh/SwapCalib.hs similarity index 74% rename from InterestCalib/HaskellLH/SwapCalib.hs rename to benchmarks/InterestCalib/implementations/haskell_lh/SwapCalib.hs index eeb638a..9121592 100644 --- a/InterestCalib/HaskellLH/SwapCalib.hs +++ b/benchmarks/InterestCalib/implementations/haskell_lh/SwapCalib.hs @@ -1,8 +1,11 @@ module Main where +import Control.DeepSeq import Control.Applicative import Control.Monad import Data.Maybe +import System.CPUTime +import System.Environment ------------------------------------ --- Requires the installation of --- @@ -208,56 +211,6 @@ compute pop_size num_mcmc_its swaption_quotes in (res_genome, res_logLik, res_swap_arr) - - - ----------------------------------------------- ---- Formatting the Output of the Benchmark --- ----------------------------------------------- -validate :: (Genome,Double,[[Double]]) -> - (Genome,Double,[[Double]]) -> - (Int,Int,Int) -> [String] -validate ref_res win_res (pop_size, num_mcmc_its, num_of_swaptions) = - let ((ref_a, ref_b, ref_rho, ref_nu, ref_sigma), ref_logLik, ref_swap_arr) = ref_res - ((win_a, win_b, win_rho, win_nu, win_sigma), win_logLik, win_swap_arr) = win_res - - (is_valid, err_msg) = - if (abs (ref_logLik - win_logLik)) > 1.0 - then (False, "Difference in logLikelihood > 1.0: result logLik " - ++ show win_logLik ++", reference logLik = " ++ show ref_logLik ++ "!") - else if (win_logLik < ref_logLik) && (abs (ref_logLik - win_logLik)) > 0.4 - then (False, "Result likelihood is worse than reference with more than 0.3: result logLik " - ++ show win_logLik ++ ", reference logLik = " ++ show ref_logLik ++ "!") - else foldl (\ (acc,err_msg) (ref_row, win_row, i) -> - if not acc then (acc, err_msg) - else let ref_logLik = logLikelihood (ref_row!!1) (ref_row!!0) - cur_logLik = logLikelihood (win_row!!1) (win_row!!0) - dif_logLik = if cur_logLik > ref_logLik - then 0.0 else ref_logLik - cur_logLik - in if dif_logLik > 1.1 - then (False, "Error[" ++ show i ++ "] = " ++ - show dif_logLik ++ ", Acceptable <= 1.1!") - else (True, err_msg) - ) - (True, "") (zip3 ref_swap_arr win_swap_arr [0..num_of_swaptions]) - - in ["// Swaption-Calibration Haskell Benchmark (List-Homomorphism Style):", - "// Dataset with Population "++show pop_size++", Convergence-Loop Count: " - ++show num_mcmc_its++", Number of Swaption Quotes = " ++ show num_of_swaptions ++ ".", - ( if is_valid - then "1\t\t// VALID Result," - else "0\t\t// INVALID Result," ++ err_msg ), - "0\t\t// Runtime in microseconds,", - "1\t\t// CPU Threads,", - show win_a ++ "\t// a-field of the winning genome", - show win_b ++ "\t// b-field of the winning genome", - show win_sigma ++ "\t// sigma-field of the winning genome", - show win_nu ++ "\t// nu-field of the winning genome", - show win_rho ++ "\t// rho-field of the winning genome", - show win_logLik ++ "\t// logLik-field of the winning genome", - show win_swap_arr ++ "\t//Reference Swaption Calibration Result: foreach swaption [CalibPrice,BlackPrice,PercentDiff]" ] - - ----------------------------------------- --- Entry point for Generic Pricing --- --- The only place where using Monads,--- @@ -267,10 +220,14 @@ main :: IO () main = do s <- getContents case parse run "input" s of Left e -> error $ show e - Right (p,pr,i) -> do let msg_lst = validate pr p i - _ <- mapM putStrLn msg_lst - putStrLn "" - where run = do pop_size <- readInt + Right m -> do + (v, runtime) <- m + result <- getEnv "HIPERMARK_RESULT" + writeFile result $ jsonish v + runtime_file <- getEnv "HIPERMARK_RUNTIME" + writeFile runtime_file $ show runtime + where run = do whitespace + pop_size <- readInt num_mcmc_its <- readInt num_swap_quotes <- readInt swaption_quotes <- readDouble2d @@ -285,25 +242,36 @@ main = do s <- getContents let swaption_quotes'= map (\x -> (x!!0, x!!1, x!!2, x!!3)) swaption_quotes - let (win_genome, win_logLik, win_swap_arr) = - compute pop_size num_mcmc_its swaption_quotes' + let (win_genome, win_logLik, win_swap_arr) = + compute pop_size num_mcmc_its swaption_quotes' hermite_coeffs hermite_weights (V.fromList sobol_dir_vct) - - ref_a <- readDouble - ref_b <- readDouble - ref_sigma <- readDouble - ref_nu <- readDouble - ref_rho <- readDouble - ref_logLik <- readDouble - ref_swap_arr <- readDouble2d - let ref_genome = (ref_a, ref_b, ref_rho, ref_nu, ref_sigma) - - return ( (win_genome, win_logLik, win_swap_arr), - (ref_genome, ref_logLik, ref_swap_arr), - (pop_size, num_mcmc_its, num_swap_quotes) ) + + return $ do + start <- getCPUTime -- In picoseconds; 1 microsecond == 10^6 picoseconds. + let v = (win_genome, win_logLik, win_swap_arr) + end <- v `deepseq` getCPUTime + return (v, (end - start) `div` 1000000) + readInt1d = readArray readInt readDouble1d = readArray readDouble readDouble2d = readArray $ readArray readDouble +jsonish :: (Genome, Double, [[Double]]) + -> String +jsonish ((win_a, win_b, win_rho, win_nu, win_sigma), win_logLik, win_swap_arr) = + unlines [ "{" + , intercalate ",\n" + [ field "a_field" win_a + , field "b_field" win_b + , field "sigma_field" win_sigma + , field "nu_field" win_nu + , field "rho_field" win_rho + , field "lg_likelyhood" win_logLik + , field "swaption_calibration_result" win_swap_arr + ] + , "}" + ] + where field k v = "\"" ++ k ++ "\": " ++ show v + -- ghc -O2 -msse2 -rtsopts PricingLexiFi.hs -- ./PricingLexiFi +RTS -K128m -RTS < ../Data/Medium/input.data diff --git a/InterestCalib/includeC/Candidate.h b/benchmarks/InterestCalib/lib/include/Candidate.h similarity index 65% rename from InterestCalib/includeC/Candidate.h rename to benchmarks/InterestCalib/lib/include/Candidate.h index 336e1d5..4916ef2 100644 --- a/InterestCalib/includeC/Candidate.h +++ b/benchmarks/InterestCalib/lib/include/Candidate.h @@ -27,28 +27,28 @@ * Genome min/max ranges and proposed initial values (not used) * { g_a, g_b, g_rho, g_nu, g_sigma } */ -const REAL g_mins [GENOME_DIM] = { EPS0, EPS0, -1.0+EPS0, EPS0, EPS0 }; -const REAL g_maxs [GENOME_DIM] = { 1.0-EPS0, 1.0-EPS0, 1.0-EPS0, 0.2, 0.2 }; -const REAL g_inis [GENOME_DIM] = { 0.02, 0.02, 0.0, 0.01, 0.04 }; -//const REAL Candidate::p_ref[GENOME_DIM] = { 1.0, -2.0, 0.5, -0.3, -0.5, 0.1 }; +const real_t g_mins [GENOME_DIM] = { EPS0, EPS0, -1.0+EPS0, EPS0, EPS0 }; +const real_t g_maxs [GENOME_DIM] = { 1.0-EPS0, 1.0-EPS0, 1.0-EPS0, 0.2, 0.2 }; +const real_t g_inis [GENOME_DIM] = { 0.02, 0.02, 0.0, 0.01, 0.04 }; +//const real_t Candidate::p_ref[GENOME_DIM] = { 1.0, -2.0, 0.5, -0.3, -0.5, 0.1 }; /** * perturbing a genome; requires one random uniform number in [0,1) */ inline -REAL perturbation( - const REAL gene, - const REAL gene_k, - const REAL gene_l, +real_t perturbation( + const real_t gene, + const real_t gene_k, + const real_t gene_l, const UINT i, - const REAL gamma1, - const REAL amplitude_ratio + const real_t gamma1, + const real_t amplitude_ratio ) { - REAL amplitude = fabs( (g_maxs[i] - g_mins[i]) * amplitude_ratio ); - REAL semiamplitude = amplitude / 2.0; - REAL r01 = getRandRandNorm(); - REAL perturb = ( amplitude * r01 - semiamplitude ); + real_t amplitude = fabs( (g_maxs[i] - g_mins[i]) * amplitude_ratio ); + real_t semiamplitude = amplitude / 2.0; + real_t r01 = getRandRandNorm(); + real_t perturb = ( amplitude * r01 - semiamplitude ); return ( gene + perturb + gamma1 * ( gene_k - gene_l ) ); } @@ -57,7 +57,7 @@ REAL perturbation( * contraining gene i to be within accepted bounds! */ inline -REAL constrain_dim1( const int i, const REAL gene ) { +real_t constrain_dim1( const int i, const real_t gene ) { return std::max( g_mins[i], std::min( g_maxs[i], gene ) ); } @@ -65,12 +65,12 @@ REAL constrain_dim1( const int i, const REAL gene ) { * accepting the proposal */ void accept(const int i, - REAL* g_a, // genome begins - REAL* g_b, - REAL* g_rho, - REAL* g_nu, - REAL* g_sigma, - REAL* logLik + real_t* g_a, // genome begins + real_t* g_b, + real_t* g_rho, + real_t* g_nu, + real_t* g_sigma, + real_t* logLik ) { g_a [i] = g_a [i+POP_SIZE]; g_b [i] = g_b [i+POP_SIZE]; @@ -83,12 +83,12 @@ void accept(const int i, /** * Helper mutate function: requires one uniform random number */ -Tuple mutate_helper( const REAL gene, const REAL gene_prop, const int i, const REAL amplitude_ratio ) { - REAL forward_range, backward_range; - REAL tmp_min_max, tmp_max_min; +Tuple mutate_helper( const real_t gene, const real_t gene_prop, const int i, const real_t amplitude_ratio ) { + real_t forward_range, backward_range; + real_t tmp_min_max, tmp_max_min; - const REAL amplitude = fabs( (g_maxs[i] - g_mins[i]) * amplitude_ratio ); - const REAL semiamplitude = amplitude / 2.0; + const real_t amplitude = fabs( (g_maxs[i] - g_mins[i]) * amplitude_ratio ); + const real_t semiamplitude = amplitude / 2.0; tmp_min_max = std::min( g_maxs[i], gene + semiamplitude ); tmp_max_min = std::max( g_mins[i], gene - semiamplitude ); @@ -98,12 +98,12 @@ Tuple mutate_helper( const REAL gene, const REAL gene_prop, const int tmp_max_min = std::max( g_mins[i], gene_prop - semiamplitude ); backward_range = tmp_min_max - tmp_max_min; - const REAL bf_fact = ( semiamplitude > 0.0 ) ? (backward_range / forward_range) : 1.0; + const real_t bf_fact = ( semiamplitude > 0.0 ) ? (backward_range / forward_range) : 1.0; // assign p' - REAL r01 = getRandRandNorm(); - REAL diff = amplitude * r01 - semiamplitude; - return Tuple(gene + diff, bf_fact); + real_t r01 = getRandRandNorm(); + real_t diff = amplitude * r01 - semiamplitude; + return Tuple(gene + diff, bf_fact); } /** @@ -112,17 +112,17 @@ Tuple mutate_helper( const REAL gene, const REAL gene_prop, const int * I took out the evaluation of the proposal, since it should be * done for all types of crossover/mutation/etc */ -void mutate_dims_all( REAL* g_a, // genome begins - REAL* g_b, - REAL* g_rho, - REAL* g_nu, - REAL* g_sigma, - REAL* g_fb_rat, +void mutate_dims_all( real_t* g_a, // genome begins + real_t* g_b, + real_t* g_rho, + real_t* g_nu, + real_t* g_sigma, + real_t* g_fb_rat, const int i, - const REAL amplitude_ratio = MOVES_UNIF_AMPL_RATIO ) { - REAL fb_rat = 1.0; + const real_t amplitude_ratio = MOVES_UNIF_AMPL_RATIO ) { + real_t fb_rat = 1.0; - Tuple tmp(EPS0, 1.0); + Tuple tmp(EPS0, 1.0); tmp = mutate_helper( g_a [i], g_a [i+POP_SIZE], 0, amplitude_ratio ); g_a [i + POP_SIZE] = constrain_dim1(0, tmp.fst); fb_rat *= tmp.snd; @@ -148,19 +148,19 @@ void mutate_dims_all( REAL* g_a, // genome begins * all population. Memory coalescence? * Requires POP_SIZE random uniform numbers! */ -void mutate_dims_one( REAL* g_a, // genome begins - REAL* g_b, - REAL* g_rho, - REAL* g_nu, - REAL* g_sigma, - REAL* g_fb_rat, +void mutate_dims_one( real_t* g_a, // genome begins + real_t* g_b, + real_t* g_rho, + real_t* g_nu, + real_t* g_sigma, + real_t* g_fb_rat, const int i, const int dim_j, - const REAL amplitude_ratio = MOVES_UNIF_AMPL_RATIO + const real_t amplitude_ratio = MOVES_UNIF_AMPL_RATIO ) { - REAL fb_rat = 1.0; + real_t fb_rat = 1.0; - Tuple tmp(EPS0, 1.0); + Tuple tmp(EPS0, 1.0); tmp = mutate_helper( g_a [i], g_a [i+POP_SIZE], 0, (dim_j == 0) ? amplitude_ratio : 0.0 ); g_a [i + POP_SIZE] = constrain_dim1(0, tmp.fst); fb_rat *= tmp.snd; @@ -183,15 +183,15 @@ void mutate_dims_one( REAL* g_a, // genome begins * Crossover * Requires a vector of size [ POP_SIZE*8 ] of random uniform numbers. */ -void mcmc_DE( REAL* g_a, // genome begins - REAL* g_b, - REAL* g_rho, - REAL* g_nu, - REAL* g_sigma, // genome ends - REAL* bf_rat, // fwd_bwd_ratio +void mcmc_DE( real_t* g_a, // genome begins + real_t* g_b, + real_t* g_rho, + real_t* g_nu, + real_t* g_sigma, // genome ends + real_t* bf_rat, // fwd_bwd_ratio const int j, - const REAL gamma_avg = 2.38 / sqrt(2.0*GENOME_DIM), - const REAL ampl_ratio = 0.1 * MOVES_UNIF_AMPL_RATIO + const real_t gamma_avg = 2.38 / sqrt(2.0*GENOME_DIM), + const real_t ampl_ratio = 0.1 * MOVES_UNIF_AMPL_RATIO ) { UINT cand_UB = POP_SIZE - 1; UINT k = getRandIntNorm(cand_UB); // random in [0,pop_size-1) @@ -207,7 +207,7 @@ void mcmc_DE( REAL* g_a, // genome begins // proposal // gamma: integrated out from the adviced // Multivariate Gaussian with Gaussian target (Braak, 2006) - REAL gamma1 = gamma_avg - 0.5 + getRandUnifNorm(); + real_t gamma1 = gamma_avg - 0.5 + getRandUnifNorm(); g_a [j + POP_SIZE] = constrain_dim1( 0, perturbation( g_a [j], g_a [k], g_a [l], 0, gamma1, ampl_ratio ) ); g_b [j + POP_SIZE] = constrain_dim1( 1, perturbation( g_b [j], g_b [k], g_b [l], 1, gamma1, ampl_ratio ) ); diff --git a/InterestCalib/includeC/Constants.h b/benchmarks/InterestCalib/lib/include/Constants.h similarity index 77% rename from InterestCalib/includeC/Constants.h rename to benchmarks/InterestCalib/lib/include/Constants.h index 357f6ba..5d22d72 100644 --- a/InterestCalib/includeC/Constants.h +++ b/benchmarks/InterestCalib/lib/include/Constants.h @@ -3,6 +3,8 @@ #include #include + +#include "real.h" #include "KerConsts.h" #ifdef __APPLE__ @@ -15,13 +17,13 @@ typedef uint UINT; /******** DATE RELATED STUFF *********/ /*************************************/ -#if WITH_FLOAT - const REAL INFTY = 1.0e38; +#if REAL_IS_FLOAT + const real_t INFTY = 1.0e38; #else - const REAL INFTY = 1.0e49; + const real_t INFTY = 1.0e49; #endif -bool equalEps(REAL x1, REAL x2) { +bool equalEps(real_t x1, real_t x2) { return ( fabs(x1-x2) <= 1.0e-8 ); } @@ -37,16 +39,16 @@ struct Date { }; //"2299-12-31T23:59:59" -REAL MAX_DATE = 168307199.0; +real_t MAX_DATE = 168307199.0; //"1980-01-01T12:00:00" -REAL MIN_DATE = 3600.0; +real_t MIN_DATE = 3600.0; #include "Date.h" // Date.of_string("2012-01-01") -const REAL TODAY = static_cast( date_of_gregorian( Date(2012, 1, 1, 12, 0) ) ); +const real_t TODAY = static_cast( date_of_gregorian( Date(2012, 1, 1, 12, 0) ) ); /*************************************/ @@ -60,7 +62,7 @@ const uint LWG_FB = 256; /*************************************/ /******** MATH RELATED STUFF *********/ /*************************************/ -//const REAL R = 0.03; +//const real_t R = 0.03; const uint IT_MAX= 10000; // a.k.a. itMax template @@ -71,14 +73,14 @@ struct Triple { struct SwapOfSwap { const UINT n; // size of swap_sched - REAL* swap_sched1; - REAL* swap_sched2; - REAL maturity; - REAL strike; + real_t* swap_sched1; + real_t* swap_sched2; + real_t maturity; + real_t strike; SwapOfSwap(const UINT len) : n(len) { - swap_sched1 = new REAL[n]; - swap_sched2 = new REAL[n]; + swap_sched1 = new real_t[n]; + swap_sched2 = new real_t[n]; } void cleanUp() { delete[] swap_sched1; @@ -90,13 +92,13 @@ struct SwapOfSwap { // Gaussian Quadrature with Hermite linear expansion: cmulative distribution function of Normal distribution UINT NUM_HERMITE; // 11 -REAL* HermiteCoeffs; // [NUM_HERMITE] -REAL* HermiteWeights;// [NUM_HERMITE] +real_t* HermiteCoeffs; // [NUM_HERMITE] +real_t* HermiteWeights;// [NUM_HERMITE] //========================================================================= UINT NUM_SWAP_QUOTES; //196 // 196 x { maturity_in_year * swap_frequency * swap_term_in_year * volatility } -REAL* SwaptionQuotes; //[NUM_SWAP_QUOTES,4] +real_t* SwaptionQuotes; //[NUM_SWAP_QUOTES,4] UINT NUM_SOBOL_BITS; // 30 int* SobolDirVct; // [SOBOL_BITS_NUM] @@ -109,14 +111,14 @@ int PROCS; const UINT SEED = 12345; const UINT GENOME_DIM = 5; -const REAL GENOME_SCALE = 1.0; +const real_t GENOME_SCALE = 1.0; // Likelihood Parameters enum Likelihood_Type { CAUCHY, NORMAL }; const Likelihood_Type LLHOOD_TYPE = CAUCHY; //NORMAL; -const REAL LLHOOD_CAUCHY_OFFS = 5.0; -const REAL LLHOOD_NORMAL_OFFS = 1.0; +const real_t LLHOOD_CAUCHY_OFFS = 5.0; +const real_t LLHOOD_NORMAL_OFFS = 1.0; // population @@ -127,7 +129,7 @@ UINT POP_SIZE; //const UINT MCMC_LOOPS = (UINT) ( 100.0 * (1.0 + log(GENOME_SCALE)) * // (2.0 + log(GENOME_DIM )) + 64);//was 2.0+... UINT MCMC_LOOPS; -const REAL MOVES_UNIF_AMPL_RATIO = 0.005 / GENOME_SCALE; +const real_t MOVES_UNIF_AMPL_RATIO = 0.005 / GENOME_SCALE; // Generic Tuple template @@ -138,7 +140,7 @@ struct Tuple { }; enum Move_Type { DIMS_ALL, DIMS_ONE, DEMCMC, NONE }; -typedef Tuple MV_EL_TYPE; +typedef Tuple MV_EL_TYPE; const UINT CUMDENSFCT_CARD = 3; MV_EL_TYPE mcmc_moves_selection_cumdensfct[3] = //{ MV_EL_TYPE(0.0,DIMS_ALL), MV_EL_TYPE(0.0,DIMS_ONE), MV_EL_TYPE(1.0,DEMCMC) }; diff --git a/InterestCalib/includeC/Date.h b/benchmarks/InterestCalib/lib/include/Date.h similarity index 93% rename from InterestCalib/includeC/Date.h rename to benchmarks/InterestCalib/lib/include/Date.h index ba21834..39beace 100644 --- a/InterestCalib/includeC/Date.h +++ b/benchmarks/InterestCalib/lib/include/Date.h @@ -74,12 +74,12 @@ bool check_date(const int& year, const int& month, const int& day) { return tmp1 && (tmp2 || tmp3); } -REAL days_between(const REAL& t1, const REAL& t2) { - REAL diff = static_cast(t1 - t2); +real_t days_between(const real_t& t1, const real_t& t2) { + real_t diff = static_cast(t1 - t2); return diff / minutes_in_day; } -REAL date_act_365(const REAL& t1, const REAL& t2) { +real_t date_act_365(const real_t& t1, const real_t& t2) { return days_between(t1, t2) / 365.0; } @@ -96,7 +96,7 @@ int end_of_month( const int& year, const int& month ) { else return 31; } -REAL add_months ( const REAL& time, const REAL& rnbmonths ) { +real_t add_months ( const real_t& time, const real_t& rnbmonths ) { int nbmonths = static_cast( rnbmonths ); Date date = gregorian_of_date( static_cast ( time ) ); @@ -113,15 +113,15 @@ REAL add_months ( const REAL& time, const REAL& rnbmonths ) { date.min = 0; } - return static_cast( date_of_gregorian( date ) ); + return static_cast( date_of_gregorian( date ) ); } -REAL add_years( const REAL& date, const REAL& nbyears ) { +real_t add_years( const real_t& date, const real_t& nbyears ) { return add_months( date, nbyears * 12.0 ); } void test_dates() { - REAL tmp; + real_t tmp; fprintf(stderr, "add_months(min_date,1)==48240 : "); tmp = add_months(MIN_DATE, 1.0); diff --git a/benchmarks/InterestCalib/lib/include/EvalGenomeInl.h b/benchmarks/InterestCalib/lib/include/EvalGenomeInl.h new file mode 100644 index 0000000..360ce9c --- /dev/null +++ b/benchmarks/InterestCalib/lib/include/EvalGenomeInl.h @@ -0,0 +1,199 @@ +#ifndef EVAL_GENOME_INLINED +#define EVAL_GENOME_INLINED + +#include "Constants.h" +#include "GenAlgUtil.h" +#include "G2PP.h" + + +/** + * MOST IMPORTANTLY: GENOME EVALUATION By Pricer of Swaption & BLACK PRICE + */ +real_t eval_genome( const real_t a, + const real_t b, + const real_t rho, + const real_t nu, + const real_t sigma, + + real_t* anew_quote, // [NUM_SWAP_QUOTES] + real_t* anew_price, // [NUM_SWAP_QUOTES] + + const int N, + short* flags, // [N] + + int * start_inds // [NUM_SWAP_QUOTES] +) { + real_t rms = 0.0; + bool sanity = true; + + // expand the irregular arrays + real_t *irreg_arrays = new real_t[8 * N]; + real_t *gbai, *gbbi, *gaici, *glog_aici, *gci, *gt1_cs, *gscale, *ghat_scale; + { // map intermediary arrays + real_t* ptr = irreg_arrays; + gbai = ptr; ptr += N; + gbbi = ptr; ptr += N; + gaici = ptr; ptr += N; + glog_aici = ptr; ptr += N; + gci = ptr; ptr += N; + gt1_cs = ptr; ptr += N; + gscale = ptr; ptr += N; + ghat_scale= ptr; ptr += N; + } + + // BIG KERNEL + for( UINT ttt = 0; ttt < NUM_SWAP_QUOTES; ttt++ ) { + const real_t mat_year = SwaptionQuotes[4*ttt + 0]; + const real_t swap_freq = SwaptionQuotes[4*ttt + 1]; + const real_t term_year = SwaptionQuotes[4*ttt + 2]; + const real_t quote = SwaptionQuotes[4*ttt + 3]; + + // adjust temporary array + const int beg_ind = start_inds[ttt]; + real_t *ci = gci + beg_ind, *bai = gbai + beg_ind, *bbi = gbbi + beg_ind, *aici = gaici + beg_ind; + real_t *log_aici = glog_aici + beg_ind, *t1_cs = gt1_cs + beg_ind, *scale = gscale + beg_ind; + real_t *hat_scale = ghat_scale + beg_ind; + + // new_quote does not have to be computed all the time, does it? + // it can just be computed once and indexed into an array ... + //const real_t new_quote = black_price ( TODAY, mat_year, swap_freq, term_year, quote ); + + const real_t maturity = add_years( TODAY, mat_year ); + const UINT n_schedi = static_cast(12.0 * term_year / swap_freq); + const real_t tmat0 = date_act_365( maturity, TODAY ); + + real_t strike; // new_quote, + { // BLACK PRICE computation + real_t lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; + + for(UINT i = 0; i < n_schedi; i++) { // reduce o map => in local memory + const real_t a1 = add_months( maturity, swap_freq*i ); + const real_t a2 = add_months( a1, swap_freq ); + + // Reduction( lvl: +, t0 : min, tn : max ) + lvl += zc(a2) * date_act_365(a2, a1); + t0 = std::min(t0, a1); + tn = std::max(tn, a2); + } + + strike = ( zc(t0) - zc(tn) ) / lvl; + const real_t d1 = 0.5 * quote * tmat0; + anew_quote[ttt] = lvl * strike * ( uGaussian_P(d1) - uGaussian_P(-d1) ); + } // END BLACK PRICE + + + //const real_t new_price = pricer_of_swaption( TODAY, mat_year, swap_freq, term_year, g_a, g_b, g_rho, g_nu, g_sigma); + //real_t new_price; + { // PRICER OF SWAPTION COMPUTATION + real_t v0_mat, dummy1, dummy2; + bigv( a, b, rho, nu, sigma, tmat0, v0_mat, dummy1, dummy2); +// + const real_t mux = - bigmx( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); + const real_t muy = - bigmy( a, b, rho, nu, sigma, TODAY, maturity, TODAY, maturity ); +// + const real_t zc_mat = zc(maturity); +// + const real_t sqrt_bfun_a = sqrt( b_fun(2.0*a, tmat0) ); + const real_t sqrt_bfun_b = sqrt( b_fun(2.0*b, tmat0) ); + const real_t rhoxy = rho * b_fun(a+b, tmat0) / (sqrt_bfun_a * sqrt_bfun_b); + const real_t sigmax = sigma * sqrt_bfun_a; + const real_t sigmay = nu * sqrt_bfun_b; + + const real_t rhoxyc = 1.0 - rhoxy * rhoxy; // used in reduction kernel + const real_t rhoxycs = sqrt( rhoxyc ); // used in reduction kernel + const real_t sigmay_rhoxycs = sigmay * rhoxycs; + const real_t t4 = (rhoxy * sigmay) / sigmax; +// + + for( UINT i = 0; i < n_schedi; i++ ) { + const real_t beg_date = add_months( maturity, swap_freq*i ); //scheduleix[i]; + const real_t end_date = add_months( beg_date, swap_freq ); //scheduleiy[i]; + const real_t res = date_act_365( end_date, beg_date ) * strike; + + const real_t cii = ( i == n_schedi-1 ) ? 1.0 + res : res; + + real_t v0_end, vt_end, baii, bbii, date_tod1, date_tod2; + date_tod1 = date_act_365(end_date, TODAY); + bigv( a, b, rho, nu, sigma, date_tod1, v0_end, dummy1, dummy2 ); + date_tod2 = date_act_365(end_date, maturity); + bigv( a, b, rho, nu, sigma, date_tod2, vt_end, baii, bbii ); + + const real_t expo_aici = 0.5 * (vt_end - v0_end + v0_mat); + const real_t fact_aici = cii * zc(end_date) / zc_mat; + ci [i] = fact_aici; // reuse the space to hold the factor of t1_cs + t1_cs [i] = bbii * (mux * t4 - (muy - 0.5*rhoxyc*sigmay*sigmay*bbii) ) + expo_aici; + // hold only the exponent of the original t1_cs; + + bai [i] = baii; + bbi [i] = bbii; + aici [i] = fact_aici * exp( expo_aici ); + log_aici[i] = log( fact_aici ) + expo_aici; + scale [i] = - ( baii + bbii * t4 ); + + sanity = ! ( isinf(aici[i]) || isnan(aici[i]) ); + assert(sanity && "Nan aici in pricer of swaption. Exiting!\n"); + } +// + const real_t eps = 0.5 * sigmax; + + const real_t f = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, + mux, muy, bai, bbi, aici, log_aici, hat_scale, mux ); + const real_t g = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, + mux, muy, bai, bbi, aici, log_aici, hat_scale, mux + eps ); + const real_t h = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, + mux, muy, bai, bbi, aici, log_aici, hat_scale, mux - eps ); + const real_t df = 0.5 * ( g - h ) / eps; + + const real_t sqrt2sigmax = sqrt(2.0) * sigmax;; + const real_t t2 = rhoxy / (sigmax*rhoxycs);; + + real_t accum = 0.0; + + for( UINT j = 0; j < NUM_HERMITE; j++ ) { + const real_t x_quad = HermiteCoeffs [j]; + const real_t w_quad = HermiteWeights[j]; + + const real_t x = sqrt2sigmax * x_quad + mux; + const real_t yhat_x = f + df*(x - mux); + const real_t h1 = ( (yhat_x - muy) / sigmay_rhoxycs ) - t2*( x - mux ); + + real_t accum1 = 0.0; + for( UINT i = 0; i < n_schedi; i++ ) { + const real_t h2 = h1 + bbi[i] * sigmay_rhoxycs; + + const real_t expo_aici = t1_cs[i] + scale[i]*x; + const real_t fact_aici = ci[i]; + // accum1 += fact_aici * exp(expo_aici) * uGaussian_P(-h2); + const real_t expo_part = uGaussian_P_withExpFactor( -h2, expo_aici ); + accum1 += fact_aici * expo_part; + } + + sanity = ! ( isnan(accum1) || isinf(accum1) ); + assert(sanity && "Nan accum1 in pricer of swaption. Exiting!\n"); + + real_t tmp = sqrt(2.0) * x_quad; //(x - mux) / sigmax; + const real_t t1 = exp( - 0.5 * tmp * tmp ); + + accum += w_quad * t1 * ( uGaussian_P(-h1) - accum1 ); + } + + sanity = ! ( isnan(accum) || isinf(accum) ); + assert(sanity && "Nan accum1 in pricer of swaption. Exiting!\n"); + + anew_price[ttt] = zc_mat * ( accum / sqrt( PI ) ); + +// const real_t tmp = (anew_price[ttt] - anew_quote[ttt]) / anew_quote[ttt]; +// rms += tmp * tmp; + const real_t lik = logLikelihood( anew_quote[ttt], anew_price[ttt] ); + rms += lik; + } + } + + delete[] irreg_arrays; + + return rms; +// return 0.0-rms; +} + +#endif // end ifndef EVAL_GENOME_INLINED + diff --git a/InterestCalib/includeC/G2PP.h b/benchmarks/InterestCalib/lib/include/G2PP.h similarity index 51% rename from InterestCalib/includeC/G2PP.h rename to benchmarks/InterestCalib/lib/include/G2PP.h index e9d3b0b..bd9105f 100644 --- a/InterestCalib/includeC/G2PP.h +++ b/benchmarks/InterestCalib/lib/include/G2PP.h @@ -12,33 +12,33 @@ // Root finder ////////////////////////// -REAL exactYhat( const UINT& n_schedi, - - const REAL& b, // scals begins - const REAL& sigmax, - const REAL& sigmay, - const REAL& rhoxy, - const REAL& rhoxyc, - const REAL& rhoxycs, - const REAL& mux, - const REAL& muy, // scals ends - - const REAL* bai, // babaicis begins - const REAL* bbi, - const REAL* aici, - const REAL* log_aici, // babaicis ends - - REAL* scales, - const REAL& x +real_t exactYhat( const UINT& n_schedi, + + const real_t& b, // scals begins + const real_t& sigmax, + const real_t& sigmay, + const real_t& rhoxy, + const real_t& rhoxyc, + const real_t& rhoxycs, + const real_t& mux, + const real_t& muy, // scals ends + + const real_t* bai, // babaicis begins + const real_t* bbi, + const real_t* aici, + const real_t* log_aici, // babaicis ends + + real_t* scales, + const real_t& x ) { // ugaussian_Pinv(k)=1.0e~4 - const REAL k = - 3.71901648545568; + const real_t k = - 3.71901648545568; - REAL up = 0.0, lo = -INFTY; + real_t up = 0.0, lo = -INFTY; for( UINT i = 0; i < n_schedi; i++ ) { - REAL baix = bai[i] * x; + real_t baix = bai[i] * x; - REAL up_term = aici[i] * exp( -baix ); + real_t up_term = aici[i] * exp( -baix ); scales[i] = up_term; up += up_term; lo = std::max( lo, ( log_aici[i] - baix ) / bbi[i] ); @@ -50,8 +50,8 @@ REAL exactYhat( const UINT& n_schedi, // CHECKING uplo!!!! - const REAL log_s = log(up); - REAL tmp = log_s / bbi[n_schedi-1]; + const real_t log_s = log(up); + real_t tmp = log_s / bbi[n_schedi-1]; if ( tmp <= 0.0 ) { up = tmp; @@ -61,20 +61,20 @@ REAL exactYhat( const UINT& n_schedi, else up = - INFTY; } - const REAL yl = lo - EPS; - const REAL yu = up + EPS; + const real_t yl = lo - EPS; + const real_t yu = up + EPS; - const REAL y0 = sigmay * ( rhoxy * (x-mux) / sigmax + k * rhoxycs ) - rhoxyc/b + muy; - const REAL y1 = sigmay * ( rhoxy * (x-mux) / sigmax - k * rhoxycs ) + muy; + const real_t y0 = sigmay * ( rhoxy * (x-mux) / sigmax + k * rhoxycs ) - rhoxyc/b + muy; + const real_t y1 = sigmay * ( rhoxy * (x-mux) / sigmax - k * rhoxycs ) + muy; - REAL res; + real_t res; if ( y1 <= yl ) res = y1 + 1.0; // yhat is greater than y1 => 1 - phi(h_i(x, yhat)) < EPS else if ( yu <= y0 ) res = y0 - 1.0; // yhat is lower than y0 => phi(h_i(x, yhat)) < EPS) else { - const REAL root_lb = std::max( yl, y0 ); - const REAL root_ub = std::min( yu, y1 ); + const real_t root_lb = std::max( yl, y0 ); + const real_t root_ub = std::min( yu, y1 ); - REAL root, error; UINT iter; + real_t root, error; UINT iter; rootFinding_Brent(1, n_schedi, scales, bbi, root_lb, root_ub, 1.0e-4, 1000, root, iter, error); //rootBisection(1, n_schedi, scales, bbi, root_lb, root_ub, 1.0e-4, 1000, root, iter, error); @@ -101,47 +101,47 @@ REAL exactYhat( const UINT& n_schedi, // return res,ba,bb ////////////// -REAL pricer_of_swaption( const REAL& today, +real_t pricer_of_swaption( const real_t& today, - const REAL& sw_mat, // swaptionQuote begins ... - const REAL& sw_freq, - const REAL& sw_ty, // swaptionQuote ends. - - const REAL& a, // genome begins ... - const REAL& b, - const REAL& rho, - const REAL& nu, - const REAL& sigma // genome ends. + const real_t& sw_mat, // swaptionQuote begins ... + const real_t& sw_freq, + const real_t& sw_ty, // swaptionQuote ends. + + const real_t& a, // genome begins ... + const real_t& b, + const real_t& rho, + const real_t& nu, + const real_t& sigma // genome ends. ) { //SwapOfSwap sos = extended_swaption_of_swaption(sw_mat, sw_freq, sw_ty); - const REAL maturity = add_years( TODAY, sw_mat ); + const real_t maturity = add_years( TODAY, sw_mat ); const UINT n_schedi = static_cast(12.0 * sw_ty / sw_freq); // - const REAL tmat0 = date_act_365( maturity, today ); // BIG BUG -- was TODAY - REAL v0_mat, dummy1, dummy2; + const real_t tmat0 = date_act_365( maturity, today ); // BIG BUG -- was TODAY + real_t v0_mat, dummy1, dummy2; bigv( a, b, rho, nu, sigma, tmat0, v0_mat, dummy1, dummy2); // - const REAL mux = - bigmx( a, b, rho, nu, sigma, today, maturity, today, maturity ); - const REAL muy = - bigmy( a, b, rho, nu, sigma, today, maturity, today, maturity ); + const real_t mux = - bigmx( a, b, rho, nu, sigma, today, maturity, today, maturity ); + const real_t muy = - bigmy( a, b, rho, nu, sigma, today, maturity, today, maturity ); // - const REAL zc_mat = zc(maturity); + const real_t zc_mat = zc(maturity); // - const REAL sqrt_bfun_a = sqrt( b_fun(2.0*a, tmat0) ); - const REAL sqrt_bfun_b = sqrt( b_fun(2.0*b, tmat0) ); - const REAL rhoxy = rho * b_fun(a+b, tmat0) / (sqrt_bfun_a * sqrt_bfun_b); - const REAL sigmax = sigma * sqrt_bfun_a; - const REAL sigmay = nu * sqrt_bfun_b; - - const REAL rhoxyc = 1.0 - rhoxy * rhoxy; // used in reduction kernel - const REAL rhoxycs = sqrt( rhoxyc ); // used in reduction kernel - const REAL sigmay_rhoxycs = sigmay * rhoxycs; - const REAL t4 = (rhoxy * sigmay) / sigmax; + const real_t sqrt_bfun_a = sqrt( b_fun(2.0*a, tmat0) ); + const real_t sqrt_bfun_b = sqrt( b_fun(2.0*b, tmat0) ); + const real_t rhoxy = rho * b_fun(a+b, tmat0) / (sqrt_bfun_a * sqrt_bfun_b); + const real_t sigmax = sigma * sqrt_bfun_a; + const real_t sigmay = nu * sqrt_bfun_b; + + const real_t rhoxyc = 1.0 - rhoxy * rhoxy; // used in reduction kernel + const real_t rhoxycs = sqrt( rhoxyc ); // used in reduction kernel + const real_t sigmay_rhoxycs = sigmay * rhoxycs; + const real_t t4 = (rhoxy * sigmay) / sigmax; // - REAL lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; + real_t lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; for( UINT i = 0; i < n_schedi; i++ ) { - REAL a1 = add_months( maturity, sw_freq*i ); + real_t a1 = add_months( maturity, sw_freq*i ); //sos.swap_sched1[i] = a1; - REAL a2 = add_months( a1, sw_freq ); + real_t a2 = add_months( a1, sw_freq ); //sos.swap_sched2[i] = a2; // Reduction( lvl: +, t0 : min, tn : max ) @@ -150,32 +150,32 @@ REAL pricer_of_swaption( const REAL& today, tn = std::max(tn, a2); } - const REAL strike = ( zc(t0) - zc(tn) ) / lvl; + const real_t strike = ( zc(t0) - zc(tn) ) / lvl; // - REAL* ci = new REAL[n_schedi]; - REAL* bai = new REAL[n_schedi]; - REAL* bbi = new REAL[n_schedi]; - REAL* aici = new REAL[n_schedi]; - REAL* log_aici = new REAL[n_schedi]; - REAL* t1_cs = new REAL[n_schedi]; - REAL* scale = new REAL[n_schedi]; - REAL* hat_scale= new REAL[n_schedi]; + real_t* ci = new real_t[n_schedi]; + real_t* bai = new real_t[n_schedi]; + real_t* bbi = new real_t[n_schedi]; + real_t* aici = new real_t[n_schedi]; + real_t* log_aici = new real_t[n_schedi]; + real_t* t1_cs = new real_t[n_schedi]; + real_t* scale = new real_t[n_schedi]; + real_t* hat_scale= new real_t[n_schedi]; for( UINT i = 0; i < n_schedi; i++ ) { - const REAL beg_date = add_months( maturity, sw_freq*i ); //scheduleix[i]; - const REAL end_date = add_months( beg_date, sw_freq ); //scheduleiy[i]; - const REAL res = date_act_365( end_date, beg_date ) * strike; + const real_t beg_date = add_months( maturity, sw_freq*i ); //scheduleix[i]; + const real_t end_date = add_months( beg_date, sw_freq ); //scheduleiy[i]; + const real_t res = date_act_365( end_date, beg_date ) * strike; - const REAL cii = ( i == n_schedi-1 ) ? 1.0 + res : res; + const real_t cii = ( i == n_schedi-1 ) ? 1.0 + res : res; - REAL v0_end, vt_end, baii, bbii, date_tod1, date_tod2; + real_t v0_end, vt_end, baii, bbii, date_tod1, date_tod2; date_tod1 = date_act_365(end_date, today); bigv( a, b, rho, nu, sigma, date_tod1, v0_end, dummy1, dummy2 ); date_tod2 = date_act_365(end_date, maturity); bigv( a, b, rho, nu, sigma, date_tod2, vt_end, baii, bbii ); - const REAL expo_aici = 0.5 * (vt_end - v0_end + v0_mat); - const REAL fact_aici = cii * zc(end_date) / zc_mat; + const real_t expo_aici = 0.5 * (vt_end - v0_end + v0_mat); + const real_t fact_aici = cii * zc(end_date) / zc_mat; ci [i] = fact_aici; // reuse the space to hold the factor of t1_cs t1_cs [i] = bbii * (mux * t4 - (muy - 0.5*rhoxyc*sigmay*sigmay*bbii) ) + expo_aici; // hold only the exponent of the original t1_cs; @@ -191,39 +191,39 @@ REAL pricer_of_swaption( const REAL& today, } // - const REAL eps = 0.5 * sigmax; + const real_t eps = 0.5 * sigmax; - const REAL f = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, mux, muy, bai, bbi, aici, log_aici, hat_scale, mux ); - const REAL g = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, mux, muy, bai, bbi, aici, log_aici, hat_scale, mux + eps ); - const REAL h = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, mux, muy, bai, bbi, aici, log_aici, hat_scale, mux - eps ); - const REAL df = 0.5 * ( g - h ) / eps; + const real_t f = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, mux, muy, bai, bbi, aici, log_aici, hat_scale, mux ); + const real_t g = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, mux, muy, bai, bbi, aici, log_aici, hat_scale, mux + eps ); + const real_t h = exactYhat( n_schedi, b, sigmax, sigmay, rhoxy, rhoxyc, rhoxycs, mux, muy, bai, bbi, aici, log_aici, hat_scale, mux - eps ); + const real_t df = 0.5 * ( g - h ) / eps; // AT this point we need: // scalars: sqrt2sigmax, t2, f, df, mux, muy, sigmay_rhoxycs, zc_mat // arrays : t1_cs, bbi, scale, ci - const REAL sqrt2sigmax = sqrt(2.0) * sigmax; - const REAL t2 = rhoxy / (sigmax*rhoxycs); + const real_t sqrt2sigmax = sqrt(2.0) * sigmax; + const real_t t2 = rhoxy / (sigmax*rhoxycs); // t2 * (sqrt2sigmax * x_quad) -> sqrt(2.0) * rhoxy / rhoxycs * xquad - REAL accum0 = 0.0; + real_t accum0 = 0.0; for( UINT j = 0; j < NUM_HERMITE; j++ ) { - const REAL x_quad = HermiteCoeffs [j]; - const REAL w_quad = HermiteWeights[j]; + const real_t x_quad = HermiteCoeffs [j]; + const real_t w_quad = HermiteWeights[j]; - const REAL x = sqrt2sigmax * x_quad + mux; + const real_t x = sqrt2sigmax * x_quad + mux; - const REAL yhat_x = f + df*(x - mux); - const REAL h1 = ( (yhat_x - muy) / sigmay_rhoxycs ) - t2*( x - mux ); + const real_t yhat_x = f + df*(x - mux); + const real_t h1 = ( (yhat_x - muy) / sigmay_rhoxycs ) - t2*( x - mux ); - REAL accum1 = 0.0; + real_t accum1 = 0.0; for( UINT i = 0; i < n_schedi; i++ ) { - const REAL h2 = h1 + bbi[i] * sigmay_rhoxycs; + const real_t h2 = h1 + bbi[i] * sigmay_rhoxycs; - const REAL expo_aici = t1_cs[i] + scale[i]*x; - const REAL fact_aici = ci[i]; + const real_t expo_aici = t1_cs[i] + scale[i]*x; + const real_t fact_aici = ci[i]; // accum1 += fact_aici * exp(expo_aici) * uGaussian_P(-h2); - const REAL expo_part = uGaussian_P_withExpFactor( -h2, expo_aici ); + const real_t expo_part = uGaussian_P_withExpFactor( -h2, expo_aici ); accum1 += fact_aici * expo_part; if( isnan(accum1) || isinf(accum1) ) { @@ -235,8 +235,8 @@ REAL pricer_of_swaption( const REAL& today, } } - REAL tmp = sqrt(2.0) * x_quad; //(x - mux) / sigmax; - const REAL t1 = exp( - 0.5 * tmp * tmp ); + real_t tmp = sqrt(2.0) * x_quad; //(x - mux) / sigmax; + const real_t t1 = exp( - 0.5 * tmp * tmp ); accum0 += w_quad * t1 * ( uGaussian_P(-h1) - accum1 ); } @@ -258,20 +258,20 @@ REAL pricer_of_swaption( const REAL& today, //// Pricer for one genome: //// //////////////////////////////// -REAL pricer (const REAL a = 0.02453, const REAL b = 0.98376, const REAL rho = -0.82400, const REAL nu = 0.11830, const REAL sigma = 0.02398) { +real_t pricer (const real_t a = 0.02453, const real_t b = 0.98376, const real_t rho = -0.82400, const real_t nu = 0.11830, const real_t sigma = 0.02398) { //let genome = {0.02453, 0.98376, ~0.82400, 0.11830, 0.02398} in - REAL rms = 0.0, logLik = 0.0; + real_t rms = 0.0, logLik = 0.0; for( UINT i = 0; i < NUM_SWAP_QUOTES; i++ ) { - const REAL mat_year = SwaptionQuotes[4*i+0]; - const REAL swap_freq = SwaptionQuotes[4*i+1]; - const REAL term_year = SwaptionQuotes[4*i+2]; - const REAL quote = SwaptionQuotes[4*i+3]; + const real_t mat_year = SwaptionQuotes[4*i+0]; + const real_t swap_freq = SwaptionQuotes[4*i+1]; + const real_t term_year = SwaptionQuotes[4*i+2]; + const real_t quote = SwaptionQuotes[4*i+3]; - const REAL g2pp_price = pricer_of_swaption( TODAY, mat_year, swap_freq, term_year, a, b, rho, nu, sigma); - const REAL market_price = black_price ( TODAY, mat_year, swap_freq, term_year, quote ); + const real_t g2pp_price = pricer_of_swaption( TODAY, mat_year, swap_freq, term_year, a, b, rho, nu, sigma); + const real_t market_price = black_price ( TODAY, mat_year, swap_freq, term_year, quote ); - const REAL tmp = (g2pp_price - market_price) / market_price; + const real_t tmp = (g2pp_price - market_price) / market_price; rms += tmp * tmp; logLik += logLikelihood( market_price, g2pp_price ); } @@ -297,18 +297,18 @@ REAL pricer (const REAL a = 0.02453, const REAL b = 0.98376, const REAL rho = -0 void test_pricer_of_swaption() { - const REAL a = 0.02453; - const REAL b = 0.98376; - const REAL rho = -0.82400; - const REAL nu = 0.11830; - const REAL sigma = 0.02398; + const real_t a = 0.02453; + const real_t b = 0.98376; + const real_t rho = -0.82400; + const real_t nu = 0.11830; + const real_t sigma = 0.02398; // (maturity, frequency, term) = swaption - REAL maturity = 10.0; - REAL freq = 6.0; - REAL term = 4.0; + real_t maturity = 10.0; + real_t freq = 6.0; + real_t term = 4.0; - const REAL price1 = 1.0e4 * pricer_of_swaption( TODAY, maturity, freq, term, a, b, rho, nu, sigma); + const real_t price1 = 1.0e4 * pricer_of_swaption( TODAY, maturity, freq, term, a, b, rho, nu, sigma); printf("Pricer_of_swaption test I = 657.82158867845 : "); if( equalEps(price1, 657.82158867845) ) printf(" SUCCESS!\n\n"); else printf("%f FAILS!\n\n", price1); @@ -318,7 +318,7 @@ void test_pricer_of_swaption() { freq = 6.0; term = 30.0; - const REAL price2 = 1.0e4 * pricer_of_swaption( TODAY, maturity, freq, term, a, b, rho, nu, sigma ); + const real_t price2 = 1.0e4 * pricer_of_swaption( TODAY, maturity, freq, term, a, b, rho, nu, sigma ); printf("Pricer_of_swaption test II = 1902.97628191498 : "); if( equalEps(price2, 1902.97628191498) ) printf(" SUCCESS!\n\n"); else printf("%f FAILS!\n\n", price2); @@ -329,7 +329,7 @@ void test_pricer_of_swaption() { freq = 6.0; term = 25.0; - const REAL price3 = 1.0e4 * pricer_of_swaption( TODAY, maturity, freq, term, a, b, rho, nu, sigma ); + const real_t price3 = 1.0e4 * pricer_of_swaption( TODAY, maturity, freq, term, a, b, rho, nu, sigma ); printf("Pricer_of_swaption test III = 1840.859126408099 : "); if( equalEps(price3, 1840.859126408099) ) printf(" SUCCESS!\n\n"); else printf("%f FAILS!\n\n", price3); diff --git a/InterestCalib/includeC/G2ppUtil.h b/benchmarks/InterestCalib/lib/include/G2ppUtil.h similarity index 61% rename from InterestCalib/includeC/G2ppUtil.h rename to benchmarks/InterestCalib/lib/include/G2ppUtil.h index fae53f9..0666314 100644 --- a/InterestCalib/includeC/G2ppUtil.h +++ b/benchmarks/InterestCalib/lib/include/G2ppUtil.h @@ -5,34 +5,34 @@ #include "Constants.h" #include "MathModule.h" -REAL zc( const REAL& t ) { +real_t zc( const real_t& t ) { return exp( - R * date_act_365( t, TODAY ) ); } /** -Triple accumSched( Triple xx, Triple yy ) { - REAL x = xx.fst, d1 = xx.snd, d2 = xx.thrd, y = yy.fst, tf = yy.snd, tp = yy.thrd; - return Triple( x + zc(tp) * date_act_365(tp, tf), std::min(d1,tf), std::max(d2,tp) ); +Triple accumSched( Triple xx, Triple yy ) { + real_t x = xx.fst, d1 = xx.snd, d2 = xx.thrd, y = yy.fst, tf = yy.snd, tp = yy.thrd; + return Triple( x + zc(tp) * date_act_365(tp, tf), std::min(d1,tf), std::max(d2,tp) ); } **/ SwapOfSwap extended_swaption_of_swaption( - const REAL& sw_mat, - const REAL& freq, - const REAL& sw_ty + const real_t& sw_mat, + const real_t& freq, + const real_t& sw_ty ) { - const REAL maturity = add_years( TODAY, sw_mat ); + const real_t maturity = add_years( TODAY, sw_mat ); const UINT nschedule = static_cast(12.0 * sw_ty / freq); SwapOfSwap sos(nschedule); - REAL lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; + real_t lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; for(UINT i=0; i= EPS ) ? x : ( x >= 0.0 ) ? EPS : -EPS; - const REAL expxtau = exp( -x0*tau ) ; - const REAL exp2xtau = expxtau*expxtau; +real_t t_fun( const real_t& sigma, const real_t& x0, const real_t& tau ) { + //const real_t x0 = ( fabs(x) >= EPS ) ? x : ( x >= 0.0 ) ? EPS : -EPS; + const real_t expxtau = exp( -x0*tau ) ; + const real_t exp2xtau = expxtau*expxtau; return sigma*sigma/(x0*x0) * ( tau + 2.0/x0*expxtau-1.0/(2.0*x0)*exp2xtau-3.0/(2.0*x0) ); } @@ -69,17 +69,17 @@ REAL t_fun( const REAL& sigma, const REAL& x0, const REAL& tau ) { // the result is V in Brigo and Mercurio's book page 148. // \var(\int_t^T [x(u)+y(u)]du) /////////////////////////////////////////////////////////////////// -void bigv( const REAL& g_a, - const REAL& g_b, - const REAL& g_rho, - const REAL& g_nu, - const REAL& g_sig, - const REAL& tau, - REAL& v, - REAL& bai, - REAL& bbi +void bigv( const real_t& g_a, + const real_t& g_b, + const real_t& g_rho, + const real_t& g_nu, + const real_t& g_sig, + const real_t& tau, + real_t& v, + real_t& bai, + real_t& bbi ) { - const REAL g_sigma = g_sig; //(g_sig == 0.0) ? 1.0e-10 : g_sig; + const real_t g_sigma = g_sig; //(g_sig == 0.0) ? 1.0e-10 : g_sig; bai = b_fun(g_a, tau); bbi = b_fun(g_b, tau); @@ -98,25 +98,25 @@ void bigv( const REAL& g_a, // // the result is: x drift term in tmat-forward measure /////////////////////////////////////////////////////////////////// -REAL bigmx( const REAL& a, - const REAL& b, - const REAL& rho, - const REAL& nu, - const REAL& sigma, // ends genome - const REAL& today, - const REAL& tmat, - const REAL& s, - const REAL& t +real_t bigmx( const real_t& a, + const real_t& b, + const real_t& rho, + const real_t& nu, + const real_t& sigma, // ends genome + const real_t& today, + const real_t& tmat, + const real_t& s, + const real_t& t ) { - const REAL ts = date_act_365(t, s) ; - const REAL tmatt = date_act_365(tmat, t) ; + const real_t ts = date_act_365(t, s) ; + const real_t tmatt = date_act_365(tmat, t) ; - const REAL tmat0 = date_act_365(tmat, today); - const REAL tmats = date_act_365(tmat, s) ; - const REAL t0 = date_act_365(t, today); - const REAL s0 = date_act_365(s, today); + const real_t tmat0 = date_act_365(tmat, today); + const real_t tmats = date_act_365(tmat, s) ; + const real_t t0 = date_act_365(t, today); + const real_t s0 = date_act_365(s, today); - REAL tmp, res = 0.0; + real_t tmp, res = 0.0; tmp = (sigma*sigma)/(a*a)+(sigma*rho*nu)/(a*b); tmp *= ( 1.0 - exp(- a * ts) ); @@ -143,24 +143,24 @@ REAL bigmx( const REAL& a, // the result is: y drift term in tmat-forward measure /////////////////////////////////////////////////////////////////// -REAL bigmy( const REAL& a, - const REAL& b, - const REAL& rho, - const REAL& nu, - const REAL& sigma, // ends genome - const REAL& today, - const REAL& tmat, - const REAL& s, - const REAL& t +real_t bigmy( const real_t& a, + const real_t& b, + const real_t& rho, + const real_t& nu, + const real_t& sigma, // ends genome + const real_t& today, + const real_t& tmat, + const real_t& s, + const real_t& t ) { - const REAL ts = date_act_365(t, s) ; - const REAL tmatt = date_act_365(tmat, t) ; - const REAL tmat0 = date_act_365(tmat, today); - const REAL tmats = date_act_365(tmat, s) ; - const REAL t0 = date_act_365(t, today); - const REAL s0 = date_act_365(s, today); + const real_t ts = date_act_365(t, s) ; + const real_t tmatt = date_act_365(tmat, t) ; + const real_t tmat0 = date_act_365(tmat, today); + const real_t tmats = date_act_365(tmat, s) ; + const real_t t0 = date_act_365(t, today); + const real_t s0 = date_act_365(s, today); - REAL tmp, res = 0.0; + real_t tmp, res = 0.0; tmp = nu*nu/(b*b)+sigma*rho*nu/(a*b); tmp *= 1.0 - exp(-b * ts); @@ -178,23 +178,23 @@ REAL bigmy( const REAL& a, } -REAL black_price ( const REAL& today, - const REAL& sw_mat, // swaption.1 - const REAL& freq, // swaption.2 - const REAL& sw_ty, // swaption.3 - const REAL& vol +real_t black_price ( const real_t& today, + const real_t& sw_mat, // swaption.1 + const real_t& freq, // swaption.2 + const real_t& sw_ty, // swaption.3 + const real_t& vol ) { // inlined extended_swaption_of_swaptions - const REAL maturity = add_years( TODAY, sw_mat ); + const real_t maturity = add_years( TODAY, sw_mat ); const UINT nschedule = static_cast(12.0 * sw_ty / freq); - const REAL sqrtt = date_act_365( maturity, today ); + const real_t sqrtt = date_act_365( maturity, today ); // morally equivalent to `swap_schedule2lvl(swap_schedule)' but in map-reduce form!! - REAL lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; + real_t lvl = 0.0, t0 = MAX_DATE, tn = MIN_DATE; for(UINT i=0; i> 1) ^ n; int res = 0; for( int i=0; i < NUM_SOBOL_BITS; i++ ) { @@ -19,7 +19,7 @@ REAL getSobolNum( uint n ) { res = res ^ SobolDirVct[i]; } } - REAL rres = static_cast(res) / ( (1<(res) / ( (1<= 1.0 || rres < 0 ) { printf("sobol(%d) = %f. Exiting!\n", n, rres); exit(0);} return rres; } @@ -27,23 +27,23 @@ REAL getSobolNum( uint n ) { //unsigned int rand_count = 1; uint sobol_offset = 1; //11; -REAL getRandRandNorm() { +real_t getRandRandNorm() { #if WITH_SOBOL return getSobolNum( sobol_offset++ ); #endif double r = static_cast(std::rand()); // drand48() double d = static_cast(RAND_MAX)+0.1; - return static_cast(r / d); + return static_cast(r / d); } -REAL getRandUnifNorm() { +real_t getRandUnifNorm() { return getRandRandNorm(); - //return static_cast(drand48()); + //return static_cast(drand48()); } //Returns a (pseudo) random integer in [0, ub) UINT getRandIntNorm(long int ub) { - REAL r01 = getRandRandNorm(); + real_t r01 = getRandRandNorm(); return static_cast(r01 * ub); } @@ -54,38 +54,38 @@ UINT getRandIntNorm(long int ub) { /********************************************/ //========================================================================= -const REAL sqrtTwoPi = sqrt(2*PI); +const real_t sqrtTwoPi = sqrt(2*PI); -REAL normal_pdf( const REAL& z, const REAL& mu, const REAL& sigma ) { - REAL sigmap = fabs(sigma); - REAL res = 1.0 / (sigmap * sqrtTwoPi); - REAL ecf = (z-mu) * (z-mu) / (2.0 * sigmap * sigmap); +real_t normal_pdf( const real_t& z, const real_t& mu, const real_t& sigma ) { + real_t sigmap = fabs(sigma); + real_t res = 1.0 / (sigmap * sqrtTwoPi); + real_t ecf = (z-mu) * (z-mu) / (2.0 * sigmap * sigmap); return res * exp( -ecf ); } -REAL cauchy_pdf( const REAL& z, const REAL mu = 0.0, const REAL gamma = 4.0) { - REAL x = (z-mu) / gamma; +real_t cauchy_pdf( const real_t& z, const real_t mu = 0.0, const real_t gamma = 4.0) { + real_t x = (z-mu) / gamma; return 1.0 / ( PI * gamma * (1+x*x) ); } -REAL logLikelihood_normal(const REAL& y_ref, const REAL& y) { - //REAL mu = y_ref; - REAL sigma = (y_ref / 50.0) * LLHOOD_NORMAL_OFFS; - REAL pdfs = normal_pdf( y, y_ref, sigma ); +real_t logLikelihood_normal(const real_t& y_ref, const real_t& y) { + //real_t mu = y_ref; + real_t sigma = (y_ref / 50.0) * LLHOOD_NORMAL_OFFS; + real_t pdfs = normal_pdf( y, y_ref, sigma ); pdfs += 1.0e-20; // avoid NaNs return log(pdfs); } -REAL logLikelihood_cauchy(const REAL& y_ref, const REAL& y) { - REAL gamma = ( fabs(y_ref) / 50.0 ) * LLHOOD_CAUCHY_OFFS + 0.01; - REAL pdfs = cauchy_pdf( y, y_ref, gamma ); +real_t logLikelihood_cauchy(const real_t& y_ref, const real_t& y) { + real_t gamma = ( fabs(y_ref) / 50.0 ) * LLHOOD_CAUCHY_OFFS + 0.01; + real_t pdfs = cauchy_pdf( y, y_ref, gamma ); pdfs += 1.0e-20; // avoid NaNs return log(pdfs); } -REAL logLikelihood(const REAL& y_ref, const REAL& y) { +real_t logLikelihood(const real_t& y_ref, const real_t& y) { if ( LLHOOD_TYPE == NORMAL ) return logLikelihood_normal(y_ref, y); else/* LLHOOD_TYPE == CAUCHY */return logLikelihood_cauchy(y_ref, y); } diff --git a/InterestCalib/includeC/IrregShape.h b/benchmarks/InterestCalib/lib/include/IrregShape.h similarity index 98% rename from InterestCalib/includeC/IrregShape.h rename to benchmarks/InterestCalib/lib/include/IrregShape.h index 9703fac..107e08b 100644 --- a/InterestCalib/includeC/IrregShape.h +++ b/benchmarks/InterestCalib/lib/include/IrregShape.h @@ -53,7 +53,7 @@ short* getIregShapeAdjusted( const int LWG, } N = Ncur; - REAL overhead = ((REAL)Ncur)/(Ncur-tot_iddle_thds); + real_t overhead = ((real_t)Ncur)/(Ncur-tot_iddle_thds); overhead = (overhead - 1.0) * 100.0; // printf("Summary: Ncurr: %d, tot_iddle_thds: %d, overhead: %f percent\n", diff --git a/InterestCalib/includeC/KerConsts.h b/benchmarks/InterestCalib/lib/include/KerConsts.h similarity index 64% rename from InterestCalib/includeC/KerConsts.h rename to benchmarks/InterestCalib/lib/include/KerConsts.h index 52e05b6..2433360 100644 --- a/InterestCalib/includeC/KerConsts.h +++ b/benchmarks/InterestCalib/lib/include/KerConsts.h @@ -17,30 +17,16 @@ */ #define GPU_VERSION 2 -/** - * If WITH_FLOAT == 0 THEN double precision is used, - * Otherwise single float precision. - * - * If you modify this flag, DO NOT forget to perform - * a dummy change in file `SrcCL/CalibKers.cl', - * so that the cached version will be invalidated! - */ -#define WITH_FLOAT 1 - /*********************************************/ /*********************************************/ /*********************************************/ -#if WITH_FLOAT - typedef float REAL; - #define EPS0 (0.3e-2) - #define EPS (0.2e-4) - #define PI (3.14159265358) +#if REAL_IS_FLOAT + #define EPS0 (0.3e-2F) + #define EPS (0.2e-4F) + #define PI (3.14159265358F) #else - #pragma OPENCL EXTENSION cl_khr_fp64: enable - - typedef double REAL; #define EPS0 (1.0e-3) #define EPS (1.0e-5) #define PI (3.1415926535897932384626433832795) @@ -57,4 +43,3 @@ #define R 0.03 #endif // KERNEL_CONSTANTS - diff --git a/InterestCalib/includeC/MathModule.h b/benchmarks/InterestCalib/lib/include/MathModule.h similarity index 66% rename from InterestCalib/includeC/MathModule.h rename to benchmarks/InterestCalib/lib/include/MathModule.h index db7ecf6..55dc3c0 100644 --- a/InterestCalib/includeC/MathModule.h +++ b/benchmarks/InterestCalib/lib/include/MathModule.h @@ -12,15 +12,15 @@ // formula 7.1.26 (page 300), Handbook of Mathematical Functions, Abramowitz and Stegun // http://people.math.sfu.ca/~cbm/aands/frameindex.htm -REAL erff1( const REAL& x ) { - const REAL p = 0.3275911; - const REAL a1 = 0.254829592, a2 = -0.284496736, a3 = 1.421413741, a4 = -1.453152027, a5 = 1.061405429; +real_t erff1( const real_t& x ) { + const real_t p = 0.3275911; + const real_t a1 = 0.254829592, a2 = -0.284496736, a3 = 1.421413741, a4 = -1.453152027, a5 = 1.061405429; - const REAL t = 1.0/(1.0+p*x); - const REAL t2 = t * t; - const REAL t3 = t * t2; - const REAL t4 = t2 * t2; - const REAL t5 = t2 * t3; + const real_t t = 1.0/(1.0+p*x); + const real_t t2 = t * t; + const real_t t3 = t * t2; + const real_t t4 = t2 * t2; + const real_t t5 = t2 * t3; return ( 1.0 - (a1*t + a2*t2 + a3*t3 + a4*t4 + a5*t5) * exp(-(x*x)) ); } @@ -28,35 +28,35 @@ REAL erff1( const REAL& x ) { //------------------------------------------------------------------------- // Cumulative Distribution Function for a standard normal distribution -REAL uGaussian_P( const REAL& x ) { - const REAL u = x / sqrt(2.0); - const REAL e = ( u < 0.0 ) ? -erff1(-u) : erff1(u); +real_t uGaussian_P( const real_t& x ) { + const real_t u = x / sqrt(2.0); + const real_t e = ( u < 0.0 ) ? -erff1(-u) : erff1(u); return ( 0.5 * (1.0 + e) ); } -REAL erff_poly_only( const REAL& x ) { - const REAL p = 0.3275911; - const REAL a1 = 0.254829592, a2 = -0.284496736, a3 = 1.421413741, a4 = -1.453152027, a5 = 1.061405429; +real_t erff_poly_only( const real_t& x ) { + const real_t p = 0.3275911; + const real_t a1 = 0.254829592, a2 = -0.284496736, a3 = 1.421413741, a4 = -1.453152027, a5 = 1.061405429; - const REAL t = 1.0/(1.0+p*x); - const REAL t2 = t * t; - const REAL t3 = t * t2; - const REAL t4 = t2 * t2; - const REAL t5 = t2 * t3; + const real_t t = 1.0/(1.0+p*x); + const real_t t2 = t * t; + const real_t t3 = t * t2; + const real_t t4 = t2 * t2; + const real_t t5 = t2 * t3; - const REAL res = (a1*t + a2*t2 + a3*t3 + a4*t4 + a5*t5); + const real_t res = (a1*t + a2*t2 + a3*t3 + a4*t4 + a5*t5); return res; // erff was: ( 1.0 - res * exp(-(x*x)) ); } -REAL uGaussian_P_withExpFactor( const REAL& x, const REAL exp_factor ) { - const REAL u = fabs( x / sqrt(2.0) ); - const REAL e = erff_poly_only(u); +real_t uGaussian_P_withExpFactor( const real_t& x, const real_t exp_factor ) { + const real_t u = fabs( x / sqrt(2.0) ); + const real_t e = erff_poly_only(u); - REAL res = 0.5 * e * exp(exp_factor-u*u); + real_t res = 0.5 * e * exp(exp_factor-u*u); if( x >= 0.0 ) { res = exp(exp_factor) - res; @@ -73,10 +73,10 @@ REAL uGaussian_P_withExpFactor( const REAL& x, const REAL exp_factor ) { // otherwise follows the real implementation //////////////////////////////////////////////////////////////////////// // N is the size of scales (bbi) -REAL to_solve( const UINT& fid, const UINT& N, const REAL* scales, const REAL* bbi, const REAL& yhat ) { +real_t to_solve( const UINT& fid, const UINT& N, const real_t* scales, const real_t* bbi, const real_t& yhat ) { if ( fid == 33 ) return (yhat+3.0)*(yhat-1.0)*(yhat-1.0); else { - REAL accum = 0.0; + real_t accum = 0.0; for( UINT i = 0; i < N; i++ ) { accum += scales[i] * exp( - bbi[i] * yhat ); } @@ -96,26 +96,26 @@ def bisection(f,lb,ub,N=50): void rootBisection( const UINT& fid, const UINT& N, - const REAL* scale, - const REAL* bbi, - const REAL& lb, - const REAL& ub, - const REAL& toll, + const real_t* scale, + const real_t* bbi, + const real_t& lb, + const real_t& ub, + const real_t& toll, const UINT& it_mx, - REAL& root, // result + real_t& root, // result UINT& it, - REAL& fb + real_t& fb ) { // IMPLEMENT THIS HERE!!! - const REAL tol = (toll <= 0.0) ? 1.0e-9 : toll; - const REAL iter_max = (it_mx <= 0 ) ? IT_MAX : it_mx; + const real_t tol = (toll <= 0.0) ? 1.0e-9 : toll; + const real_t iter_max = (it_mx <= 0 ) ? IT_MAX : it_mx; - REAL a = lb, b = ub; + real_t a = lb, b = ub; - REAL x, fx; + real_t x, fx; it = 0; - REAL fa = to_solve(fid, N, scale, bbi, a); + real_t fa = to_solve(fid, N, scale, bbi, a); fb = to_solve(fid, N, scale, bbi, b); if( fa*fb >= 0.0 ) { @@ -152,22 +152,22 @@ void rootBisection( void rootFinding_Brent ( const UINT& fid, const UINT& N, - const REAL* scale, - const REAL* bbi, - const REAL& lb, - const REAL& ub, - const REAL& toll, + const real_t* scale, + const real_t* bbi, + const real_t& lb, + const real_t& ub, + const real_t& toll, const UINT& it_mx, - REAL& root, // result + real_t& root, // result UINT& it, - REAL& fb + real_t& fb ) { - const REAL tol = (toll <= 0.0) ? 1.0e-9 : toll; - const REAL iter_max = (it_mx <= 0 ) ? IT_MAX : it_mx; + const real_t tol = (toll <= 0.0) ? 1.0e-9 : toll; + const real_t iter_max = (it_mx <= 0 ) ? IT_MAX : it_mx; - REAL a = lb, b = ub; + real_t a = lb, b = ub; - REAL fa = to_solve(fid, N, scale, bbi, a); + real_t fa = to_solve(fid, N, scale, bbi, a); fb = to_solve(fid, N, scale, bbi, b); if( fa*fb >= 0.0 ) { @@ -177,22 +177,22 @@ void rootFinding_Brent ( return; } - if( fabs(fa) < fabs(fb) ) { REAL tmp = fa; fa = fb; fb = tmp; tmp = a; a = b; b = tmp; } + if( fabs(fa) < fabs(fb) ) { real_t tmp = fa; fa = fb; fb = tmp; tmp = a; a = b; b = tmp; } - REAL c = a, fc = fa; + real_t c = a, fc = fa; bool mflag = true; - REAL d = 0.0; + real_t d = 0.0; it = 0; for( UINT i = 0; i < iter_max; i++ ) { if ( fb != 0.0 && fabs(b-a) >= tol ) { - REAL s; + real_t s; if( fa == fc || fb == fc ) { s = b - fb * (b - a) / (fb - fa); } else { - REAL s1 = (a*fb*fc)/( (fa-fb)*(fa-fc) ); - REAL s2 = (b*fa*fc)/( (fb-fa)*(fb-fc) ); - REAL s3 = (c*fa*fb)/( (fc-fa)*(fc-fb) ); + real_t s1 = (a*fb*fc)/( (fa-fb)*(fa-fc) ); + real_t s2 = (b*fa*fc)/( (fb-fa)*(fb-fc) ); + real_t s3 = (c*fa*fb)/( (fc-fa)*(fc-fb) ); s = s1 + s2 + s3; } @@ -207,7 +207,7 @@ void rootFinding_Brent ( mflag = false; } - REAL fs = to_solve(fid, N, scale, bbi, s); + real_t fs = to_solve(fid, N, scale, bbi, s); // d is assigned for the first time here: // it's not used above because mflag is set @@ -218,7 +218,7 @@ void rootFinding_Brent ( else { a = s; fa = fs; } if( fabs(fa) < fabs(fb) ) { - REAL tmp; + real_t tmp; tmp = a; a = b; b = tmp; tmp = fa; fa = fb; fb = tmp; } @@ -243,9 +243,9 @@ void rootFinding_Brent ( int test_math() { // Rootfinder.brent (-4.) (4./.3.) (fun x -> (x+.3.)*.(x-.1.)**2.) 1e-4 == -3 printf("# Brent test: %f => ", -3.0); - REAL scale[1] = { 0.0 }, bbi[1] = { 0.0 }; + real_t scale[1] = { 0.0 }, bbi[1] = { 0.0 }; - REAL root, err; UINT it; + real_t root, err; UINT it; rootFinding_Brent(33, 1, scale, bbi, -4.0, 4.0/3.0, 0.0, 0, root, it, err); if( equalEps(root, -3.0) ) printf(" SUCCESS!\n\n"); else printf(" %f FAILS!\n\n", root); diff --git a/benchmarks/InterestCalib/lib/include/ParseInput.h b/benchmarks/InterestCalib/lib/include/ParseInput.h new file mode 100644 index 0000000..9cde8ba --- /dev/null +++ b/benchmarks/InterestCalib/lib/include/ParseInput.h @@ -0,0 +1,102 @@ +#ifndef PARSE_INPUT +#define PARSE_INPUT + +#include "ParserC.h" +#include +#include +#include +#include "GenAlgUtil.h" + +//using namespace std; + +#if REAL_IS_FLOAT + #define read_real read_float +#else + #define read_real read_double +#endif + +/***********************************/ +/********** READ DATA SET **********/ +/***********************************/ + +void readDataSet( UINT& pop_size, + UINT& num_conv_iters, + UINT& num_swap_quotes, + real_t*& swaption_quotes, // [num_swap_quotes,4] + + UINT& num_hermitians, + real_t*& hermite_coefs, // [num_hermite] + real_t*& hermite_weights, // [num_hermite] + + UINT& num_sobol_bits, + int*& sobol_dirs_vct // [num_sobol_bits] +) { + int64_t shape[3]; + bool atr_ok = true; + + if ( read_int( static_cast( &pop_size ) ) || + read_int( static_cast( &num_conv_iters ) ) ) { + fprintf(stderr, "Syntax error when reading population size or convergence-loop count!\n"); + exit(1); + } + atr_ok = (pop_size >= 64) && (num_conv_iters >= 100); + assert(atr_ok && "Population size < 64 OR convergence-loop count < 100!\n"); + + { // swaption quotes + if ( read_int( static_cast( &num_swap_quotes ) ) ) { + fprintf(stderr, "Syntax error when reading NUM_SWAP_QUOTES.\n"); + exit(1); + } + atr_ok = num_swap_quotes > 0; + assert(atr_ok && "Number of swaptions LESS or equal to ZERO!\n"); + + if ( read_array(sizeof(real_t), read_real, (void**)&swaption_quotes, shape, 2) ) { + fprintf(stderr, "Syntax error when reading the swaption quotes.\n"); + exit(1); + } + atr_ok = ( shape[1] == 4 && shape[0] == num_swap_quotes ); + assert(atr_ok && "Incorrect shape of the swaption quotes!"); + } + + { // hermitean coefficients + if ( read_int( static_cast( &num_hermitians ) ) ) { + fprintf(stderr, "Syntax error when reading number of hermitians.\n"); + exit(1); + } + atr_ok = num_hermitians > 0; + assert(atr_ok && "Number of hermitians LESS or equal to ZERO!\n"); + + if ( read_array(sizeof(real_t), read_real, (void**)&hermite_coefs, shape, 1) ) { + fprintf(stderr, "Syntax error when reading the hermitian coeficients.\n"); + exit(1); + } + atr_ok = ( shape[0] == num_hermitians ); + assert(atr_ok && "Incorrect shape of the hermitian coefficients!"); + + if ( read_array(sizeof(real_t), read_real, (void**)&hermite_weights, shape, 1) ) { + fprintf(stderr, "Syntax error when reading the hermitian weights.\n"); + exit(1); + } + atr_ok = ( shape[0] == num_hermitians ); + assert(atr_ok && "Incorrect shape of the hermitian weights!"); + } + + { // sobol direction vectors! + if ( read_int( static_cast( &num_sobol_bits ) ) ) { + fprintf(stderr, "Syntax error when reading NUM_SOBOL_BITS.\n"); + exit(1); + } + atr_ok = num_sobol_bits > 0; + assert(atr_ok && "Number of sobol bits LESS or equal to ZERO!\n"); + + if ( read_array(sizeof(int), read_int, (void**)&sobol_dirs_vct, shape, 1) ) { + fprintf(stderr, "Syntax error when reading sobol direction vectors.\n"); + exit(1); + } + atr_ok = ( shape[0] == num_sobol_bits ); + assert( atr_ok && "Incorrect shape of sobol direction vectors!" ); + } +} + +#endif // PARSE_INPUT + diff --git a/benchmarks/InterestCalib/lib/include/WriteResult.h b/benchmarks/InterestCalib/lib/include/WriteResult.h new file mode 100644 index 0000000..93c9453 --- /dev/null +++ b/benchmarks/InterestCalib/lib/include/WriteResult.h @@ -0,0 +1,37 @@ +#ifndef WRITERESULT_H +#define WRITERESULT_H + +#include + +/* Writes trailing comma and newline. */ +void writeRealField(FILE *stream, const char* field, real_t x) +{ + fprintf(stream, "\"%s\": %f,\n", field, x); +} + +void writeResult(FILE *stream, + real_t a, + real_t b, + real_t sigma, + real_t nu, + real_t rho, + real_t logLik, + real_t* calib_arr) +{ + /* Hackily manually generate JSON. It would be nice with some + proper library support. */ + fprintf(stream, "{\n"); + + writeRealField(stream, "a_field", a); + writeRealField(stream, "b_field", b); + writeRealField(stream, "sigma_field", sigma); + writeRealField(stream, "nu_field", nu); + writeRealField(stream, "rho_field", rho); + writeRealField(stream, "lg_likelyhood", logLik); + + fprintf(stream, "\"swaption_calibration_result\":\n"); + write_2Darr(stream, calib_arr, static_cast(NUM_SWAP_QUOTES), 3); + fprintf(stream, "}\n"); +} + +#endif diff --git a/benchmarks/InterestCalib/validation_function b/benchmarks/InterestCalib/validation_function new file mode 100755 index 0000000..51bbeff --- /dev/null +++ b/benchmarks/InterestCalib/validation_function @@ -0,0 +1,78 @@ +#!/usr/bin/env python + +import os +import sys +import json +import math + +LG_LIKELIHOOD_TOLERANCE1 = 1.0 +LG_LIKELIHOOD_TOLERANCE2 = 0.5 +LG_LIKELIHOOD_TOLERANCE3 = 0.7 +LLHOOD_CAUCHY_OFFS = 5.0 + +def read_json_file(filename): + """ returns an array containing the content of the JSON file. + + keyword arguments: + filename -- name of json file to interpret + """ + with open(filename, "r") as file: + return json.loads(file.read()) + +def get_arguments(): + if len(sys.argv) != 3: + raise Exception("Usage: %s "% (sys.argv[0]) ) + return (sys.argv[1], sys.argv[2]) + +def cauchy_pdf(z, mu, gamma): + x = (z-mu) / gamma + return 1/(math.pi * gamma * (1+x*x)) + +def log_likelihood(y_ref, y): # CAUCHY + gamma = (abs(y_ref) / 50.0) * LLHOOD_CAUCHY_OFFS + 0.01 + pdfs = cauchy_pdf(y, y_ref, gamma) + pdfs += 1e-20 # avoid NaNs + return math.log(pdfs) + +def validate_swaption(calc_swap, expt_swap): + """ Checks whether the result (excluding the lg_likelyhood part of the JSON object) validates. + """ + N = len(calc_swap) + if N != len(expt_swap): + raise Exception("The length of the swaption result array is different for the calculated and expected result: len(calculated swaption result array: %d. Expected result array: %d)" % (N, len(expt_swap))) + for i in range(N): + lg_lh_calc = log_likelihood(calc_swap[i][1], calc_swap[i][0]) + lg_lh_expt = log_likelihood(expt_swap[i][1], expt_swap[i][0]) + diff_curr_lg_lh = 0.0 if (lg_lh_calc > lg_lh_expt) else (lg_lh_expt - lg_lh_calc) + if diff_curr_lg_lh > LG_LIKELIHOOD_TOLERANCE3: + raise Exception("Error in swaption result validation.git Error of result number %d: %f. Acceptable: %f" % + (i, diff_curr_lg_lh, LG_LIKELIHOOD_TOLERANCE3)) + +def validate(calculated_result_file, expected_result_file): + """ Checks if the calculated result and the expected result are close enough to be considered valid. + All errors in validation must throw an exception, otherwise validate will wrongly return succesful. + """ + calc = read_json_file(os.path.join(os.getcwd(), calculated_result_file)) + expt = read_json_file(os.path.join(os.getcwd(), expected_result_file)) + calc_lg_lh = calc['lg_likelyhood'] + expt_lg_lh = expt['lg_likelyhood'] + dev = abs(calc_lg_lh - expt_lg_lh) + if (dev > LG_LIKELIHOOD_TOLERANCE1): + raise Exception("Difference in log likelihood > %f. Result log likelihood: %f, reference log likelihood: %f" % + (LG_LIKELIHOOD_TOLERANCE1, calc_lg_lh, expt_lg_lh)) + if (expt_lg_lh - calc_lg_lh) > LG_LIKELIHOOD_TOLERANCE2: + raise Exception("Result likelihood is worse than reference with more than %f. Result log likelihood: %f, reference log likelihood %f" % (LG_LIKELIHOOD_TOLERANCE2, calc_lg_lh, expt_lg_lh)) + expt_res = expt['swaption_calibration_result'] + calc_res = calc['swaption_calibration_result'] + validate_swaption(calc_res, expt_res) + +if __name__ == "__main__": + (calculated_result, expected_result) = get_arguments() + try: + validate(calculated_result, expected_result) + print("Validation succesfull") + exit(0) + except Exception as e: + print("Validation failed:") + print("%s: %s" % (type(e), e.args)) + exit(1) diff --git a/LocVolCalib/README.txt b/benchmarks/LocVolCalib/README.txt similarity index 98% rename from LocVolCalib/README.txt rename to benchmarks/LocVolCalib/README.txt index 36926e4..848f0be 100644 --- a/LocVolCalib/README.txt +++ b/benchmarks/LocVolCalib/README.txt @@ -1,3 +1,4 @@ +FIXME: this README is outdated. 1. This is a benchmark received from Nordea, via Prof. Brian Vinter. Here is Christian's (Andreetta) guess about what the application is about: diff --git a/LocVolCalib/ToDo.txt b/benchmarks/LocVolCalib/ToDo.txt similarity index 100% rename from LocVolCalib/ToDo.txt rename to benchmarks/LocVolCalib/ToDo.txt diff --git a/benchmarks/LocVolCalib/datasets/large/input.json b/benchmarks/LocVolCalib/datasets/large/input.json new file mode 100644 index 0000000..d0db1fc --- /dev/null +++ b/benchmarks/LocVolCalib/datasets/large/input.json @@ -0,0 +1,6 @@ +{ + "outer" : 256, + "num_x" : 256, + "num_y" : 256, + "num_t" : 64 +} diff --git a/LocVolCalib/Data/Large/output.data b/benchmarks/LocVolCalib/datasets/large/output.json similarity index 60% rename from LocVolCalib/Data/Large/output.data rename to benchmarks/LocVolCalib/datasets/large/output.json index 45e37ed..8ea53b5 100644 --- a/LocVolCalib/Data/Large/output.data +++ b/benchmarks/LocVolCalib/datasets/large/output.json @@ -1,29 +1,29 @@ -[ 0.029996 , 0.029204 , 0.028803 , 0.028405 , 0.028013 , 0.027626 , 0.027245 , 0.026870 , 0.026500 , - 0.026136 , 0.025778 , 0.025426 , 0.025080 , 0.024739 , 0.024404 , 0.024075 , 0.023751 , 0.023433 , - 0.023120 , 0.022813 , 0.022511 , 0.022214 , 0.021923 , 0.021636 , 0.021355 , 0.021078 , 0.020806 , - 0.020538 , 0.020273 , 0.020014 , 0.019791 , 0.019512 , 0.019270 , 0.019033 , 0.018799 , 0.018568 , - 0.018341 , 0.018117 , 0.017898 , 0.017682 , 0.017470 , 0.017261 , 0.017056 , 0.016855 , 0.016657 , - 0.016463 , 0.016271 , 0.016083 , 0.015898 , 0.015716 , 0.015537 , 0.015361 , 0.015188 , 0.015018 , - 0.014850 , 0.014686 , 0.014523 , 0.014364 , 0.014206 , 0.014052 , 0.013899 , 0.013749 , 0.013601 , - 0.013456 , 0.013312 , 0.013171 , 0.013032 , 0.012895 , 0.012760 , 0.012626 , 0.012495 , 0.012365 , - 0.012238 , 0.012112 , 0.011988 , 0.011865 , 0.011744 , 0.011625 , 0.011508 , 0.011392 , 0.011277 , - 0.011164 , 0.011053 , 0.010942 , 0.010834 , 0.010726 , 0.010620 , 0.010515 , 0.010412 , 0.010309 , - 0.010208 , 0.010108 , 0.010010 , 0.009912 , 0.009815 , 0.009720 , 0.009626 , 0.009533 , 0.009440 , - 0.009349 , 0.009259 , 0.009170 , 0.009081 , 0.008994 , 0.008908 , 0.008822 , 0.008737 , 0.008653 , - 0.008570 , 0.008488 , 0.008407 , 0.008326 , 0.008246 , 0.008167 , 0.008089 , 0.008011 , 0.007934 , - 0.007858 , 0.007782 , 0.007707 , 0.007633 , 0.007559 , 0.007487 , 0.007414 , 0.007342 , 0.007271 , - 0.007201 , 0.007131 , 0.007061 , 0.006993 , 0.006924 , 0.006856 , 0.006789 , 0.006722 , 0.006656 , - 0.006590 , 0.006525 , 0.006460 , 0.006396 , 0.006332 , 0.006268 , 0.006205 , 0.006143 , 0.006081 , - 0.006019 , 0.005958 , 0.005897 , 0.005836 , 0.005776 , 0.005716 , 0.005657 , 0.005598 , 0.005539 , - 0.005481 , 0.005423 , 0.005365 , 0.005308 , 0.005251 , 0.005194 , 0.005138 , 0.005081 , 0.005026 , - 0.004970 , 0.004915 , 0.004860 , 0.004806 , 0.004751 , 0.004697 , 0.004643 , 0.004590 , 0.004536 , - 0.004483 , 0.004431 , 0.004378 , 0.004326 , 0.004274 , 0.004222 , 0.004170 , 0.004119 , 0.004068 , - 0.004017 , 0.003966 , 0.003915 , 0.003865 , 0.003815 , 0.003765 , 0.003715 , 0.003665 , 0.003616 , - 0.003566 , 0.003517 , 0.003468 , 0.003420 , 0.003371 , 0.003323 , 0.003274 , 0.003226 , 0.003178 , - 0.003130 , 0.003083 , 0.003035 , 0.002988 , 0.002940 , 0.002893 , 0.002846 , 0.002799 , 0.002752 , - 0.002706 , 0.002659 , 0.002613 , 0.002566 , 0.002520 , 0.002474 , 0.002428 , 0.002382 , 0.002337 , - 0.002291 , 0.002245 , 0.002200 , 0.002154 , 0.002109 , 0.002064 , 0.002019 , 0.001973 , 0.001928 , - 0.001884 , 0.001839 , 0.001794 , 0.001749 , 0.001705 , 0.001660 , 0.001616 , 0.001571 , 0.001527 , - 0.001482 , 0.001438 , 0.001394 , 0.001350 , 0.001306 , 0.001262 , 0.001218 , 0.001174 , 0.001130 , - 0.001086 , 0.001042 , 0.000998 , 0.000954 , 0.000911 , 0.000867 , 0.000823 , 0.000780 , 0.000736 , - 0.000692 , 0.000649 , 0.000605 , 0.000562 ] // Standard Result for the Large dataset of Volatility Calibration. +[ 0.029996 , 0.029204 , 0.028803 , 0.028405 , 0.028013 , 0.027626 , 0.027245 , 0.026870 , 0.026500 , + 0.026136 , 0.025778 , 0.025426 , 0.025080 , 0.024739 , 0.024404 , 0.024075 , 0.023751 , 0.023433 , + 0.023120 , 0.022813 , 0.022511 , 0.022214 , 0.021923 , 0.021636 , 0.021355 , 0.021078 , 0.020806 , + 0.020538 , 0.020273 , 0.020014 , 0.019791 , 0.019512 , 0.019270 , 0.019033 , 0.018799 , 0.018568 , + 0.018341 , 0.018117 , 0.017898 , 0.017682 , 0.017470 , 0.017261 , 0.017056 , 0.016855 , 0.016657 , + 0.016463 , 0.016271 , 0.016083 , 0.015898 , 0.015716 , 0.015537 , 0.015361 , 0.015188 , 0.015018 , + 0.014850 , 0.014686 , 0.014523 , 0.014364 , 0.014206 , 0.014052 , 0.013899 , 0.013749 , 0.013601 , + 0.013456 , 0.013312 , 0.013171 , 0.013032 , 0.012895 , 0.012760 , 0.012626 , 0.012495 , 0.012365 , + 0.012238 , 0.012112 , 0.011988 , 0.011865 , 0.011744 , 0.011625 , 0.011508 , 0.011392 , 0.011277 , + 0.011164 , 0.011053 , 0.010942 , 0.010834 , 0.010726 , 0.010620 , 0.010515 , 0.010412 , 0.010309 , + 0.010208 , 0.010108 , 0.010010 , 0.009912 , 0.009815 , 0.009720 , 0.009626 , 0.009533 , 0.009440 , + 0.009349 , 0.009259 , 0.009170 , 0.009081 , 0.008994 , 0.008908 , 0.008822 , 0.008737 , 0.008653 , + 0.008570 , 0.008488 , 0.008407 , 0.008326 , 0.008246 , 0.008167 , 0.008089 , 0.008011 , 0.007934 , + 0.007858 , 0.007782 , 0.007707 , 0.007633 , 0.007559 , 0.007487 , 0.007414 , 0.007342 , 0.007271 , + 0.007201 , 0.007131 , 0.007061 , 0.006993 , 0.006924 , 0.006856 , 0.006789 , 0.006722 , 0.006656 , + 0.006590 , 0.006525 , 0.006460 , 0.006396 , 0.006332 , 0.006268 , 0.006205 , 0.006143 , 0.006081 , + 0.006019 , 0.005958 , 0.005897 , 0.005836 , 0.005776 , 0.005716 , 0.005657 , 0.005598 , 0.005539 , + 0.005481 , 0.005423 , 0.005365 , 0.005308 , 0.005251 , 0.005194 , 0.005138 , 0.005081 , 0.005026 , + 0.004970 , 0.004915 , 0.004860 , 0.004806 , 0.004751 , 0.004697 , 0.004643 , 0.004590 , 0.004536 , + 0.004483 , 0.004431 , 0.004378 , 0.004326 , 0.004274 , 0.004222 , 0.004170 , 0.004119 , 0.004068 , + 0.004017 , 0.003966 , 0.003915 , 0.003865 , 0.003815 , 0.003765 , 0.003715 , 0.003665 , 0.003616 , + 0.003566 , 0.003517 , 0.003468 , 0.003420 , 0.003371 , 0.003323 , 0.003274 , 0.003226 , 0.003178 , + 0.003130 , 0.003083 , 0.003035 , 0.002988 , 0.002940 , 0.002893 , 0.002846 , 0.002799 , 0.002752 , + 0.002706 , 0.002659 , 0.002613 , 0.002566 , 0.002520 , 0.002474 , 0.002428 , 0.002382 , 0.002337 , + 0.002291 , 0.002245 , 0.002200 , 0.002154 , 0.002109 , 0.002064 , 0.002019 , 0.001973 , 0.001928 , + 0.001884 , 0.001839 , 0.001794 , 0.001749 , 0.001705 , 0.001660 , 0.001616 , 0.001571 , 0.001527 , + 0.001482 , 0.001438 , 0.001394 , 0.001350 , 0.001306 , 0.001262 , 0.001218 , 0.001174 , 0.001130 , + 0.001086 , 0.001042 , 0.000998 , 0.000954 , 0.000911 , 0.000867 , 0.000823 , 0.000780 , 0.000736 , + 0.000692 , 0.000649 , 0.000605 , 0.000562 ] diff --git a/benchmarks/LocVolCalib/datasets/medium/input.json b/benchmarks/LocVolCalib/datasets/medium/input.json new file mode 100644 index 0000000..4b6f586 --- /dev/null +++ b/benchmarks/LocVolCalib/datasets/medium/input.json @@ -0,0 +1,6 @@ +{ + "outer" : 128, + "num_x" : 256, + "num_y" : 32, + "num_t" : 64 +} diff --git a/LocVolCalib/Data/Medium/output.data b/benchmarks/LocVolCalib/datasets/medium/output.json similarity index 93% rename from LocVolCalib/Data/Medium/output.data rename to benchmarks/LocVolCalib/datasets/medium/output.json index a8fc75d..4d5f9c1 100644 --- a/LocVolCalib/Data/Medium/output.data +++ b/benchmarks/LocVolCalib/datasets/medium/output.json @@ -1,7 +1,7 @@ [ 0.03, 0.0292079, 0.0288058, 0.028408, 0.0280152, 0.0276279, 0.0272462, 0.0268701, 0.0264998, 0.0261355, 0.025777, 0.0254243, 0.0250773, 0.024736, 0.0244004, 0.0240704, 0.0237459, 0.0234269, 0.0231134, 0.0228053, 0.0225025, 0.022205, 0.0219126, 0.0216253, - 0.0213431, 0.0210657, 0.0207928, 0.0205238, 0.0202581, 0.0199978, 0.0197739, 0.0194946, + 0.0213431, 0.0210657, 0.0207928, 0.0205238, 0.0202581, 0.0199978, 0.0197739, 0.0194946, 0.0192514, 0.0190136, 0.0187787, 0.018547, 0.0183189, 0.0180947, 0.0178743, 0.0176577, 0.0174448, 0.0172356, 0.0170299, 0.0168278, 0.016629, 0.0164336, 0.0162415, 0.0160526, 0.0158668, 0.0156841, 0.0155044, 0.0153276, 0.0151536, 0.0149826, 0.0148144, 0.0146488, @@ -14,5 +14,4 @@ 0.00884636, 0.00876059, 0.00867569, 0.00859167, 0.00850848, 0.00842613, 0.00834459, 0.00826384, 0.00818388, 0.00810468, 0.00802623, 0.00794852, 0.00787153, 0.00779524, 0.00771969, 0.00764481, 0.0075706, 0.00749704, 0.00742412, 0.00735183, 0.00728016, 0.00720909, 0.00713861, 0.00706872 -] // Standard Result for the Medium dataset of Volatility Calibration. - +] diff --git a/benchmarks/LocVolCalib/datasets/small/input.json b/benchmarks/LocVolCalib/datasets/small/input.json new file mode 100644 index 0000000..e14df83 --- /dev/null +++ b/benchmarks/LocVolCalib/datasets/small/input.json @@ -0,0 +1,6 @@ +{ + "outer" : 16, + "num_x" : 32, + "num_y" : 256, + "num_t" : 256 +} diff --git a/LocVolCalib/Data/Small/output.data b/benchmarks/LocVolCalib/datasets/small/output.json similarity index 60% rename from LocVolCalib/Data/Small/output.data rename to benchmarks/LocVolCalib/datasets/small/output.json index 4f1742f..a316bb0 100644 --- a/LocVolCalib/Data/Small/output.data +++ b/benchmarks/LocVolCalib/datasets/small/output.json @@ -1,4 +1,3 @@ -[ 0.0300001, 0.0290001, 0.0280001, 0.0270001, 0.026, 0.0251064, 0.0247889, 0.0244714, +[ 0.0300001, 0.0290001, 0.0280001, 0.0270001, 0.026, 0.0251064, 0.0247889, 0.0244714, 0.0241539, 0.0238364, 0.0235189, 0.0232014, 0.0228839, 0.0225664, 0.0222744, 0.02199 -] // Standard Result for the Small dataset of Volatility Calibration. - +] diff --git a/LocVolCalib/AllParOpenCLMP/CrankNicolson.cl b/benchmarks/LocVolCalib/implementations/cpp_openclmp_all/CrankNicolson.cl similarity index 69% rename from LocVolCalib/AllParOpenCLMP/CrankNicolson.cl rename to benchmarks/LocVolCalib/implementations/cpp_openclmp_all/CrankNicolson.cl index d8cad56..bd57356 100644 --- a/LocVolCalib/AllParOpenCLMP/CrankNicolson.cl +++ b/benchmarks/LocVolCalib/implementations/cpp_openclmp_all/CrankNicolson.cl @@ -1,15 +1,5 @@ -#include "../includeC/Constants.h" - - -#if (WITH_FLOATS) - typedef float4 REAL4; - typedef float2 REAL2; - typedef float3 REAL3; -#else - typedef double4 REAL4; - typedef double2 REAL2; - typedef double3 REAL3; -#endif +#include "Constants.h" + /**************************************************************************/ /**************** SHARED-MEMORY ACCESSOR FUNCTIONS ************************/ @@ -19,34 +9,34 @@ #define WITH_INTERLEAVED_BANKS2 1 #if WITH_INTERLEAVED_BANKS2 -inline void store2(REAL2 val, unsigned int ind, __local REAL* cache) { +inline void store2(real2_t val, unsigned int ind, __local real_t* cache) { ind = (ind & (WORKGROUP_SIZE-1)) + ( (ind >> logWORKGROUP_SIZE) << (logWORKGROUP_SIZE+1) ); cache[ind] = val.x; ind += WORKGROUP_SIZE; cache[ind] = val.y; } -inline REAL2 load2(unsigned int ind, __local REAL* cache) { +inline real2_t load2(unsigned int ind, __local real_t* cache) { ind = (ind & (WORKGROUP_SIZE-1)) + ( (ind >> logWORKGROUP_SIZE) << (logWORKGROUP_SIZE+1) ); - REAL2 val; + real2_t val; val.x = cache[ind]; ind += WORKGROUP_SIZE; val.y = cache[ind]; return val; } #else -inline void store2(REAL2 val, unsigned int ind, volatile __local REAL2* cache) { +inline void store2(real2_t val, unsigned int ind, volatile __local real2_t* cache) { cache[ind] = val; } -inline REAL2 load2(unsigned int ind, volatile __local REAL2* cache) { +inline real2_t load2(unsigned int ind, volatile __local real2_t* cache) { return cache[ind]; } #endif #if WITH_INTERLEAVED_BANKS4 -inline void store4(REAL4 val, unsigned int ind, __local REAL* cache) { +inline void store4(real4_t val, unsigned int ind, __local real_t* cache) { //ind = (ind / WORKGROUP_SIZE)*(WORKGROUP_SIZE) * 4 + (ind % WORKGROUP_SIZE); ind = (ind & (WORKGROUP_SIZE-1)) + ( (ind >> logWORKGROUP_SIZE) << (logWORKGROUP_SIZE+2) ); cache[ind] = val.x; @@ -58,8 +48,8 @@ inline void store4(REAL4 val, unsigned int ind, __local REAL* cache) { cache[ind] = val.w; } -inline REAL4 load4(unsigned int ind, __local REAL* cache) { - REAL4 val; +inline real4_t load4(unsigned int ind, __local real_t* cache) { + real4_t val; //ind = (ind / WORKGROUP_SIZE)*(WORKGROUP_SIZE) * 4 + (ind % WORKGROUP_SIZE); ind = (ind & (WORKGROUP_SIZE-1)) + ( (ind >> logWORKGROUP_SIZE) << (logWORKGROUP_SIZE+2) ); val.x = cache[ind]; @@ -72,11 +62,11 @@ inline REAL4 load4(unsigned int ind, __local REAL* cache) { return val; } #else -inline void store4(REAL4 val, unsigned int ind, volatile __local REAL4* cache) { +inline void store4(real4_t val, unsigned int ind, volatile __local real4_t* cache) { cache[ind] = val; } -inline REAL4 load4(unsigned int ind, volatile __local REAL4* cache) { +inline real4_t load4(unsigned int ind, volatile __local real4_t* cache) { return cache[ind]; } #endif @@ -87,45 +77,45 @@ __kernel void prepare_tridag_x ( /*** Read-Only Scalars ***/ __global RWScalars* ro_scals, // __constant /*** Read-Only Arrays ***/ - __global REAL* myX, - __global REAL3* myDx, - __global REAL3* myDxx, - __constant REAL* myY, - __constant REAL* myDy, - __constant REAL* myDyy, + __global real_t* myX, + __global real3_t* myDx, + __global real3_t* myDxx, + __constant real_t* myY, + __constant real_t* myDy, + __constant real_t* myDyy, /*** Read-Write Temporary Arrays ***/ - __global REAL* a, - __global REAL* b, - __global REAL* c, - __global REAL* y, - __global REAL* u, - __global REAL* v, - __global REAL4* scan_tmp, + __global real_t* a, + __global real_t* b, + __global real_t* c, + __global real_t* y, + __global real_t* u, + __global real_t* v, + __global real4_t* scan_tmp, /*** Temporary Array in Shared Space ***/ - __local REAL* cache_tmp, + __local real_t* cache_tmp, /*** The Result Array ***/ - __global REAL* res_arr + __global real_t* res_arr ) { - REAL3 myDy_elem, myDyy_elem, myres_elem; - REAL cur_myVar = ro_scals->nu; - REAL cur_myMu = 0.0; + real3_t myDy_elem, myDyy_elem, myres_elem; + real_t cur_myVar = ro_scals->nu; + real_t cur_myMu = 0.0; unsigned int glob_ind = get_global_id(2) * get_global_size(1) * get_global_size(0); const unsigned int ind = glob_ind + get_global_id(1)*get_global_size(0) + get_global_id(0); - REAL tmp = 0.0; + real_t tmp = 0.0; cur_myVar *= cur_myVar; // second loop { - myres_elem = (REAL3)( (get_global_id(1)!=0) ? res_arr[ind - get_global_size(0)] : 0.0, + myres_elem = (real3_t)( (get_global_id(1)!=0) ? res_arr[ind - get_global_size(0)] : 0.0, res_arr[ind], (get_global_id(1) != get_global_size(1)-1) ? res_arr[ind + get_global_size(0)] : 0.0 ); - myDy_elem = (REAL3)( myDy[get_global_id(1)<<2], myDy[ (get_global_id(1)<<2)+1], myDy[(get_global_id(1)<<2)+2] ); - myDyy_elem = (REAL3)( myDyy[get_global_id(1)<<2], myDyy[(get_global_id(1)<<2)+1], myDyy[(get_global_id(1)<<2)+2] ); + myDy_elem = (real3_t)( myDy[get_global_id(1)<<2], myDy[ (get_global_id(1)<<2)+1], myDy[(get_global_id(1)<<2)+2] ); + myDyy_elem = (real3_t)( myDyy[get_global_id(1)<<2], myDyy[(get_global_id(1)<<2)+1], myDyy[(get_global_id(1)<<2)+2] ); myDy_elem = cur_myMu*myDy_elem + 0.5f*cur_myVar*myDyy_elem; myDy_elem *= myres_elem; @@ -152,7 +142,7 @@ __kernel void prepare_tridag_x ( barrier(CLK_LOCAL_MEM_FENCE); - myres_elem = (REAL3)( (get_global_id(0)!=0) ? cache_tmp[ glob_ind - 1 ] : 0.0, + myres_elem = (real3_t)( (get_global_id(0)!=0) ? cache_tmp[ glob_ind - 1 ] : 0.0, cache_tmp[ glob_ind ], (get_global_id(0) != get_global_size(0)-1) ? cache_tmp[ glob_ind + 1 ] : 0.0 ); @@ -178,10 +168,10 @@ __kernel void prepare_tridag_x ( // third loop if( get_global_id(0) > 0 ) { - scan_tmp[ind] = (REAL4) ( tmp, myDy_elem.x * c[ind-1], 1.0, 0.0 ); + scan_tmp[ind] = (real4_t) ( tmp, myDy_elem.x * c[ind-1], 1.0, 0.0 ); } else { // i == get_global_id(0) == 0 y[ind] = tmp; // = b [ind] - scan_tmp[ind] = (REAL4) ( tmp, 0.0, 0.0, tmp ); + scan_tmp[ind] = (real4_t) ( tmp, 0.0, 0.0, tmp ); } } @@ -195,18 +185,18 @@ __kernel void prepare_tridag_y ( /*** Read-Only Scalars ***/ __global RWScalars* ro_scals, // __constant /*** Read-Only Arrays ***/ - __global REAL3* myDy, - __global REAL3* myDyy, + __global real3_t* myDy, + __global real3_t* myDyy, /*** Read-Write Temporary Arrays ***/ - __global REAL* a, - __global REAL* b, - __global REAL* c, - __global REAL* u, - __global REAL* v, - __global REAL* y, - __global REAL4* scan_tmp, + __global real_t* a, + __global real_t* b, + __global real_t* c, + __global real_t* u, + __global real_t* v, + __global real_t* y, + __global real4_t* scan_tmp, /*** Temporary Array in Shared Space ***/ - __local REAL* cache_tmp + __local real_t* cache_tmp ) { // !!!0 <-> j; 1<-> i; 2 <-> k!!! @@ -215,11 +205,11 @@ __kernel void prepare_tridag_y ( // + get_global_id(1)*NUM_Y + get_global_id(0); const unsigned int glob_ind = get_local_id(2)*get_local_size(1)*get_local_size(0) + get_local_id(1)*get_local_size(0) + get_local_id(0); - REAL3 myDy_elem; - REAL dt_inv = ro_scals->dtInv; + real3_t myDy_elem; + real_t dt_inv = ro_scals->dtInv; - REAL cur_myMuY = 0.0; - REAL cur_myVarY = ro_scals->nu; cur_myVarY *= cur_myVarY*0.5f; //nu*nu; + real_t cur_myMuY = 0.0; + real_t cur_myVarY = ro_scals->nu; cur_myVarY *= cur_myVarY*0.5f; //nu*nu; myDy_elem = 0.5f*( cur_myMuY*myDy [get_global_id(0)] + cur_myVarY*myDyy[get_global_id(0)] ); @@ -242,16 +232,16 @@ __kernel void prepare_tridag_y ( // third loop if( get_global_id(0) > 0 ) { #ifdef USE_LOCAL_Y - scan_tmp[ind] = (REAL4) ( dt_inv - myDy_elem.y, myDy_elem.x * cache_tmp[glob_ind-1], 1.0, 0.0 ); + scan_tmp[ind] = (real4_t) ( dt_inv - myDy_elem.y, myDy_elem.x * cache_tmp[glob_ind-1], 1.0, 0.0 ); #else - const REAL elem = - 0.5f*(cur_myMuY*myDy[get_global_id(0)-1].z + cur_myVarY*myDyy[get_global_id(0)-1].z); - scan_tmp[ind] = (REAL4) ( dt_inv - myDy_elem.y, myDy_elem.x * elem, 1.0, 0.0 ); + const real_t elem = - 0.5f*(cur_myMuY*myDy[get_global_id(0)-1].z + cur_myVarY*myDyy[get_global_id(0)-1].z); + scan_tmp[ind] = (real4_t) ( dt_inv - myDy_elem.y, myDy_elem.x * elem, 1.0, 0.0 ); #endif - //scan_tmp[ind] = (REAL4) ( dt_inv - myDy_elem.y, myDy_elem.x*c[ind-1], 1.0, 0.0 ); + //scan_tmp[ind] = (real4_t) ( dt_inv - myDy_elem.y, myDy_elem.x*c[ind-1], 1.0, 0.0 ); } else { // j == get_global_id(0) == 0 y[ind] = dt_inv - myDy_elem.y; //b[ind]; - scan_tmp[ind] = (REAL4) ( dt_inv - myDy_elem.y, 0.0, 0.0, dt_inv - myDy_elem.y ); + scan_tmp[ind] = (real4_t) ( dt_inv - myDy_elem.y, 0.0, 0.0, dt_inv - myDy_elem.y ); } } @@ -268,10 +258,10 @@ __kernel void prepare_tridag_y ( * Multiplies 2x2 matrixes `a' and `b' and * stores the result in(-place in) `a'. */ -inline REAL4 matmult2(REAL4 a, REAL4 b) { - REAL val = (a.x*b.x + a.y*b.z); +inline real4_t matmult2(real4_t a, real4_t b) { + real_t val = (a.x*b.x + a.y*b.z); - a = (REAL4) (val, a.x*b.y + a.y*b.w, a.z*b.x + a.w*b.z, a.z*b.y + a.w*b.w); + a = (real4_t) (val, a.x*b.y + a.y*b.w, a.z*b.x + a.w*b.z, a.z*b.y + a.w*b.w); val = 1.0/val; return a * val; } @@ -282,27 +272,27 @@ inline REAL4 matmult2(REAL4 a, REAL4 b) { //#define WARP_SIZE (1U << LOG2_WARP_SIZE) #if WITH_INTERLEAVED_BANKS4 -inline REAL4 warpScanInclMatMult(REAL4 idata, volatile __local REAL4 *l_Data4, uint size){ - volatile __local REAL* l_Data = (volatile __local REAL*) l_Data4; +inline real4_t warpScanInclMatMult(real4_t idata, volatile __local real4_t *l_Data4, uint size){ + volatile __local real_t* l_Data = (volatile __local real_t*) l_Data4; uint pos = 2 * get_local_id(0) - (get_local_id(0) & (size - 1)); - store4( (REAL4)(1.0, 0.0, 0.0, 1.0), pos, l_Data ); + store4( (real4_t)(1.0, 0.0, 0.0, 1.0), pos, l_Data ); pos += size; store4( idata, pos, l_Data ); - if(size >= 2) { REAL4 tmp = matmult2( load4(pos, l_Data),load4(pos-1, l_Data) ); store4(tmp, pos, l_Data); } - if(size >= 4) { REAL4 tmp = matmult2( load4(pos, l_Data),load4(pos-2, l_Data) ); store4(tmp, pos, l_Data); } - if(size >= 8) { REAL4 tmp = matmult2( load4(pos, l_Data),load4(pos-4, l_Data) ); store4(tmp, pos, l_Data); } - if(size >= 16) { REAL4 tmp = matmult2( load4(pos, l_Data),load4(pos-8, l_Data) ); store4(tmp, pos, l_Data); } + if(size >= 2) { real4_t tmp = matmult2( load4(pos, l_Data),load4(pos-1, l_Data) ); store4(tmp, pos, l_Data); } + if(size >= 4) { real4_t tmp = matmult2( load4(pos, l_Data),load4(pos-2, l_Data) ); store4(tmp, pos, l_Data); } + if(size >= 8) { real4_t tmp = matmult2( load4(pos, l_Data),load4(pos-4, l_Data) ); store4(tmp, pos, l_Data); } + if(size >= 16) { real4_t tmp = matmult2( load4(pos, l_Data),load4(pos-8, l_Data) ); store4(tmp, pos, l_Data); } #if WARP == 32 - if(size >= 32) { REAL4 tmp = matmult2( load4(pos, l_Data),load4(pos-16,l_Data) ); store4(tmp, pos, l_Data); } + if(size >= 32) { real4_t tmp = matmult2( load4(pos, l_Data),load4(pos-16,l_Data) ); store4(tmp, pos, l_Data); } #endif return load4(pos, l_Data); } #else -inline REAL4 warpScanInclMatMult(REAL4 idata, volatile __local REAL4 *l_Data, uint size){ +inline real4_t warpScanInclMatMult(real4_t idata, volatile __local real4_t *l_Data, uint size){ uint pos = 2 * get_local_id(0) - (get_local_id(0) & (size - 1)); - l_Data[pos] = (REAL4)(1.0, 0.0, 0.0, 1.0); + l_Data[pos] = (real4_t)(1.0, 0.0, 0.0, 1.0); pos += size; l_Data[pos] = idata; @@ -319,17 +309,17 @@ inline REAL4 warpScanInclMatMult(REAL4 idata, volatile __local REAL4 *l_Data, ui //Vector scan: the array to be scanned is stored //in work-item private memory as uint4 -inline REAL4 scanMatMultInclLocal(REAL4 idata4, __local REAL4 *l_Data, uint size){ +inline real4_t scanMatMultInclLocal(real4_t idata4, __local real4_t *l_Data, uint size){ if(size > WARP){ //Bottom-level inclusive warp scan - REAL4 warpResult = warpScanInclMatMult(idata4, l_Data, WARP); + real4_t warpResult = warpScanInclMatMult(idata4, l_Data, WARP); //Save top elements of each warp for exclusive warp scan //sync to wait for warp scans to complete (because l_Data is being overwritten) barrier(CLK_LOCAL_MEM_FENCE); if( (get_local_id(0) & (WARP - 1)) == (WARP - 1) ) { #if WITH_INTERLEAVED_BANKS4 - store4(warpResult, get_local_id(0) >> lgWARP, (__local REAL*)l_Data); + store4(warpResult, get_local_id(0) >> lgWARP, (__local real_t*)l_Data); #else l_Data[get_local_id(0) >> lgWARP] = warpResult; #endif @@ -339,11 +329,11 @@ inline REAL4 scanMatMultInclLocal(REAL4 idata4, __local REAL4 *l_Data, uint size if( get_local_id(0) < (WORKGROUP_SIZE >> lgWARP) ){ #if WITH_INTERLEAVED_BANKS4 - REAL4 val = load4(get_local_id(0), (__local REAL*)l_Data); - store4( warpScanInclMatMult(val, l_Data, size >> lgWARP), get_local_id(0), (__local REAL*)l_Data); + real4_t val = load4(get_local_id(0), (__local real_t*)l_Data); + store4( warpScanInclMatMult(val, l_Data, size >> lgWARP), get_local_id(0), (__local real_t*)l_Data); #else //grab top warp elements - REAL4 val = l_Data[get_local_id(0)]; + real4_t val = l_Data[get_local_id(0)]; //calculate inclusive scan and write back to shared memory l_Data[get_local_id(0)] = warpScanInclMatMult(val, l_Data, size >> lgWARP); #endif @@ -355,7 +345,7 @@ inline REAL4 scanMatMultInclLocal(REAL4 idata4, __local REAL4 *l_Data, uint size //if( (get_local_id(0) >> LOG2_WARP_SIZE) > 0 ) if( ( (get_local_id(0) & (size-1)) >> lgWARP ) > 0 ) { #if WITH_INTERLEAVED_BANKS4 - REAL4 tmp = load4( (get_local_id(0) >> lgWARP) - 1, (__local REAL*)l_Data ); + real4_t tmp = load4( (get_local_id(0) >> lgWARP) - 1, (__local real_t*)l_Data ); warpResult = matmult2( warpResult, tmp ); #else warpResult = matmult2( warpResult, l_Data[ (get_local_id(0) >> lgWARP) - 1] ); @@ -370,15 +360,15 @@ inline REAL4 scanMatMultInclLocal(REAL4 idata4, __local REAL4 *l_Data, uint size __kernel __attribute__((reqd_work_group_size(WORKGROUP_SIZE, 1, 1))) void scanMatMultIncl( - __global REAL4 *data, - __local REAL4 *l_Data, + __global real4_t *data, + __local real4_t *l_Data, uint size ){ //Load data - REAL4 idata4 = data[get_global_id(0)]; + real4_t idata4 = data[get_global_id(0)]; //Calculate exclusive scan - REAL4 odata4 = scanMatMultInclLocal( idata4, l_Data, size ); + real4_t odata4 = scanMatMultInclLocal( idata4, l_Data, size ); //Write back data[get_global_id(0)] = odata4; @@ -390,34 +380,34 @@ void scanMatMultIncl( /*************************************************/ // Linear Function Composition and Scan -inline REAL2 linfuncomp(REAL2 ab2, REAL2 ab1) { +inline real2_t linfuncomp(real2_t ab2, real2_t ab1) { ab2.x = ab2.y * ab1.x + ab2.x; ab2.y = ab2.y * ab1.y; return ab2; } #if WITH_INTERLEAVED_BANKS2 -inline REAL2 warpScanInclLinFunComp(REAL2 idata, volatile __local REAL2 *l_Data2, uint size){ - volatile __local REAL* l_Data = (volatile __local REAL*) l_Data2; +inline real2_t warpScanInclLinFunComp(real2_t idata, volatile __local real2_t *l_Data2, uint size){ + volatile __local real_t* l_Data = (volatile __local real_t*) l_Data2; uint pos = 2 * get_local_id(0) - (get_local_id(0) & (size - 1)); - store2( (REAL2)(0.0, 1.0), pos, l_Data ); + store2( (real2_t)(0.0, 1.0), pos, l_Data ); pos += size; store2( idata, pos, l_Data ); - if(size >= 2) { REAL2 tmp = linfuncomp( load2(pos, l_Data),load2(pos-1, l_Data) ); store2(tmp, pos, l_Data); } - if(size >= 4) { REAL2 tmp = linfuncomp( load2(pos, l_Data),load2(pos-2, l_Data) ); store2(tmp, pos, l_Data); } - if(size >= 8) { REAL2 tmp = linfuncomp( load2(pos, l_Data),load2(pos-4, l_Data) ); store2(tmp, pos, l_Data); } - if(size >= 16) { REAL2 tmp = linfuncomp( load2(pos, l_Data),load2(pos-8, l_Data) ); store2(tmp, pos, l_Data); } + if(size >= 2) { real2_t tmp = linfuncomp( load2(pos, l_Data),load2(pos-1, l_Data) ); store2(tmp, pos, l_Data); } + if(size >= 4) { real2_t tmp = linfuncomp( load2(pos, l_Data),load2(pos-2, l_Data) ); store2(tmp, pos, l_Data); } + if(size >= 8) { real2_t tmp = linfuncomp( load2(pos, l_Data),load2(pos-4, l_Data) ); store2(tmp, pos, l_Data); } + if(size >= 16) { real2_t tmp = linfuncomp( load2(pos, l_Data),load2(pos-8, l_Data) ); store2(tmp, pos, l_Data); } #if WARP == 32 - if(size >= 32) { REAL2 tmp = linfuncomp( load2(pos, l_Data),load2(pos-16,l_Data) ); store2(tmp, pos, l_Data); } + if(size >= 32) { real2_t tmp = linfuncomp( load2(pos, l_Data),load2(pos-16,l_Data) ); store2(tmp, pos, l_Data); } #endif return load2(pos, l_Data); } #else -inline REAL2 warpScanInclLinFunComp(REAL2 idata, volatile __local REAL2 *l_Data, uint size){ +inline real2_t warpScanInclLinFunComp(real2_t idata, volatile __local real2_t *l_Data, uint size){ uint pos = 2 * get_local_id(0) - (get_local_id(0) & (size - 1)); - l_Data[pos] = (REAL2)(0.0, 1.0); + l_Data[pos] = (real2_t)(0.0, 1.0); pos += size; l_Data[pos] = idata; @@ -432,17 +422,17 @@ inline REAL2 warpScanInclLinFunComp(REAL2 idata, volatile __local REAL2 *l_Data, } #endif -inline REAL2 scanLinFunCompInclLocal(REAL2 idata4, __local REAL2 *l_Data, uint size){ +inline real2_t scanLinFunCompInclLocal(real2_t idata4, __local real2_t *l_Data, uint size){ if(size > WARP){ //Bottom-level inclusive warp scan - REAL2 warpResult = warpScanInclLinFunComp(idata4, l_Data, WARP); + real2_t warpResult = warpScanInclLinFunComp(idata4, l_Data, WARP); //Save top elements of each warp for exclusive warp scan //sync to wait for warp scans to complete (because l_Data is being overwritten) barrier(CLK_LOCAL_MEM_FENCE); if( (get_local_id(0) & (WARP - 1)) == (WARP - 1) ) { #if WITH_INTERLEAVED_BANKS2 - store2(warpResult, get_local_id(0) >> lgWARP, (__local REAL*)l_Data); + store2(warpResult, get_local_id(0) >> lgWARP, (__local real_t*)l_Data); #else l_Data[get_local_id(0) >> lgWARP] = warpResult; #endif @@ -453,11 +443,11 @@ inline REAL2 scanLinFunCompInclLocal(REAL2 idata4, __local REAL2 *l_Data, uint s if( get_local_id(0) < (WORKGROUP_SIZE / WARP) ){ #if WITH_INTERLEAVED_BANKS2 - REAL2 val = load2(get_local_id(0), (__local REAL*)l_Data); - store2( warpScanInclLinFunComp(val, l_Data, size >> lgWARP), get_local_id(0), (__local REAL*)l_Data); + real2_t val = load2(get_local_id(0), (__local real_t*)l_Data); + store2( warpScanInclLinFunComp(val, l_Data, size >> lgWARP), get_local_id(0), (__local real_t*)l_Data); #else //grab top warp elements - REAL2 val = l_Data[get_local_id(0)]; + real2_t val = l_Data[get_local_id(0)]; //calculate inclusive scan and write back to shared memory l_Data[get_local_id(0)] = warpScanInclLinFunComp(val, l_Data, size >> lgWARP); #endif @@ -468,7 +458,7 @@ inline REAL2 scanLinFunCompInclLocal(REAL2 idata4, __local REAL2 *l_Data, uint s if( ( (get_local_id(0) & (size-1)) >> lgWARP ) > 0 ) { #if WITH_INTERLEAVED_BANKS2 - REAL2 tmp = load2( (get_local_id(0) >> lgWARP) - 1, (__local REAL*)l_Data ); + real2_t tmp = load2( (get_local_id(0) >> lgWARP) - 1, (__local real_t*)l_Data ); warpResult = linfuncomp( warpResult, tmp ); #else warpResult = linfuncomp( warpResult, l_Data[ (get_local_id(0) >> lgWARP) - 1] ); @@ -483,15 +473,15 @@ inline REAL2 scanLinFunCompInclLocal(REAL2 idata4, __local REAL2 *l_Data, uint s __kernel __attribute__((reqd_work_group_size(WORKGROUP_SIZE, 1, 1))) void scanLinFunCompIncl( - __global REAL2 *data, - __local REAL2 *l_Data, + __global real2_t *data, + __local real2_t *l_Data, uint size ){ //Load data - REAL2 idata4 = data[get_global_id(0)]; + real2_t idata4 = data[get_global_id(0)]; //Calculate exclusive scan - REAL2 odata4 = scanLinFunCompInclLocal( idata4, l_Data, size ); + real2_t odata4 = scanLinFunCompInclLocal( idata4, l_Data, size ); //Write back data[get_global_id(0)] = odata4; @@ -502,29 +492,29 @@ void scanLinFunCompIncl( /*** 2. TRIDAG - in between scans ****/ /*************************************/ -inline REAL map_matmult(REAL4 tmp, REAL val1) { +inline real_t map_matmult(real4_t tmp, real_t val1) { - REAL nom = tmp.x*val1+tmp.y; - REAL denom = tmp.z*val1+tmp.w; + real_t nom = tmp.x*val1+tmp.y; + real_t denom = tmp.z*val1+tmp.w; return nom/denom; - //REAL denom = tmp.z*val1+tmp.w*val2; - //REAL nom = (tmp.x/denom)*val1 + (tmp.y/denom)*val2; + //real_t denom = tmp.z*val1+tmp.w*val2; + //real_t nom = (tmp.x/denom)*val1 + (tmp.y/denom)*val2; //return nom; } __kernel void conclude_matmult ( /*** Read-Write Temporary Arrays ***/ - __global REAL* b, - __global REAL* d, - __global REAL* y, - __global REAL* u, - __global REAL4* scan_tmp + __global real_t* b, + __global real_t* d, + __global real_t* y, + __global real_t* u, + __global real4_t* scan_tmp ) { unsigned int ind = get_global_id(2) * get_global_size(1) * get_global_size(0) + get_global_id(1) * get_global_size(0); - REAL b0 = u[ind]; //b[ ind ]; + real_t b0 = u[ind]; //b[ ind ]; ind += get_global_id(0); if(get_global_id(0) > 0) { @@ -537,18 +527,18 @@ __kernel void conclude_matmult ( __kernel void prelude_fwd_fun_comp ( /*** Read-Write Temporary Arrays ***/ - __global REAL* a, - __global REAL* d, - __global REAL* u, - __global REAL2* scan_tmp + __global real_t* a, + __global real_t* d, + __global real_t* u, + __global real2_t* scan_tmp ) { const unsigned int ind = get_global_id(2) * get_global_size(1) * get_global_size(0) + get_global_id(1) * get_global_size(0) + get_global_id(0); if( get_global_id(0) > 0 ) { - scan_tmp[ind] = (REAL2) ( d[ind], (0.0 - (a[ind]/u[ind-1])) ); + scan_tmp[ind] = (real2_t) ( d[ind], (0.0 - (a[ind]/u[ind-1])) ); } else { - scan_tmp[ind] = (REAL2) (0.0, 1.0); + scan_tmp[ind] = (real2_t) (0.0, 1.0); } } @@ -556,37 +546,37 @@ __kernel void prelude_fwd_fun_comp ( __kernel void post_fwd_fun_comp ( /*** Read-Write Temporary Arrays ***/ - __global REAL* y, - __global REAL2* scan_tmp + __global real_t* y, + __global real2_t* scan_tmp ) { unsigned int ind = get_global_id(2) * get_global_size(1) * get_global_size(0) + get_global_id(1) * get_global_size(0); - REAL y0 = y[ ind ]; + real_t y0 = y[ ind ]; ind += get_global_id(0); if( get_global_id(0) > 0 ) { - REAL2 fun = scan_tmp[ind]; + real2_t fun = scan_tmp[ind]; y[ind] = fun.x + y0 * fun.y; } } __kernel void prelude_bwd_fun_comp ( /*** Read-Write Temporary Arrays ***/ - __global REAL* c, - __global REAL* y, - __global REAL* u, - __global REAL2* scan_tmp + __global real_t* c, + __global real_t* y, + __global real_t* u, + __global real2_t* scan_tmp ) { const unsigned int ind = get_global_id(2) * get_global_size(1) * get_global_size(0) + get_global_id(1) * get_global_size(0) + get_global_id(0); const unsigned int inv_ind = ind - 2*get_global_id(0) + get_global_size(0) - 2; if( get_global_id(0) < get_global_size(0) - 1 ) { - scan_tmp[ind] = (REAL2)(y[inv_ind]/u[inv_ind], 0.0 - c[inv_ind]/u[inv_ind]); + scan_tmp[ind] = (real2_t)(y[inv_ind]/u[inv_ind], 0.0 - c[inv_ind]/u[inv_ind]); } else { // get_global_id(0) == get_global_size(0) - 1 - scan_tmp[ind] = (REAL2)(0.0, 1.0); + scan_tmp[ind] = (real2_t)(0.0, 1.0); y[ind] = y[ind]/u[ind]; } } @@ -597,8 +587,8 @@ __kernel void prelude_bwd_fun_comp ( * 2. update the RW scalars rw_scals->dtInv and rw_scals->timeline_i */ __kernel void post_bwd_fun_comp ( - __global REAL* y, - __global REAL2* scan_tmp + __global real_t* y, + __global real2_t* scan_tmp ) { // map back the result from the (bacward) parallel prefix // with linear function composition @@ -607,10 +597,10 @@ __kernel void post_bwd_fun_comp ( + get_global_id(1) * get_global_size(0) + get_global_id(0); const unsigned int inv_ind = ind - 2*get_global_id(0) + get_global_size(0) - 2; - REAL ynm1 = y[inv_ind + get_global_id(0) + 1]; + real_t ynm1 = y[inv_ind + get_global_id(0) + 1]; if( get_global_id(0) < get_global_size(0) - 1 ) { - REAL2 fun = scan_tmp[ind]; + real2_t fun = scan_tmp[ind]; y[inv_ind] = fun.x + ynm1 * fun.y; } } @@ -625,11 +615,11 @@ __kernel void post_bwd_fun_comp ( // to (BLOCK_DIM+1)*BLOCK_DIM. This pads each row of the 2D block in shared memory // so that bank conflicts do not occur when threads address the array column-wise. inline void transposeMatrix( - __global REAL *odata, - __global REAL *idata, + __global real_t *odata, + __global real_t *idata, unsigned int width, unsigned int height, - __local REAL* block) + __local real_t* block) { unsigned int xIndex, yIndex; @@ -661,25 +651,25 @@ inline void transposeMatrix( } __kernel void transpose( - __global REAL *odata, - __global REAL *idata, + __global real_t *odata, + __global real_t *idata, //int offset, unsigned int width, unsigned int height, - __local REAL* block) + __local real_t* block) { transposeMatrix( odata, idata, width, height, block ); } __kernel void transposeUpdateScalars( - __global REAL *odata, - __global REAL *idata, + __global real_t *odata, + __global real_t *idata, //int offset, unsigned int width, unsigned int height, - __local REAL* block, + __local real_t* block, __global RWScalars* ro_scals, // __constant - __constant REAL* timeline + __constant real_t* timeline ) { transposeMatrix( odata, idata, width, height, block ); //odata[get_global_id(2)*get_global_size(1)*get_global_size(0) + get_global_id(1)*get_global_size(0) + get_global_id(0)] @@ -700,49 +690,49 @@ __kernel void transposeUpdateScalars( inline void tridag_inline_local ( /*** Read-Write Temporary Arrays ***/ -// __global REAL* a, - REAL a_elem, -// __global REAL* c, - REAL c_elem, -// __global REAL* d, - REAL d_elem, - __global REAL* y, -// __global REAL4* scan_tmp4, - REAL4 data4, +// __global real_t* a, + real_t a_elem, +// __global real_t* c, + real_t c_elem, +// __global real_t* d, + real_t d_elem, + __global real_t* y, +// __global real4_t* scan_tmp4, + real4_t data4, const unsigned int SIZE, /*** Temporary Array in Shared Space ***/ - __local REAL* cache_tmp, // size: [8*WORKSIZE*sizeof(REAL)] + __local real_t* cache_tmp, // size: [8*WORKSIZE*sizeof(real_t)] const size_t first_id, - REAL b0, - REAL d0 + real_t b0, + real_t d0 ) { //const size_t first_id = get_global_id(0) - (get_global_id(0) & (SIZE-1)); - //REAL b0; + //real_t b0; { // SCAN with matrix multiplication - __local REAL4* l_data = (__local REAL4*)cache_tmp; + __local real4_t* l_data = (__local real4_t*)cache_tmp; //Calculate exclusive scan data4 = scanMatMultInclLocal( data4, l_data, SIZE ); barrier(CLK_LOCAL_MEM_FENCE); // IMPORTANT! - REAL data = map_matmult( data4, b0 ); + real_t data = map_matmult( data4, b0 ); cache_tmp[get_local_id(0)] = data; barrier(CLK_LOCAL_MEM_FENCE); } { // Forward scan with linear function composition - REAL2 data2; + real2_t data2; // prepare for scan if(get_global_id(0) == first_id) { //y[get_global_id(0)] = d0; //d[get_global_id(0)]; // y[ind] = d[ind]; - data2 = (REAL2) (0.0, 1.0); + data2 = (real2_t) (0.0, 1.0); } else { - data2 = (REAL2) ( d_elem, (0.0 - (a_elem/cache_tmp[get_local_id(0)-1])) ); + data2 = (real2_t) ( d_elem, (0.0 - (a_elem/cache_tmp[get_local_id(0)-1])) ); } {//Calculate exclusive scan - __local REAL2* l_Data = ((__local REAL2*)cache_tmp) + get_local_size(0); + __local real2_t* l_Data = ((__local real2_t*)cache_tmp) + get_local_size(0); data2 = scanLinFunCompInclLocal( data2, l_Data, SIZE ); } @@ -756,23 +746,23 @@ inline void tridag_inline_local ( { // Backward scan with linear function composition const unsigned int inv_ind = (SIZE-1) - (get_global_id(0) & (SIZE-1)); - REAL2 data2; + real2_t data2; unsigned int local_offset = get_local_id(0) - (get_local_id(0) & (SIZE-1)); b0 = cache_tmp[local_offset + get_local_size(0) + (SIZE-1)]/cache_tmp[local_offset + (SIZE-1)]; // prepare for scan! if(get_global_id(0) == first_id) { - data2 = (REAL2) (0.0, 1.0); + data2 = (real2_t) (0.0, 1.0); } else { - REAL myu = cache_tmp[local_offset + inv_ind]; - data2 = (REAL2) ( cache_tmp[local_offset + inv_ind + get_local_size(0)] / myu, + real_t myu = cache_tmp[local_offset + inv_ind]; + data2 = (real2_t) ( cache_tmp[local_offset + inv_ind + get_local_size(0)] / myu, 0.0 - c_elem / myu ); //0.0 - c[first_id + inv_ind]/myu ); } {// BACKWARD SCAN with linear function compsition - __local REAL2* l_Data = ((__local REAL2*)cache_tmp) + get_local_size(0); + __local real2_t* l_Data = ((__local real2_t*)cache_tmp) + get_local_size(0); data2 = scanLinFunCompInclLocal( data2, l_Data, SIZE ); } @@ -785,15 +775,15 @@ inline void tridag_inline_local ( __kernel __attribute__((reqd_work_group_size(WORKGROUP_SIZE, 1, 1))) void tridag_inlined ( /*** Read-Write Temporary Arrays ***/ - __global REAL* a, - __global REAL* c, - __global REAL* d, - __global REAL* y, - __global REAL* u, - __global REAL4* scan_tmp4, + __global real_t* a, + __global real_t* c, + __global real_t* d, + __global real_t* y, + __global real_t* u, + __global real4_t* scan_tmp4, const unsigned int SIZE, /*** Temporary Array in Shared Space ***/ - __local REAL* cache_tmp // size: [8*WORKSIZE*sizeof(REAL)] + __local real_t* cache_tmp // size: [8*WORKSIZE*sizeof(real_t)] ) { const size_t first_id = get_global_id(0) - (get_global_id(0) & (SIZE-1)); //const unsigned int inv_ind = (SIZE-1) - (get_global_id(0) & (SIZE-1)); @@ -824,41 +814,41 @@ void nordea_kernel_x ( /*** Read-Only Scalars ***/ __constant RWScalars* ro_scals, // __constant /*** Read-Only Arrays ***/ - __global REAL* myX, - __global REAL3* myDx, - __global REAL3* myDxx, - __constant REAL* myY, - __constant REAL* myDy, - __constant REAL* myDyy, + __global real_t* myX, + __global real3_t* myDx, + __global real3_t* myDxx, + __constant real_t* myY, + __constant real_t* myDy, + __constant real_t* myDyy, /*** Read-Write Temporary Arrays ***/ - __global REAL* u, - __global REAL* v, + __global real_t* u, + __global real_t* v, /*** Temporary Array in Shared Space ***/ - __local REAL* cache_tmp, + __local real_t* cache_tmp, /*** The Result Array ***/ - __global REAL* res_arr + __global real_t* res_arr ) { - REAL3 myD_elem; + real3_t myD_elem; unsigned int ind_x = get_global_id(0) & (ro_scals->NUM_X-1); unsigned int ind_y = (get_global_id(0) & (ro_scals->NUM_XY-1)) / ro_scals->NUM_X; - REAL tmp = 0.0; + real_t tmp = 0.0; { // I. second loop - REAL3 myres_elem; - REAL cur_myMu = 0.0; - REAL cur_myVar = ro_scals->nu; + real3_t myres_elem; + real_t cur_myMu = 0.0; + real_t cur_myVar = ro_scals->nu; cur_myVar *= cur_myVar; - myres_elem = (REAL3)( myDyy[ind_y<<2], myDyy[(ind_y<<2)+1], myDyy[(ind_y<<2)+2] ); - myD_elem = (REAL3)( myDy [ind_y<<2], myDy [(ind_y<<2)+1], myDy [(ind_y<<2)+2] ); + myres_elem = (real3_t)( myDyy[ind_y<<2], myDyy[(ind_y<<2)+1], myDyy[(ind_y<<2)+2] ); + myD_elem = (real3_t)( myDy [ind_y<<2], myDy [(ind_y<<2)+1], myDy [(ind_y<<2)+2] ); myD_elem = cur_myMu*myD_elem + 0.5f*cur_myVar*myres_elem; - myres_elem = (REAL3)( (ind_y != 0) ? res_arr[get_global_id(0) - ro_scals->NUM_X] : 0.0, + myres_elem = (real3_t)( (ind_y != 0) ? res_arr[get_global_id(0) - ro_scals->NUM_X] : 0.0, res_arr[get_global_id(0)], (ind_y != ro_scals->NUM_Y-1) ? res_arr[get_global_id(0) + ro_scals->NUM_X] : 0.0 ); @@ -886,7 +876,7 @@ void nordea_kernel_x ( barrier(CLK_LOCAL_MEM_FENCE); - myres_elem = (REAL3)( (ind_x!=0) ? cache_tmp[ get_local_id(0) - 1 ] : 0.0, + myres_elem = (real3_t)( (ind_x!=0) ? cache_tmp[ get_local_id(0) - 1 ] : 0.0, cache_tmp[ get_local_id(0) ], (ind_x != ro_scals->NUM_X-1) ? cache_tmp[ get_local_id(0) + 1 ] : 0.0 ); @@ -909,7 +899,7 @@ void nordea_kernel_x ( { // prepare for and call TRIDAG - REAL4 scan_elem; + real4_t scan_elem; //u[get_global_id(0)] = tmp; //u[j*NUM_X + i] = tmp1 + tmp2; //u[j][i] = tmp1 + tmp2; myD_elem.z = tmp; @@ -921,10 +911,10 @@ void nordea_kernel_x ( // third loop if( ind_x > 0 ) { myD_elem.y = cache_tmp[get_local_size(0) + get_local_id(0) - 1]; // i.e., c[glob_ind-1] - scan_elem = (REAL4) ( tmp, 0.0 - myD_elem.x * myD_elem.y, 1.0, 0.0 ); + scan_elem = (real4_t) ( tmp, 0.0 - myD_elem.x * myD_elem.y, 1.0, 0.0 ); myD_elem.y = cache_tmp[get_local_size(0) + get_local_id(0) + (ro_scals->NUM_X-1) - 2*ind_x]; // i.e., c[glb_ind_inv] } else { // i == get_global_id(0) == 0 - scan_elem = (REAL4) ( tmp, 0.0, 0.0, tmp ); //(REAL4) ( 1.0, 0.0, 0.0, 1.0 ); + scan_elem = (real4_t) ( tmp, 0.0, 0.0, tmp ); //(real4_t) ( 1.0, 0.0, 0.0, 1.0 ); myD_elem.y = cache_tmp[get_local_size(0) + get_local_id(0) + (ro_scals->NUM_X-1) ]; cache_tmp[get_local_id(0) ] = tmp; @@ -934,7 +924,7 @@ void nordea_kernel_x ( barrier(CLK_LOCAL_MEM_FENCE); tmp = cache_tmp[get_local_id(0) - ind_x ]; - REAL d0 = cache_tmp[get_local_id(0) - ind_x + 1]; + real_t d0 = cache_tmp[get_local_id(0) - ind_x + 1]; barrier(CLK_LOCAL_MEM_FENCE); @@ -963,31 +953,31 @@ void nordea_kernel_y ( /*** Read-Only Scalars ***/ __constant RWScalars* ro_scals, // __constant /*** Read-Only Arrays ***/ - __global REAL3* myDy, - __global REAL3* myDyy, + __global real3_t* myDy, + __global real3_t* myDyy, /*** Read-Write Temporary Arrays ***/ - __global REAL* u, - __global REAL* v, + __global real_t* u, + __global real_t* v, /*** Temporary Array in Shared Space ***/ - __local REAL* cache_tmp // SIZE: 8 * WORKGROUP_SIZE * sizeof(REAL) + __local real_t* cache_tmp // SIZE: 8 * WORKGROUP_SIZE * sizeof(real_t) ) { - REAL3 myDy_elem; + real3_t myDy_elem; unsigned int ind_y = get_global_id(0) & (ro_scals->NUM_Y-1); unsigned int ind_x = (get_global_id(0) & (ro_scals->NUM_XY-1)) / ro_scals->NUM_Y; { - REAL dt_inv = ro_scals->dtInv; + real_t dt_inv = ro_scals->dtInv; #if TRANSPOSE_UV - REAL my_u = u[get_global_id(0)]; + real_t my_u = u[get_global_id(0)]; #else - REAL my_u = u[ (get_global_id(0)/ro_scals->NUM_XY)*ro_scals->NUM_XY + + real_t my_u = u[ (get_global_id(0)/ro_scals->NUM_XY)*ro_scals->NUM_XY + ind_y * ro_scals->NUM_X + ind_x ]; #endif - REAL tmp = 0.0; - REAL cur_myVarY = ro_scals->nu; cur_myVarY *= cur_myVarY*0.5f; //nu*nu; + real_t tmp = 0.0; + real_t cur_myVarY = ro_scals->nu; cur_myVarY *= cur_myVarY*0.5f; //nu*nu; myDy_elem = 0.0f - 0.5f*( tmp*myDy[ind_y] + cur_myVarY*myDyy[ind_y] ); @@ -1009,14 +999,14 @@ void nordea_kernel_y ( barrier(CLK_LOCAL_MEM_FENCE); { - REAL4 scan_elem; - REAL b0, d0; + real4_t scan_elem; + real_t b0, d0; // third loop if( ind_y > 0 ) { - scan_elem = (REAL4) ( myDy_elem.y, 0.0 - myDy_elem.x * cache_tmp[get_local_size(0)+get_local_id(0)-1], 1.0, 0.0 ); + scan_elem = (real4_t) ( myDy_elem.y, 0.0 - myDy_elem.x * cache_tmp[get_local_size(0)+get_local_id(0)-1], 1.0, 0.0 ); } else { - scan_elem = (REAL4) ( 1.0, 0.0, 0.0, 1.0 ); + scan_elem = (real4_t) ( 1.0, 0.0, 0.0, 1.0 ); } myDy_elem.y = cache_tmp[get_local_size(0) + get_local_id(0) + (ro_scals->NUM_Y-1) - 2*ind_y]; // i.e., c[ind_inv] diff --git a/benchmarks/LocVolCalib/implementations/cpp_openclmp_all/Makefile b/benchmarks/LocVolCalib/implementations/cpp_openclmp_all/Makefile new file mode 100644 index 0000000..cd0ad0e --- /dev/null +++ b/benchmarks/LocVolCalib/implementations/cpp_openclmp_all/Makefile @@ -0,0 +1,44 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +# Default to double if nothing else defined. +HIPERMARK_CONFIG_REAL_TYPE ?= double + +include $(HIPERMARK_LIB_DIR)/setup.mk +include $(HIPERMARK_LIB_DIR)/setup_real_type.mk + +# FIXME - this should not even exist! +include $(HIPERMARK_LIB_DIR)/platform.mk + +INCLUDES += -I$(HIPERMARK_BENCHMARK_LIB_DIR)/include +INCLUDES += -I$(HIPERMARK_LIB_DIR)/include + +GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -D GPU_DEV_ID=$(GPU_DEVICE_ID) \ + -D GPU_LOC_MEM=$(GPU_LOCAL_MEM) -D GPU_CONST_MEM=$(GPU_CONST_MEM) \ + -D GPU_REG_MEM=$(GPU_REG_MEM) -D GPU_GLB_MEM=$(GPU_DEVICE_MEM) \ + -D GPU_TILE=$(GPU_LOCAL_MEM_PER_TH) -D GPU_CORES=$(GPU_NUM_CORES) \ + -D CURR_DIR_PATH='"$(MAKE_DIR)"' + +SOURCES_CPP =$(HIPERMARK_IMPLEMENTATION_DIR)/VolCalibAll.cpp +HELPERS =PrepareKernels.h Vect_CPU.h Vect_GPU.h VolCalibInit.h \ + $(HIPERMARK_BENCHMARK_LIB_DIR)/Constants.h \ + $(HIPERMARK_BENCHMARK_LIB_DIR)/ParseInput.h \ + $(HIPERMARK_BENCHMARK_LIB_DIR)/DataStructConst.h \ + $(HIPERMARK_BENCHMARK_LIB_DIR)/ParPrefixUtil.h +EXECUTABLE =VolCalibAll + +$(EXECUTABLE): + cp $(HIPERMARK_IMPLEMENTATION_DIR)/*cl . + $(CXX) $(CXXFLAGS) -D IS_GPU=1 $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(SOURCES_CPP) $(LIB) + + +clean: + rm -f $(EXECUTABLE) $(OBJECTS) ./*.ptx ./Debug.txt + @# clean nVidia compiler cache + rm -rf $(HOME)/.nv/ComputeCache/* + +HIPERMARK_DATA_FIELDS=outer num_x num_y num_t +ifdef HIPERMARK_CONFIG_NUM_THREADS + HIPERMARK_RUN_ENVIRONMENT=OMP_NUM_THREADS=$(HIPERMARK_CONFIG_NUM_THREADS) +endif +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/LocVolCalib/AllParOpenCLMP/PrepareKernels.h b/benchmarks/LocVolCalib/implementations/cpp_openclmp_all/PrepareKernels.h similarity index 95% rename from LocVolCalib/AllParOpenCLMP/PrepareKernels.h rename to benchmarks/LocVolCalib/implementations/cpp_openclmp_all/PrepareKernels.h index d76d963..04a5a4f 100644 --- a/LocVolCalib/AllParOpenCLMP/PrepareKernels.h +++ b/benchmarks/LocVolCalib/implementations/cpp_openclmp_all/PrepareKernels.h @@ -37,29 +37,29 @@ struct oclNordeaArrays { // CPU BUFFERS struct NordeaArrays { /* RO arrays */ - REAL* timeline; // [NUM_T] + real_t* timeline; // [NUM_T] - REAL* myX; // [NUM_X] - REAL* myDx; // [NUM_X * 3] - REAL* myDxx; // [NUM_X * 3] + real_t* myX; // [NUM_X] + real_t* myDx; // [NUM_X * 3] + real_t* myDxx; // [NUM_X * 3] - REAL* myY; // [NUM_Y] - REAL* myDy; // [NUM_Y * 3] - REAL* myDyy; // [NUM_Y * 3] + real_t* myY; // [NUM_Y] + real_t* myDy; // [NUM_Y * 3] + real_t* myDyy; // [NUM_Y * 3] /* TRIDAG helpers are created on GPU only! no need for them to exist in main memory*/ - REAL* a; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* b; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* c; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* y; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* u; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* v; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* tmp; // [4 * OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* a; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* b; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* c; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* y; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* u; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* v; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* tmp; // [4 * OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* res_arr; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* res_arr; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] /* NOT USED FOR NOW! WRITE ONLY OUTPUT stored in "res"*/ - //REAL* res; + //real_t* res; }; // GPU KERNELS @@ -189,7 +189,7 @@ cl_kernel make_prepare_tridag_X( #if 1 { // 4. LOCAL (PRIVATE ARRAYS) - const int PRIV_MULT = sizeof(REAL) * localWorkSize[0] * localWorkSize[1] * localWorkSize[2]; + const int PRIV_MULT = sizeof(real_t) * localWorkSize[0] * localWorkSize[1] * localWorkSize[2]; ciErr1 |= clSetKernelArg(ckPreTridagX, counter++, PRIV_MULT, NULL); } #endif @@ -259,7 +259,7 @@ cl_kernel make_NordeaKernelX( ciErr1 |= clSetKernelArg(ckAllX, counter++, sizeof(cl_mem), (void*)&ocl_arrs.v); // 4. LOCAL (PRIVATE ARRAYS) - const int PRIV_MULT = sizeof(REAL) * 8 * WORKGROUP_SIZE; + const int PRIV_MULT = sizeof(real_t) * 8 * WORKGROUP_SIZE; ciErr1 |= clSetKernelArg(ckAllX, counter++, PRIV_MULT, NULL); // 5. OUT ARRAY! @@ -329,7 +329,7 @@ cl_kernel make_prepare_tridag_Y( } #if 1 { // 4. LOCAL (PRIVATE ARRAYS) - const int PRIV_MULT = sizeof(REAL) * localWorkSize[0] * localWorkSize[1] * localWorkSize[2]; + const int PRIV_MULT = sizeof(real_t) * localWorkSize[0] * localWorkSize[1] * localWorkSize[2]; ciErr1 |= clSetKernelArg(ckPreTridagY, counter++, PRIV_MULT, NULL); } #endif @@ -397,7 +397,7 @@ cl_kernel make_NordeaKernelY( #endif // 4. LOCAL (PRIVATE ARRAYS) - const int PRIV_MULT = sizeof(REAL) * 8 * WORKGROUP_SIZE; + const int PRIV_MULT = sizeof(real_t) * 8 * WORKGROUP_SIZE; ciErr1 |= clSetKernelArg(ckAllY, counter++, PRIV_MULT, NULL); oclCheckError(ciErr1, CL_SUCCESS); @@ -453,8 +453,8 @@ cl_kernel make_MatMultScan( ciErr1 |= clSetKernelArg(ckTridagMatMultX, counter++, sizeof(cl_mem), (void*)&ocl_arrs.tmp4); } - { // 2. LOCAL: 8 * sizeof(REAL) * worksize - const int PRIV_MULT = sizeof(REAL) * 8 * localWorkSize; + { // 2. LOCAL: 8 * sizeof(real_t) * worksize + const int PRIV_MULT = sizeof(real_t) * 8 * localWorkSize; ciErr1 |= clSetKernelArg(ckTridagMatMultX, counter++, PRIV_MULT, NULL); } @@ -519,8 +519,8 @@ cl_kernel make_FwdFunCompScan( // 1. GPU-ONLY GLOBAL ARRAYS /(4 * NUM_X * NUM_Y * OUTER_LOOP_COUNT) ciErr1 |= clSetKernelArg(ckTridagFwdFunComp, counter++, sizeof(cl_mem), (void*)&ocl_arrs.tmp2); - // 2. LOCAL: 4 * sizeof(REAL) * worksize - const int PRIV_MULT = sizeof(REAL) * 4 * localWorkSize; + // 2. LOCAL: 4 * sizeof(real_t) * worksize + const int PRIV_MULT = sizeof(real_t) * 4 * localWorkSize; ciErr1 |= clSetKernelArg(ckTridagFwdFunComp, counter++, PRIV_MULT, NULL); // 1. GPU-ONLY GLOBAL ARRAYS // @@ -884,7 +884,7 @@ cl_kernel make_TRIDAG_ALL_OPT ( ciErr1 |= clSetKernelArg(ckTridagAll, counter++, sizeof(uint) , (void *)NUM_P ); { - const int PRIV_MULT = sizeof(REAL) * 8 * WORKGROUP_SIZE; + const int PRIV_MULT = sizeof(real_t) * 8 * WORKGROUP_SIZE; ciErr1 |= clSetKernelArg(ckTridagAll, counter++, PRIV_MULT, NULL); } @@ -950,7 +950,7 @@ cl_kernel make_transposeGPU( ciErr1 |= clSetKernelArg(ckMatTransp, counter++, sizeof(int), size_y); // size of 1 dim // shared memory space - ciErr1 |= clSetKernelArg(ckMatTransp, counter++, (BLOCK_DIM + 1) * BLOCK_DIM * sizeof(REAL), 0 ); + ciErr1 |= clSetKernelArg(ckMatTransp, counter++, (BLOCK_DIM + 1) * BLOCK_DIM * sizeof(real_t), 0 ); #if 0 // enqueue kernel @@ -1333,10 +1333,10 @@ void testMatMultScan ( //const unsigned NUM_X = 64, NUM_Y = 1; cl_mem cl_tmp; cl_int ciErr; - REAL* tmp = new REAL[NUM_X*NUM_Y*4]; + real_t* tmp = new real_t[NUM_X*NUM_Y*4]; for(int i=0; i4) for( k=0; k(s0/dx); for( i=0; iNUM_Y; //(ro_scals->NUM_Y << LOG2_WARP_SIZE); - REAL cur_myVar, cur_myMu, exp_add; - REAL4 myDy_el; + real_t cur_myVar, cur_myMu, exp_add; + real4_t myDy_el; { // cur_myVarY = nu*nu; cur_myMuY = 0.0; compute ind_y and exp_add cur_myVar = ro_scals->nu; cur_myVar *= cur_myVar; @@ -102,9 +89,9 @@ __kernel void nordea_kernel_x ( i = get_global_id(0) & (ro_scals->NUM_Y - 1); myDy_el = cur_myMu*myDy[i] + (0.5f*cur_myVar)*myDyy[i]; //i = REAL3_CT*(get_global_id(0) & (ro_scals->NUM_Y - 1)); - //myDy_el = (REAL4)(myDyy[i], myDyy[i+1], myDyy[i+2], 1.0); + //myDy_el = (real4_t)(myDyy[i], myDyy[i+1], myDyy[i+2], 1.0); //myDy_el = myDy_el * (0.5*cur_myVar); - //myDy_el += cur_myMu*((REAL4)(myDy[i], myDy[i+1], myDy[i+2], 1.0)); + //myDy_el += cur_myMu*((real4_t)(myDy[i], myDy[i+1], myDy[i+2], 1.0)); } @@ -161,19 +148,19 @@ __kernel void nordea_kernel_y ( /*** Read-Only Scalars ***/ __constant RWScalars* ro_scals, // __constant /*** Read-Only Arrays ***/ - __constant REAL* myDy, - __constant REAL* myDyy, + __constant real_t* myDy, + __constant real_t* myDyy, /*** Read-Write Temporary Arrays ***/ - __global REAL* a, - __global REAL* b, - __global REAL* c, - __global REAL* u, - __global REAL* v, - __global REAL* y + __global real_t* a, + __global real_t* b, + __global real_t* c, + __global real_t* u, + __global real_t* v, + __global real_t* y ) { //const unsigned int step_rev = ro_scals->NUM_X; //(ro_scals->NUM_X << LOG2_WARP_SIZE); unsigned int ind, ind_rev, i; - REAL cur_myVar, cur_myMu; + real_t cur_myVar, cur_myMu; { // cur_myVarY = nu*nu; cur_myMuY = 0.0; compute ind_y and exp_add cur_myVar = ro_scals->nu; cur_myVar *= cur_myVar; @@ -217,11 +204,11 @@ __kernel void nordea_kernel_y ( // to (BLOCK_DIM+1)*BLOCK_DIM. This pads each row of the 2D block in shared memory // so that bank conflicts do not occur when threads address the array column-wise. inline void transposeMatrix( - __global REAL *odata, - __global REAL *idata, + __global real_t *odata, + __global real_t *idata, unsigned int width, unsigned int height, - __local REAL* block) + __local real_t* block) { unsigned int xIndex, yIndex; @@ -253,25 +240,25 @@ inline void transposeMatrix( } __kernel void transpose( - __global REAL *odata, - __global REAL *idata, + __global real_t *odata, + __global real_t *idata, //int offset, unsigned int width, unsigned int height, - __local REAL* block) + __local real_t* block) { transposeMatrix( odata, idata, width, height, block ); } __kernel void transposeUpdateScalars( - __global REAL *odata, - __global REAL *idata, + __global real_t *odata, + __global real_t *idata, //int offset, unsigned int width, unsigned int height, - __local REAL* block, + __local real_t* block, __global RWScalars* ro_scals, // __constant - __constant REAL* timeline + __constant real_t* timeline ) { transposeMatrix( odata, idata, width, height, block ); diff --git a/benchmarks/LocVolCalib/implementations/cpp_openclmp_outer/Makefile b/benchmarks/LocVolCalib/implementations/cpp_openclmp_outer/Makefile new file mode 100644 index 0000000..65c467d --- /dev/null +++ b/benchmarks/LocVolCalib/implementations/cpp_openclmp_outer/Makefile @@ -0,0 +1,44 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +# Default to double if nothing else defined. +HIPERMARK_CONFIG_REAL_TYPE ?= double + +include $(HIPERMARK_LIB_DIR)/setup.mk +include $(HIPERMARK_LIB_DIR)/setup_real_type.mk + +# FIXME - this should not even exist! +include $(HIPERMARK_LIB_DIR)/platform.mk + +INCLUDES += -I$(HIPERMARK_BENCHMARK_LIB_DIR)/include +INCLUDES += -I$(HIPERMARK_LIB_DIR)/include + +GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -D GPU_DEV_ID=$(GPU_DEVICE_ID) \ + -D GPU_LOC_MEM=$(GPU_LOCAL_MEM) -D GPU_CONST_MEM=$(GPU_CONST_MEM) \ + -D GPU_REG_MEM=$(GPU_REG_MEM) -D GPU_GLB_MEM=$(GPU_DEVICE_MEM) \ + -D GPU_TILE=$(GPU_LOCAL_MEM_PER_TH) -D GPU_CORES=$(GPU_NUM_CORES) \ + -D CURR_DIR_PATH='"$(MAKE_DIR)"' + +SOURCES_CPP =$(HIPERMARK_IMPLEMENTATION_DIR)/VolCalibOuter.cpp +HELPERS =PrepareKernels.h Vect_CPU.h Vect_GPU.h VolCalibInit.h \ + $(HIPERMARK_BENCHMARK_LIB_DIR)/Constants.h \ + $(HIPERMARK_BENCHMARK_LIB_DIR)/ParseInput.h \ + $(HIPERMARK_BENCHMARK_LIB_DIR)/DataStructConst.h \ + $(HIPERMARK_BENCHMARK_LIB_DIR)/ParPrefixUtil.h +EXECUTABLE =VolCalibOuter + +$(EXECUTABLE): + cp $(HIPERMARK_IMPLEMENTATION_DIR)/*cl . + $(CXX) $(CXXFLAGS) -D IS_GPU=1 $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(SOURCES_CPP) $(LIB) + + +clean: + rm -f $(EXECUTABLE) $(OBJECTS) ./*.ptx ./Debug.txt + @# clean nVidia compiler cache + rm -rf $(HOME)/.nv/ComputeCache/* + +HIPERMARK_DATA_FIELDS=outer num_x num_y num_t +ifdef HIPERMARK_CONFIG_NUM_THREADS + HIPERMARK_RUN_ENVIRONMENT=OMP_NUM_THREADS=$(HIPERMARK_CONFIG_NUM_THREADS) +endif +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/LocVolCalib/OutParOpenCLMP/PrepareKernels.h b/benchmarks/LocVolCalib/implementations/cpp_openclmp_outer/PrepareKernels.h similarity index 94% rename from LocVolCalib/OutParOpenCLMP/PrepareKernels.h rename to benchmarks/LocVolCalib/implementations/cpp_openclmp_outer/PrepareKernels.h index 13a39bd..65d9745 100644 --- a/LocVolCalib/OutParOpenCLMP/PrepareKernels.h +++ b/benchmarks/LocVolCalib/implementations/cpp_openclmp_outer/PrepareKernels.h @@ -40,29 +40,29 @@ struct oclNordeaArrays { // CPU BUFFERS struct NordeaArrays { /* RO arrays */ - REAL* timeline; // [NUM_T] + real_t* timeline; // [NUM_T] - REAL* myX; // [NUM_X] - REAL* myDx; // [NUM_X * 3] - REAL* myDxx; // [NUM_X * 3] + real_t* myX; // [NUM_X] + real_t* myDx; // [NUM_X * 3] + real_t* myDxx; // [NUM_X * 3] - REAL* myY; // [NUM_Y] - REAL* myDy; // [NUM_Y * 3] - REAL* myDyy; // [NUM_Y * 3] + real_t* myY; // [NUM_Y] + real_t* myDy; // [NUM_Y * 3] + real_t* myDyy; // [NUM_Y * 3] /* TRIDAG helpers are created on GPU only! no need for them to exist in main memory*/ - REAL* a; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* b; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* c; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* y; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* u; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* v; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* tmp; // [4 * OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* a; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* b; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* c; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* y; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* u; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* v; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* tmp; // [4 * OUTER_LOOP_COUNT * NUM_X * NUM_Y] - REAL* res_arr; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] + real_t* res_arr; // [OUTER_LOOP_COUNT * NUM_X * NUM_Y] /* NOT USED FOR NOW! WRITE ONLY OUTPUT stored in "res"*/ - //REAL* res; + //real_t* res; }; // GPU KERNELS @@ -267,7 +267,7 @@ cl_kernel make_transposeGPU( ciErr1 |= clSetKernelArg(ckMatTransp, counter++, sizeof(int), size_y); // size of 1 dim // shared memory space - ciErr1 |= clSetKernelArg(ckMatTransp, counter++, (BLOCK_DIM + 1) * BLOCK_DIM * sizeof(REAL), 0 ); + ciErr1 |= clSetKernelArg(ckMatTransp, counter++, (BLOCK_DIM + 1) * BLOCK_DIM * sizeof(real_t), 0 ); oclCheckError(ciErr1, CL_SUCCESS); @@ -463,9 +463,9 @@ void run_trimmed_GPUkernels_one_time_iteration ( NordeaArrays& cpu_arrs, oclNordeaArrays& ocl_arrs, int time_ind, - const REAL alpha, - const REAL beta, - const REAL nu + const real_t alpha, + const real_t beta, + const real_t nu ) { run_NordeaKernelX( cqCommandQueue, kernels ); run_transposeGPU ( cqCommandQueue, kernels.ckMatTransposeU, kernels.FORM_32X ); // y <- transpose(u) @@ -474,7 +474,7 @@ void run_trimmed_GPUkernels_one_time_iteration ( run_transposeGPU_WithUpdate( cqCommandQueue, kernels.ckMatTranspUpdate, kernels.FORM_32Y); cl_int ciErr; - const unsigned int ARR_SIZE = NUM_X * NUM_Y * OUTER_LOOP_COUNT * sizeof(REAL); + const unsigned int ARR_SIZE = NUM_X * NUM_Y * OUTER_LOOP_COUNT * sizeof(real_t); #if 1 ciErr = clEnqueueReadBuffer( cqCommandQueue, ocl_arrs.a, CL_TRUE, 0, ARR_SIZE, cpu_arrs.a, 0, NULL, NULL ); ciErr = clEnqueueReadBuffer( cqCommandQueue, ocl_arrs.b, CL_TRUE, 0, ARR_SIZE, cpu_arrs.b, 0, NULL, NULL ); @@ -490,9 +490,9 @@ void run_trimmed_GPUkernels_one_time_iteration ( // now the rest of the code! unsigned int i, j, k; - REAL dtInv = 1.0/(cpu_arrs.timeline[time_ind+1]-cpu_arrs.timeline[time_ind]); + real_t dtInv = 1.0/(cpu_arrs.timeline[time_ind+1]-cpu_arrs.timeline[time_ind]); - REAL *res_arr = cpu_arrs.res_arr, *a = cpu_arrs.a, + real_t *res_arr = cpu_arrs.res_arr, *a = cpu_arrs.a, *b = cpu_arrs.b, *c = cpu_arrs.c, *u = cpu_arrs.u, *v = cpu_arrs.v, *y = cpu_arrs.y; diff --git a/LocVolCalib/OutParOpenCLMP/Vect_CPU.h b/benchmarks/LocVolCalib/implementations/cpp_openclmp_outer/Vect_CPU.h similarity index 82% rename from LocVolCalib/OutParOpenCLMP/Vect_CPU.h rename to benchmarks/LocVolCalib/implementations/cpp_openclmp_outer/Vect_CPU.h index 26d522c..78411a2 100644 --- a/LocVolCalib/OutParOpenCLMP/Vect_CPU.h +++ b/benchmarks/LocVolCalib/implementations/cpp_openclmp_outer/Vect_CPU.h @@ -1,7 +1,7 @@ #ifndef NORDEA_CPU #define NORDEA_CPU -#include "../includeC/ParPrefixUtil.h" +#include "ParPrefixUtil.h" //////////////////////////////////////////////////////////// //// FINALLY THE MEAT: The CPU Version of the Main Loop! @@ -9,24 +9,24 @@ void iteration_expanded_CPU ( const unsigned int time_ind, - const REAL alpha, - const REAL beta, - const REAL nu, - REAL* a, // [OUTER_LOOP_COUNT*NUM_XY] - REAL* b, // [OUTER_LOOP_COUNT*NUM_XY] - REAL* c, // [OUTER_LOOP_COUNT*NUM_XY] - REAL* y, // [OUTER_LOOP_COUNT*NUM_XY] - REAL* u, // [OUTER_LOOP_COUNT*NUM_XY] - REAL* v // [OUTER_LOOP_COUNT*NUM_XY] + const real_t alpha, + const real_t beta, + const real_t nu, + real_t* a, // [OUTER_LOOP_COUNT*NUM_XY] + real_t* b, // [OUTER_LOOP_COUNT*NUM_XY] + real_t* c, // [OUTER_LOOP_COUNT*NUM_XY] + real_t* y, // [OUTER_LOOP_COUNT*NUM_XY] + real_t* u, // [OUTER_LOOP_COUNT*NUM_XY] + real_t* v // [OUTER_LOOP_COUNT*NUM_XY] ) { //for(int time_ind = NUM_T-2; time_ind>=0; --time_ind) { unsigned int i, j, k; - REAL dtInv = 1.0/(myTimeline[time_ind+1]-myTimeline[time_ind]); + real_t dtInv = 1.0/(myTimeline[time_ind+1]-myTimeline[time_ind]); - REAL *res_arr = &myResArr[0]; + real_t *res_arr = &myResArr[0]; #pragma omp parallel for default(shared) schedule(static) private(k,j,i) if(OUTER_LOOP_COUNT>4) for( k=0; k(s0/dx); for( i=0; i 0) { for(unsigned int i=0; i 0 ) { - RWScalars ro_scal; + RWScalars ro_scal; NordeaArrays cpu_arrs; oclNordeaArrays ocl_arrs; @@ -64,11 +63,11 @@ whole_loop_nest ( { // SAFETY CHECK! bool is_safe = ( (OUTER_LOOP_COUNT*NUM_X) % NUM_Y == 0 ) && - ( (OUTER_LOOP_COUNT*NUM_Y) % NUM_X == 0 ) && - ( (OUTER_LOOP_COUNT*NUM_X) % WORKGROUP_SIZE == 0 ) && - ( (OUTER_LOOP_COUNT*NUM_Y) % WORKGROUP_SIZE == 0 ) && - ( is_pow2(NUM_X) && is_pow2(NUM_Y) ) && - ( NUM_X % 32 == 0 && NUM_Y % 32 == 0) ; + ( (OUTER_LOOP_COUNT*NUM_Y) % NUM_X == 0 ) && + ( (OUTER_LOOP_COUNT*NUM_X) % WORKGROUP_SIZE == 0 ) && + ( (OUTER_LOOP_COUNT*NUM_Y) % WORKGROUP_SIZE == 0 ) && + ( is_pow2(NUM_X) && is_pow2(NUM_Y) ) && + ( NUM_X % 32 == 0 && NUM_Y % 32 == 0) ; assert(is_safe && "NOT SAFE TO PARALLELISE ON GPU!"); } @@ -76,29 +75,29 @@ whole_loop_nest ( elapsed = runOnGPU ( ro_scal, cpu_arrs, ocl_arrs ); for( i=0; i=0; --t_ind) { - iteration_expanded_CPU ( - t_ind, alpha, beta, nu, - a, b, c, y, u, v - ); - } + for(int t_ind = NUM_T-2; t_ind>=0; --t_ind) { + iteration_expanded_CPU ( + t_ind, alpha, beta, nu, + a, b, c, y, u, v + ); + } gettimeofday(&t_end, NULL); timeval_subtract(&t_diff, &t_end, &t_start); elapsed = t_diff.tv_sec*1e6+t_diff.tv_usec; for( i=0; i +#include + +#define WORKGROUP_SIZE 512 + +#include "real.h" +#include "Util.h" +#include "ParseInput.h" + +using namespace std; + +struct PrivGlobs { + + // grid + vector myX; + vector myY; + vector myTimeline; + unsigned myXindex; + unsigned myYindex; + + // variable + vector > myResult; + + // coeffs + vector > myMuX; + vector > myVarX; + vector > myMuY; + vector > myVarY; + + // operators + vector > myDx; + vector > myDxx; + + vector > myDy; + vector > myDyy; +} __attribute__ ((aligned (128))); + + + + + +/***********************************/ + +void updateParams(const unsigned g, const real_t alpha, const real_t beta, const real_t nu, PrivGlobs& globs) +{ + for(unsigned i=0;i(s0/dx); + + for(unsigned i=0;i& x, vector >& Dx, vector >& Dxx) +{ + const unsigned n = x.size(); + + Dx.resize(n); + Dxx.resize(n); + + for(unsigned i=0;i& a, + const vector& b, + const vector& c, + const vector& r, + const int n, + vector& u, + vector& uu) +{ + int i, offset; + real_t beta; + + u[0] = r[0]; + uu[0] = b[0]; + + for(i=1; i=0; i--) { + u[i] = (u[i] - c[i]*u[i+1]) / uu[i]; + } +} + + +void +rollback( const unsigned g, PrivGlobs& globs ) { + unsigned numX = globs.myX.size(), + numY = globs.myY.size(); + + unsigned numZ = max(numX,numY); + + int k, l; + unsigned i, j; + + int kl, ku, ll, lu; + + real_t dtInv = 1.0/(globs.myTimeline[g+1]-globs.myTimeline[g]); + + vector > u(numY,vector(numX)), v(numX,vector(numY)); + vector a(numZ), b(numZ), c(numZ), y(numZ), yy(numZ); + + // explicit x + for(i=0;i=0;--i) + { + updateParams(i,alpha,beta,nu,globs); + rollback(i, globs); + } + + return globs.myResult[globs.myXindex][globs.myYindex]; +} + +real_t* run_CPUkernel( + const unsigned int& outer, + const unsigned int& numX, + const unsigned int& numY, + const unsigned int& numT, + const real_t& s0, + const real_t& t, + const real_t& alpha, + const real_t& nu, + const real_t& beta, + const vector& strikes, + vector& res +) { +#pragma omp parallel for default(shared) schedule(static) if(outer>4) + for( unsigned i = 0; i < outer; ++ i ) { + res[i] = value( s0, strikes[i], t, alpha, nu, beta, + numX, numY, numT ); + } +} + + +int main() +{ + unsigned int OUTER_LOOP_COUNT, NUM_X, NUM_Y, NUM_T; + const real_t s0 = 0.03, strike = 0.03, t = 5.0, alpha = 0.2, nu = 0.6, beta = 0.5; + + cout<<"\n// Running Original (Parallel) Volatility-Calibration Benchmark"< strikes(OUTER_LOOP_COUNT),res(OUTER_LOOP_COUNT); + + for(unsigned i=0;i +#include + +#define WORKGROUP_SIZE 512 + +#include "real.h" +#include "Util.h" +#include "ParseInput.h" + +using namespace std; + +// grid +vector myX, myY, myTimeline; +unsigned myXindex, myYindex; + +// variable +vector > myResult; + +// coeffs +vector > myMuX, myVarX, myMuY, myVarY; + +// operators +vector > myDx, myDxx, myDy, myDyy; + + + + +/***********************************/ + +void updateParams(const unsigned g, const real_t alpha, const real_t beta, const real_t nu) +{ + for(unsigned i=0;i(s0/dx); + + for(unsigned i=0;i& x, vector >& Dx, vector >& Dxx) +{ + const unsigned n = x.size(); + + Dx.resize(n); + Dxx.resize(n); + + for(unsigned i=0;i& a, + const vector& b, + const vector& c, + const vector& r, + const int n, + vector& u, + vector& uu) +{ + int i, offset; + real_t beta; + + u[0] = r[0]; + uu[0] = b[0]; + + for(i=1; i=0; i--) { + u[i] = (u[i] - c[i]*u[i+1]) / uu[i]; + } +} + +void +rollback(const unsigned g) +{ + unsigned numX = myX.size(), + numY = myY.size(); + + unsigned numZ = max(numX,numY); + + int k, l; + unsigned i, j; + + int kl, ku, ll, lu; + + real_t dtInv = 1.0/(myTimeline[g+1]-myTimeline[g]); + + vector > u(numY,vector(numX)), v(numX,vector(numY)); + + vector a(numZ), b(numZ), c(numZ), y(numZ), yy(numZ); + + // explicit x + for(i=0;i=0;--i) + { + updateParams(i,alpha,beta,nu); + rollback(i); + } + + return myResult[myXindex][myYindex]; +} + +int main() +{ + unsigned int OUTER_LOOP_COUNT, NUM_X, NUM_Y, NUM_T; + const real_t s0 = 0.03, strike = 0.03, t = 5.0, alpha = 0.2, nu = 0.6, beta = 0.5; + + fprintf(stdout, "\n// Original (Sequential) Volatility Calibration Benchmark:\n"); + readDataSet( OUTER_LOOP_COUNT, NUM_X, NUM_Y, NUM_T ); + + vector strikes(OUTER_LOOP_COUNT),res(OUTER_LOOP_COUNT); + + for(unsigned i=0;i), token) -import Text.Parsec.String +import Text.Parsec.String +import Data.Bits import Data.List import Prelude ---import Debug.Trace - ------------------------------ --- Parser-related Helpers --- ------------------------------ @@ -60,7 +61,8 @@ reduce bop ne lst = foldl bop ne lst initGrid :: Double -> Double -> Double -> Double -> Int -> Int -> Int - -> ( Int, Int, [Double], [Double], [Double]) + -> ( Int, Int, [Double], [Double], [Double], + [[Double]], [[Double]], [[Double]], [[Double]] ) initGrid s0 alpha nu t num_x num_y num_t = let logAlpha = log alpha myTimeline = map (\i -> t * (fromIntegral i) / ((fromIntegral num_t) - 1.0)) [0..num_t-1] @@ -70,7 +72,9 @@ initGrid s0 alpha nu t num_x num_y num_t = (myXindex, myYindex) = (truncate (s0 / dx), num_y `div` 2) myX = map (\i -> (fromIntegral i) * dx - (fromIntegral myXindex) * dx + s0 ) [0..num_x-1] myY = map (\i -> (fromIntegral i) * dy - (fromIntegral myYindex) * dy + logAlpha) [0..num_y-1] - in (myXindex, myYindex, myX, myY, myTimeline) + xXy = replicate num_x (replicate num_y 0.0) + (myMuX, myVarX, myMuY, myVarY) = (xXy, xXy, xXy, xXy) + in (myXindex, myYindex, myX, myY, myTimeline, myMuX, myVarX, myMuY, myVarY) --------------------------------------------- --------------------------------------------- @@ -84,8 +88,9 @@ initOperator x = let n = length x mid_x = zip3 x (tail x) (tail (tail x)) - dxu0 = (x !! 1) - (x !! 0) - dxlow = (0.0, -1.0 / dxu0, 1.0 / dxu0) + dxu = (x !! 1) - (x !! 0) + dxl = 0.0 + dxlow = (0.0, -1.0 / dxu, 1.0 / dxu) dxxlow = (0.0, 0.0, 0.0) --- Implements a parallel loop such as: --- @@ -105,10 +110,11 @@ initOperator x = dxlpxu = dxl + dxu in ( ( 2.0/dxl ) / dxlpxu, -2.0*(1.0/dxl+1.0/dxu) / dxlpxu, - ( 2.0/dxu ) / dxlpxu + ( 2.0/dxu ) / dxlpxu ) ) mid_x dxll = (x !! (n-1)) - (x !! (n-2)) + dxul = 0.0 dxhigh = [(-1.0 / dxll, 1.0 / dxll, 0.0)] dxxhigh= [(0.0, 0.0, 0.0)] in ( dxlow : (dxmid++dxhigh), dxxlow : (dxxmid++dxxhigh) ) @@ -121,29 +127,33 @@ initOperator x = doLoop :: Int -> Int -> ( [Double], [(Double,Double,Double)], [(Double,Double,Double)], [Double], [(Double,Double,Double)], [(Double,Double,Double)], - [Double], Double, Double, Double ) - -> [[Double]] - -> [[Double]] -doLoop i bound loop_ros myResult = + [Double], Double, Double, Double ) + -> ([[Double]], [[Double]], [[Double]], [[Double]], [[Double]]) + -> ([[Double]], [[Double]], [[Double]], [[Double]], [[Double]]) +doLoop i bound loop_ros loop_variants = if i == bound - then myResult - else let ( myX, myDx, myDxx, myY, myDy, myDyy, + then loop_variants + else let (myResult, myMuX, myVarX, myMuY, myVarY) = loop_variants + + ( myX, myDx, myDxx, myY, myDy, myDyy, myTimeline, alpha, beta, nu ) = loop_ros j = (bound-1-i) - (myMuX, myVarX, myMuY, myVarY) = + (myMuX', myVarX', myMuY', myVarY') = updateParams myX myY myTimeline j alpha beta nu - myResult'= rollback j myTimeline myResult - myMuX myDx myDxx myVarX - myMuY myDy myDyy myVarY + myResult'= rollback j myX myY myTimeline myResult + myMuX' myDx myDxx myVarX' + myMuY' myDy myDyy myVarY' + + loop_variants' = (myResult', myMuX', myVarX', myMuY', myVarY') in -- Hack to avoid space leak - myResult' `deepseq` myMuX `deepseq` myVarX `deepseq` myMuY `deepseq` myVarY `deepseq` - doLoop (i+1) bound loop_ros myResult' + myResult' `deepseq` myMuX' `deepseq` myVarX' `deepseq` myMuY' `deepseq` myVarY' `deepseq` + doLoop (i+1) bound loop_ros loop_variants' --------------------------------------------- --------------------------------------------- @@ -151,131 +161,19 @@ doLoop i bound loop_ros myResult = updateParams :: [Double] -> [Double] -> [Double] -> Int -> Double -> Double -> Double -> ( [[Double]], [[Double]], [[Double]], [[Double]] ) updateParams myX myY myTimeline g alpha beta nu = - let ( numX, numY ) = ( length myX, length myY ) - myMuY = replicate numX (replicate numY (0.0*alpha)) - myVarY = replicate numX (replicate numY (nu*nu) ) - myMuX = replicate numY (replicate numX 0.0 ) - myVarX = map (\ yj -> - map (\ xi -> - let b = beta * log(xi) + yj - c = 0.5 * nu * nu * (myTimeline !! g) - in exp (2.0 * (b - c)) - ) myX - ) myY - in ( myMuX, myVarX, myMuY, myVarY ) - ------------------------------------------------------- ---- TRIDAG: tridiagonal solver. --- ---- sequential and parallel implementation --- ------------------------------------------------------- - -tridagSeq :: [Double] -> [Double] -> [Double] -> [Double] - -> [Double] -tridagSeq a b c r = - let u0 = head r - uu0 = head b - - -- sequential scanl: binary operator is NOT associative - uu = scanl (\ uuim1 (ai, bi, cim1) -> - let beta = ai / uuim1 - in bi - beta*cim1 - ) uu0 (zip3 (tail a) (tail b) c) - - -- sequential scanl: binary operator is NOT associative - u = scanl (\ uim1 (ai, ri, uuim1) -> - let beta = ai / uuim1 - in ri - beta*uim1 - ) u0 (zip3 (tail a) (tail r) uu) - - ur = reverse u - uur = reverse uu - ur0'= (head ur) / (head uur) - ur' = scanl (\ uip1 (uri, uuri, cri) -> - (uri - cri*uip1) / uuri - ) ur0' (zip3 (tail ur) (tail uur) (tail $ reverse c)) - in reverse ur' - - -tridagPar :: [Double] -> [Double] -> [Double] -> [Double] - -> [Double] -tridagPar a b c y = - ---------------------------------------------------- - -- Recurrence 1: b[i] = b[i] - a[i]*c[i-1]/b[i-1] -- - -- solved by scan with 2x2 matrix mult operator -- - ---------------------------------------------------- - let bfst = head b - mats = map (\ (bi,ai,cim1) -> (bi, 0.0-ai*cim1, 1.0, 0.0) ) - (zip3 (tail b) (tail a) c) - - scmt = -- parallel scan with 2x2 mat mult op - scanl(\ (a0,a1,a2,a3) (b0,b1,b2,b3) -> - let val = 1.0/(a0*b0) in - ( (b0*a0 + b1*a2)*val, - (b0*a1 + b1*a3)*val, - (b2*a0 + b3*a2)*val, - (b2*a1 + b3*a3)*val ) ) - (1.0,0.0,0.0,1.0) mats - - b' = map (\ (t0,t1,t2,t3) -> (t0*bfst + t1) / (t2*bfst + t3) ) - scmt - - ------------------------------------------------------ - -- Recurrence 2: y[i] = y[i] - (a[i]/b[i-1])*y[i-1] -- - -- solved by scan with linear func comp operator -- - ------------------------------------------------------ - y0 = head y - lffns= map (\ (yi,ai,bim1) -> (yi, 0.0-ai/bim1) ) - (zip3 (tail y) (tail a) b') - - cffns= -- parallel scan with lin fun composition op - scanl (\ (a0,a1) (b0,b1) -> (b0 + b1*a0, a1*b1) ) - (0.0, 1.0) lffns - - yf = map (\ (t1,t2) -> t1 + t2*y0 ) cffns - - ------------------------------------------------------ - -- Recurrence 3: backward recurrence solved via -- - -- scan with linear func comp operator -- - ------------------------------------------------------ - yn = (last yf) / (last b') - lbfn0= map (\ (yi,bi,ci) -> (yi/bi, 0.0-ci/bi) ) - (tail $ zip3 (reverse yf) (reverse b') (reverse c)) - lbfns= (0.0, 1.0) : lbfn0 - cbfns= tail $ -- parallel scan with lin fun composition op - scanl (\ (a0,a1) (b0,b1) -> (b0 + b1*a0, a1*b1) ) - (0.0, 1.0) lbfns - - yb = map (\ (t1,t2) -> t1 + t2*yn ) cbfns - - in (reverse yb) - ---------------------------------------------- ---- Implicit Method (parameterization) --- ---------------------------------------------- - -implicitMethod :: Double - -> [(Double,Double,Double)] - -> [(Double,Double,Double)] - -> [[Double]] -> [[Double]] - -> [[Double]] -> [[Double]] -implicitMethod dtInv myD myDD myMu myVar u = - zipWith3(\ mu_row var_row u_row -> - let (a, b, c) = unzip3 $ - zipWith4 (\ mu var (d0,d1,d2) (dd0,dd1,dd2) -> - ( 0.0 - 0.5*(mu*d0 + 0.5*var*dd0) - , dtInv - 0.5*(mu*d1 + 0.5*var*dd1) - , 0.0 - 0.5*(mu*d2 + 0.5*var*dd2) - ) - ) mu_row var_row myD myDD - in if (1::Integer) == (1::Integer) - then tridagSeq a b c u_row - else tridagPar a b c u_row - ) myMu myVar u - + unzip4 $ map (\ xi -> unzip4 $ + map (\ yj -> let b = beta * log(xi) + yj + c = 0.5 * nu * nu * (myTimeline !! g) + in ( 0.0, exp (2.0 * (b - c) ), 0.0, nu * nu ) + ) myY + ) myX --------------------------------------------- ---- Explicit Method (parameterization) --- +--- Helpers for the rollback function --- +--- ToDo: make them nice!!! --- --------------------------------------------- +-- explicitX = explicitXY dt_inv 0.5 (transpose my_result) (transpose myMuX) (transpose myVarX) myDx myDxx +-- explicitY = explicitXY 0.0 1.0 my_result myMuY myVarY myDy myDyy explicitXY :: Double -> Double -> [[Double]] -> [[Double]] -> [[Double]] -> [ (Double,Double,Double) ] @@ -299,7 +197,6 @@ explicitXY dt_inv fact my_result myMuY myVarY myDy myDyy = ) (zip3 my_result myMuY myVarY) ------------------------------------------ ---- UNUSED --- --- loop-like definition for explicitX --- --- inneficient due to list traversal --- --- to find every index. --- @@ -334,34 +231,125 @@ explicitX0 num_x num_y dt_inv my_result ) [0..num_y-1] +tridag :: [Double] -> [Double] -> [Double] -> [Double] + -> ( [Double], [Double] ) +tridag a b c r = + let u0 = head r + uu0 = head b + + -- scanl's binary operator is NOT associative + uu = scanl (\ uuim1 (ai, bi, cim1) -> + let beta = ai / uuim1 + in bi - beta*cim1 + ) uu0 (zip3 (tail a) (tail b) c) + + -- scanl's binary operator is NOT associative + u = scanl (\ uim1 (ai, ri, uuim1) -> + let beta = ai / uuim1 + in ri - beta*uim1 + ) u0 (zip3 (tail a) (tail r) uu) + + ur = reverse u + uur = reverse uu + ur0'= (head ur) / (head uur) + ur' = scanl (\ uip1 (uri, uuri, cri) -> + (uri - cri*uip1) / uuri + ) ur0' (zip3 (tail ur) (tail uur) (tail $ reverse c)) + in (reverse ur', uu) + + +tridagPar :: [Double] -> [Double] -> [Double] -> [Double] + -> ( [Double], [Double] ) +tridagPar a b c r = + let -- u0 = head r + -- uu0 = head b + u0 = head b + uu0 = head r + + -- creating the 2x2 matrices + mats = map (\(ai,bi,cim1)-> (bi, -ai*cim1, 1.0, 0.0)) (zip3 (tail a) (tail b) c) + -- scan with 2x2 matrix multiplication + scanmat = scanl (\(x1,y1,z1,w1) (x2,y2,z2,w2) -> + let dv = 1.0/(x1*x2) + in ( (x1*x2+y1*z2)*dv, + (x1*y2+y1*w2)*dv, + (z1*x2+w1*z2)*dv, + (z1*y2+w1*w2)*dv ) + ) (1.0, 0.0, 0.0, 1.0) mats + + -- compute the first recurrence result + uu = map (\(x,y,z,w) -> (x*u0 + y) / (z*u0 + w) ) scanmat + + -- compute the second recurrence + pairs = map (\(ai,ri,uuim1)->(ri, -ai/uuim1)) (zip3 (tail a) (tail r) uu) + + scanpairs = scanl (\ (x1,y1) (x2,y2) -> (x2+y2*x1, y1*y2) ) (0.0,1.0) pairs + + u = map (\(x,y) -> x + u0*y) scanpairs + + -- backwards recurrence + ur = reverse u + uur = reverse uu + ur0'= (head ur) / (head uur) + + pairsr = map (\(uri, uuri, cri)->(uri/uuri, -cri/uuri)) (zip3 (tail ur) (tail uur) (tail $ reverse c)) + scanpairsr = scanl (\ (x1,y1) (x2,y2) -> (x2+y2*x1, y1*y2) ) (0.0,1.0) pairsr + ur' = map (\(x,y) -> x + ur0'*y) scanpairsr + + in (reverse ur', uu) --------------------------------------------- --- rollback: the brain of the program --- --------------------------------------------- -rollback :: Int -> [Double] -> [[Double]] +rollback :: Int -> [Double] -> [Double] -> [Double] -> [[Double]] -> [[Double]] -> [(Double,Double,Double)] -> [(Double,Double,Double)] -> [[Double]] -> [[Double]] -> [(Double,Double,Double)] -> [(Double,Double,Double)] -> [[Double]] -> [[Double]] -rollback g myTimeline myResult +rollback g myX myY myTimeline myResult myMuX myDx myDxx myVarX myMuY myDy myDyy myVarY = - let dtInv = 1.0 / ( (myTimeline !! (g+1)) - (myTimeline !! g) ) + let (numX, numY) = (length myX, length myY) + numZ = max numX numY + dtInv = 1.0 / ( (myTimeline !! (g+1)) - (myTimeline !! g) ) - u0= explicitXY dtInv 0.5 (transpose myResult) myMuX myVarX myDx myDxx + u0= explicitXY dtInv 0.5 (transpose myResult) (transpose myMuX) (transpose myVarX) myDx myDxx v0= explicitXY 0.0 1.0 myResult myMuY myVarY myDy myDyy u1= map (\ (us, vs) -> zipWith (+) us vs ) (zip u0 (transpose v0)) - u2= implicitMethod dtInv myDx myDxx myMuX myVarX u1 - y = zipWith (\ u_row v_row -> - zipWith (\ u_el v_el -> dtInv*u_el - 0.5*v_el) u_row v_row - ) (transpose u2) v0 - - in implicitMethod dtInv myDy myDyy myMuY myVarY y + u2= map (\ t -> let (uj, myDx, myDxx, myMuX, myVarX) = t + (a,b,c) = unzip3 $ + map (\ tt -> let (myDx, myDxx, myMuX, myVarX) = tt + (dx0, dx1, dx2 ) = myDx + (dxx0, dxx1, dxx2) = myDxx + in ( -0.5*(myMuX*dx0 + 0.5*myVarX*dxx0), + dtInv - 0.5*(myMuX*dx1 + 0.5*myVarX*dxx1), + -0.5*(myMuX*dx2+0.5*myVarX*dxx2) ) ) + (zip4 myDx myDxx myMuX myVarX) + + (uj', yy) = tridag a b c uj -- tridagPar a b c uj + in uj' ) + (zip5 u1 (replicate numY myDx) (replicate numY myDxx) (transpose myMuX) (transpose myVarX)) + + in map (\ t -> let (ui, vi, myDy, myDyy, myMuY, myVarY) = t + (a,b,c) = unzip3 $ + map (\ tt -> let (myDy, myDyy, myMuY, myVarY) = tt + (dy0, dy1, dy2 ) = myDy + (dyy0, dyy1, dyy2) = myDyy + in ( -0.5*(myMuY*dy0+0.5*myVarY*dyy0), + dtInv - 0.5*(myMuY*dy1+0.5*myVarY*dyy1), + -0.5*(myMuY*dy2+0.5*myVarY*dyy2) ) ) + (zip4 myDy myDyy myMuY myVarY) + + y = map (\ (u,v) -> dtInv * u - 0.5 * v) (zip ui vi) + + (ri, yy) = tridag a b c y -- tridagPar a b c y + in ri ) + (zip6 (transpose u2) v0 (replicate numX myDy) (replicate numX myDyy) myMuY myVarY) --------------------------------------------- --------------------------------------------- @@ -375,19 +363,20 @@ value :: (Double, Double, Double, Double, Double) -> (Int, Int, Int, Int) -> Double -> Double value params it_spaces strike = - let (_, num_x, num_y, num_t) = it_spaces - (s0, t, alpha, nu, beta) = params + let (outer, num_x, num_y, num_t) = it_spaces + (s0, t, alpha, nu, beta) = params - (myXindex, myYindex, myX, myY, myTimeline) = + (myXindex, myYindex, myX, myY, myTimeline, myMuX, myVarX, myMuY, myVarY) = initGrid s0 alpha nu t num_x num_y num_t (myDx, myDxx) = initOperator myX (myDy, myDyy) = initOperator myY my_result_ini = map (\ xi -> replicate num_y (max (xi - strike) 0.0 )) myX + loop_variants = (my_result_ini, myMuX, myVarX, myMuY, myVarY) loop_ros = (myX, myDx, myDxx, myY, myDy, myDyy, myTimeline, alpha, beta, nu) - my_result = doLoop 0 (num_t-1) loop_ros my_result_ini + (my_result,_,_,_,_) = doLoop 0 (num_t-1) loop_ros loop_variants in (my_result !! myXindex) !! myYindex -- my_result[myXindex, myYindex] @@ -398,8 +387,8 @@ compute :: (Int, Int, Int, Int) -> (Double, Double, Double, Double, Double) -> [Double] compute it_spaces params = - let -- (s0, t, alpha, nu, beta) = params - (outer, _, _, _) = it_spaces -- was (outer, num_x, num_y, num_t) + let (s0, t, alpha, nu, beta) = params + (outer, num_x, num_y, num_t) = it_spaces strikes = map (\i -> 0.001 * (fromIntegral i)) [0..outer-1] res = map (value params it_spaces) strikes in res @@ -429,32 +418,27 @@ validate res_ref res info= --- e.g., parsing Dataset from StdIn --- ----------------------------------------- main :: IO () -main = do s <- getContents +main = do s <- getContents case parse run "input" s of Left e -> error $ show e - Right (p,pr,i) -> do let msg_lst = validate pr p i - _ <- mapM putStrLn msg_lst - putStrLn "" - where run = do outer <- readInt + Right m -> do (v,runtime) <- m + result <- getEnv "HIPERMARK_RESULT" + writeFile result $ show v + runtime_file <- getEnv "HIPERMARK_RUNTIME" + writeFile runtime_file $ show runtime + where run = do whitespace + outer <- readInt num_x <- readInt num_y <- readInt num_t <- readInt - s0 <- readDouble - t <- readDouble - alpha <- readDouble - nu <- readDouble - beta <- readDouble - - let params = (s0, t, alpha, nu, beta) - - let v = compute (outer, num_x, num_y, num_t) params - r <- readDouble1d - return (v, r, (outer, num_x, num_y, num_t)) - - readInt2d = readArray $ readArray readInt - readDouble1d = readArray readDouble - readDouble2d = readArray $ readArray readDouble - readDouble3d = readArray $ readArray $ readArray readDouble + + let params = (0.03, 5.0, 0.2, 0.6, 0.5) --(s0, t, alpha, nu, beta) + + return $ do + start <- getCPUTime -- In picoseconds; 1 microsecond == 10^6 picoseconds. + let v = compute (outer, num_x, num_y, num_t) params + end <- v `deepseq` getCPUTime + return (v, (end - start) `div` 1000000) -- ghc -O2 -msse2 -rtsopts PricingLexiFi.hs -- ./PricingLexiFi +RTS -K128m -RTS < ../Data/Medium/input.data diff --git a/benchmarks/LocVolCalib/lib/include/Constants.h b/benchmarks/LocVolCalib/lib/include/Constants.h new file mode 100644 index 0000000..3df4577 --- /dev/null +++ b/benchmarks/LocVolCalib/lib/include/Constants.h @@ -0,0 +1,30 @@ +#ifndef CONSTANTS_H +#define CONSTANTS_H + +#include "real.h" + +#define REAL3_CT 4 +#define TRANSPOSE_UV 1 + +#define WARP (1< +#include +#include + +using namespace std; + +#include + +#if REAL_IS_FLOAT + #define read_real read_float +#else + #define read_real read_double +#endif + +const float EPS = 0.00001; + +/***********************************/ +/********** READ DATA SET **********/ +/***********************************/ + +void readDataSet( unsigned int& outer, + unsigned int& num_X, + unsigned int& num_Y, + unsigned int& num_T +) { + if( read_int( static_cast( &outer ) ) || + read_int( static_cast( &num_X ) ) || + read_int( static_cast( &num_Y ) ) || + read_int( static_cast( &num_T ) ) ) { + + fprintf(stderr, "Syntax error when reading the dataset, i.e., four ints.\n"); + exit(1); + } + + { // check dataset invariants: + bool atr_ok = true; + + atr_ok = outer > 0; + assert(atr_ok && "Outer loop count less than 0!"); + + atr_ok = (num_X > 0) && (num_X <= WORKGROUP_SIZE) && is_pow2(num_X); + assert(atr_ok && "Illegal NUM_X value!"); + + atr_ok = (num_Y > 0) && (num_Y <= WORKGROUP_SIZE) && is_pow2(num_Y); + assert(atr_ok && "Illegal NUM_X value!"); + + atr_ok = num_T > 0; + assert(atr_ok && "NUM_T value less or equal to zero!!"); + } +} + +#endif // PARSE_INPUT + diff --git a/benchmarks/OptionPricing/datasets/large/input.json b/benchmarks/OptionPricing/datasets/large/input.json new file mode 100644 index 0000000..5dc0044 --- /dev/null +++ b/benchmarks/OptionPricing/datasets/large/input.json @@ -0,0 +1,4088 @@ +{ + "contract_number" : 3, + "monte_carlo_iterations" : 131072, + "num_path_dates" : 367, + "num_underlyings" : 3, + "num_models" : 1, + "num_bits" : 30, + + "dir_vs" : + [ + [ + 536870912, 268435456, 134217728, 67108864, 33554432, 16777216, 8388608, 4194304, 2097152, 1048576, 524288, 262144, 131072, 65536, 32768, 16384, 8192, 4096, 2048, 1024, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 570425344, 855638016, 713031680, 1069547520, 538968064, 808452096, 673710080, 1010565120, 572653568, 858980352, 715816960, 1073725440, 536879104, 805318656, 671098880, 1006648320, 570434048, 855651072, 713042560, 1069563840, 538976288, 808464432, 673720360, 1010580540, 572662306, 858993459 + ], + [ + 536870912, 805306368, 402653184, 603979776, 973078528, 385875968, 595591168, 826277888, 438304768, 657457152, 999817216, 358875136, 538574848, 807862272, 406552576, 605372416, 975183872, 389033984, 597170176, 828646400, 437926400, 656873216, 1002152832, 357921088, 536885792, 805312304, 402662296, 603992420, 973085210, 385885991 + ], + [ + 536870912, 805306368, 939524096, 335544320, 234881024, 721420288, 411041792, 616562688, 920649728, 1062207488, 381157376, 258736128, 771883008, 453181440, 545488896, 817971200, 954261504, 340963328, 238651392, 732843008, 417426944, 609285376, 909831040, 1068349120, 383778848, 256901168, 783810616, 460062740, 537001998, 805503019 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 167772160, 285212672, 713031680, 566231040, 853540864, 489684992, 952631296, 208928768, 316801024, 758317056, 550076416, 813154304, 417505280, 1009913856, 172697600, 297131008, 704744960, 553894656, 847291520, 499194688, 954376224, 204607536, 306915352, 766893116, 536972810, 805552913 + ], + [ + 536870912, 805306368, 402653184, 469762048, 301989888, 721420288, 92274688, 264241152, 941621248, 741343232, 169345024, 924581888, 395444224, 619380736, 1034256384, 603963392, 838868992, 452997120, 494934016, 331357184, 706744832, 120597248, 261621120, 953946048, 800208928, 148581424, 935168536, 350484252, 630339474, 1072370923 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 503316480, 754974720, 629145600, 440401920, 94371840, 711983104, 229113856, 374079488, 330694656, 996212736, 907247616, 557531136, 867573760, 190918656, 1041467392, 490437632, 766918144, 643898624, 462663040, 125527616, 672545696, 202454896, 373006376, 288845836, 1000351766, 930090001 + ], + [ + 536870912, 268435456, 402653184, 872415232, 838860800, 956301312, 612368384, 717225984, 211812352, 386924544, 302514176, 688128000, 1015414784, 516751360, 1051492352, 773734400, 914432000, 63877120, 807741440, 165200896, 748683776, 118489344, 168296832, 486802240, 243663648, 667747216, 439124552, 81674924, 975249610, 350138737 + ], + [ + 536870912, 268435456, 671088640, 469762048, 973078528, 1023410176, 713031680, 339738624, 912261120, 797966336, 176685056, 71565312, 510263296, 865533952, 814120960, 961232896, 887136256, 668078080, 116070400, 382772224, 1047134720, 597098752, 411468416, 625689024, 249602976, 449975248, 745216680, 43033924, 134873446, 201786361 + ], + [ + 536870912, 268435456, 402653184, 67108864, 704643072, 385875968, 696254464, 205520896, 920649728, 946864128, 359137280, 859045888, 302907392, 50659328, 462192640, 524599296, 895541248, 590794752, 168810496, 118033408, 831447552, 138662144, 485185920, 796511296, 1021313184, 1064304752, 619184920, 997458052, 250479054, 745865975 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 838860800, 889192448, 645922816, 46137344, 476053504, 584056832, 210239488, 465829888, 820903936, 689897472, 73695232, 249118720, 110075904, 315338752, 610637824, 517665792, 1049494016, 785318144, 376210304, 735921088, 402760480, 738505552, 168368744, 151499820, 344957894, 936096557 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 503316480, 922746880, 41943040, 423624704, 228589568, 651165696, 195559424, 500957184, 791019520, 261292032, 1040285696, 118407168, 982065152, 625250304, 329533440, 298984448, 153690624, 76845824, 579619712, 692987840, 900670432, 450334832, 363187112, 719119956, 765461306, 382730781 + ], + [ + 536870912, 805306368, 402653184, 603979776, 838860800, 117440512, 478150656, 658505728, 752877568, 1060110336, 141033472, 209453056, 244187136, 272957440, 678068224, 1014546432, 377724928, 876875776, 443160576, 998185984, 168665600, 318837504, 914397568, 71818816, 40763680, 527762288, 939688008, 335855668, 705536494, 587273091 + ], + [ + 536870912, 268435456, 671088640, 738197504, 637534208, 150994944, 813694976, 943718400, 77594624, 179306496, 798490624, 967049216, 134348800, 1006698496, 235044864, 620937216, 377643008, 826314752, 874711040, 854819840, 725109248, 856992512, 664336768, 94804544, 100663328, 419430416, 411041832, 339738668, 580911142, 61865993 + ], + [ + 536870912, 805306368, 939524096, 603979776, 100663296, 452984832, 998244352, 188743680, 866123776, 389021696, 287834112, 172228608, 824836096, 977731584, 153714688, 507854848, 254402560, 88403968, 883578880, 235160576, 118055424, 422917888, 371224704, 326210368, 654926368, 691353392, 773877944, 930190180, 554263078, 842348331 + ], + [ + 536870912, 268435456, 134217728, 872415232, 771751936, 486539264, 629145600, 163577856, 467664896, 472907776, 168296448, 993787904, 201981952, 37552128, 260734976, 587087872, 535322624, 705662976, 729954304, 79891456, 912360960, 569626368, 1072277120, 974077120, 595691040, 818138896, 409052808, 1022573812, 443254286, 869191437 + ], + [ + 536870912, 805306368, 134217728, 67108864, 369098752, 654311424, 562036736, 1044381696, 333447168, 1068498944, 487063552, 614727680, 652869632, 790036480, 635600896, 682835968, 881451008, 518402048, 587823104, 933663744, 426354176, 844586752, 25366144, 239108416, 467682848, 1001484080, 185235080, 61216068, 124379190, 290861079 + ], + [ + 536870912, 805306368, 134217728, 603979776, 436207616, 1023410176, 830472192, 1061158912, 274726912, 946864128, 752353280, 1040973824, 660209664, 206503936, 247103488, 796737536, 671293440, 335712256, 302135296, 419587072, 730054144, 37987072, 568382336, 120820672, 1018805792, 108831536, 193090440, 843240420, 702586426, 590426893 + ], + [ + 536870912, 805306368, 402653184, 335544320, 637534208, 452984832, 578813952, 364904448, 903872512, 84934656, 498597888, 152829952, 794951680, 886243328, 374964224, 51200000, 911761408, 856600576, 777627648, 655301632, 140164608, 1007657216, 718934912, 701382080, 523919392, 752726064, 41953304, 633494548, 769842726, 286331163 + ], + [ + 536870912, 805306368, 134217728, 67108864, 1040187392, 721420288, 696254464, 272629760, 945815552, 202375168, 973602816, 360448000, 47579136, 965935104, 671121408, 872464384, 905977856, 788533248, 394328064, 994094080, 299935232, 475021568, 40427904, 426520640, 954132512, 753882608, 718703448, 227747404, 503316482, 452984835 + ], + [ + 536870912, 268435456, 134217728, 335544320, 167772160, 822083584, 343932928, 884998144, 618659840, 753926144, 953679872, 852230144, 61734912, 386334720, 598638592, 117915648, 732864512, 319229952, 565086208, 570938368, 892262912, 382142208, 298731904, 976729280, 689351392, 150700016, 716743768, 536617964, 152480482, 419135473 + ], + [ + 536870912, 268435456, 402653184, 603979776, 33554432, 486539264, 679477248, 155189248, 580911104, 678428672, 745013248, 1043595264, 997326848, 936706048, 1021870080, 57950208, 64118784, 648384512, 973113344, 687879168, 847299072, 809547008, 136348288, 1009833408, 642257824, 520412624, 901408584, 563183252, 737329666, 177583361 + ], + [ + 536870912, 805306368, 134217728, 738197504, 234881024, 687865856, 176160768, 750780416, 429916160, 355467264, 1017643008, 563347456, 825622528, 514523136, 110526464, 312197120, 952016896, 869232640, 505976832, 290771968, 781595136, 245081856, 1052701824, 919569344, 447225376, 345248144, 1035356408, 929807420, 464961058, 40591763 + ], + [ + 536870912, 805306368, 671088640, 335544320, 436207616, 486539264, 511705088, 742391808, 375390208, 995098624, 229113856, 905183232, 966393856, 533528576, 209747968, 356564992, 987799552, 504385536, 524838912, 1071936512, 1020426752, 1026142464, 785570176, 69807424, 38934176, 560547792, 280145512, 729389876, 368705538, 161284099 + ], + [ + 536870912, 805306368, 134217728, 335544320, 100663296, 721420288, 713031680, 666894336, 371195904, 326107136, 918028288, 904134656, 997851136, 317915136, 1004699648, 73908224, 1042325504, 930123776, 951597056, 182778880, 402305536, 506671872, 121795200, 819401408, 515383904, 300157520, 897191688, 770924636, 392310882, 145205587 + ], + [ + 536870912, 268435456, 939524096, 201326592, 1040187392, 385875968, 713031680, 398458880, 140509184, 609222656, 174587904, 627310592, 64094208, 708509696, 895123456, 1003438080, 637558784, 184578048, 746592256, 213937152, 484463104, 613417728, 680037248, 385142336, 31066144, 722404560, 1021355752, 881884540, 277363234, 452229073 + ], + [ + 536870912, 268435456, 134217728, 603979776, 905969664, 721420288, 109051904, 20971520, 664797184, 919601152, 422051840, 198967296, 617480192, 71892992, 638091264, 592199680, 583409664, 923111424, 214849536, 810150912, 403225088, 743232768, 306603648, 491120448, 770582176, 131712624, 645969848, 289415012, 799054338, 315639041 + ], + [ + 536870912, 805306368, 939524096, 469762048, 570425344, 1056964608, 58720256, 557842432, 786432000, 632291328, 270008320, 139722752, 607518720, 1048248320, 494436352, 1017430016, 583983104, 262107136, 190187520, 898317312, 402681344, 738211072, 436261760, 587209408, 562087520, 507533392, 761275736, 82897452, 1056476674, 769934595 + ], + [ + 536870912, 268435456, 671088640, 67108864, 33554432, 486539264, 310378496, 239075328, 186646528, 634388480, 96993280, 367263744, 1032454144, 966590464, 1000374272, 646987776, 879271936, 980684800, 828508160, 346649600, 291686912, 78215424, 962727040, 11126592, 996294432, 497644432, 702714920, 334101364, 583180290, 909709313 + ], + [ + 536870912, 268435456, 402653184, 335544320, 503316480, 117440512, 746586112, 876609536, 236978176, 523239424, 950534144, 712769536, 154009600, 870907904, 209747968, 608190464, 371220480, 187715584, 648574976, 763108352, 632205824, 128569600, 44087424, 997211328, 780698272, 558692848, 797334712, 513135524, 690880514, 602472449 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 100663296, 218103808, 746586112, 641728512, 1029701632, 883949568, 439877632, 996933632, 967442432, 920715264, 492863488, 78692352, 37249024, 124579840, 1068111872, 1004614656, 836776448, 586176768, 1062770048, 870064832, 630354144, 9296304, 139121832, 336691844, 574119938, 929886211 + ], + [ + 536870912, 805306368, 939524096, 335544320, 570425344, 553648128, 981467136, 62914560, 488636416, 76546048, 748158976, 818675712, 1054212096, 701431808, 273580032, 134463488, 739794944, 906792960, 58091520, 463459328, 964092416, 513755904, 435617408, 677350720, 475410144, 235914608, 393104184, 965967628, 402705634, 604016243 + ], + [ + 536870912, 805306368, 671088640, 67108864, 973078528, 285212672, 343932928, 692060160, 148897792, 1058013184, 669515776, 14942208, 185204736, 904724480, 367558656, 635748352, 227188736, 162336768, 864577536, 582255616, 906162688, 521778432, 394939264, 682457152, 252243360, 267679376, 81938344, 822706164, 618852866, 17413379 + ], + [ + 536870912, 805306368, 939524096, 201326592, 704643072, 754974720, 897581056, 1019215872, 656408576, 680525824, 824705024, 397148160, 633208832, 881393664, 320241664, 249937920, 906518528, 255651840, 748046336, 790987776, 480837120, 392988416, 278833792, 1025073472, 1035890720, 143231216, 18277464, 803573652, 696815138, 519835635 + ], + [ + 536870912, 268435456, 134217728, 469762048, 637534208, 587202560, 25165824, 1019215872, 442499072, 355467264, 715653120, 557056000, 11141120, 739573760, 1046642688, 923877376, 1004576768, 972042240, 952678400, 671415296, 201498112, 773947136, 1061744512, 667215808, 534962976, 466722832, 696299528, 817952900, 878763298, 707850001 + ], + [ + 536870912, 805306368, 402653184, 67108864, 167772160, 721420288, 612368384, 817889280, 312475648, 630194176, 253231104, 516685824, 62521344, 841154560, 523927552, 920895488, 530243584, 1014222848, 1040369664, 964656128, 194533888, 504151808, 152735872, 330557760, 438455520, 53428848, 950012424, 1049638652, 865619170, 705446515 + ], + [ + 536870912, 805306368, 671088640, 335544320, 1040187392, 452984832, 260046848, 566231040, 580911104, 292552704, 446169088, 490995712, 411172864, 742719488, 841121792, 422952960, 1052385280, 191991808, 397989888, 502594560, 146433536, 879868672, 238603392, 859074240, 463109856, 532801488, 964754152, 515911108, 991977186, 1068529619 + ], + [ + 536870912, 805306368, 402653184, 603979776, 973078528, 620756992, 679477248, 239075328, 639631360, 187695104, 798490624, 669253632, 987365376, 108331008, 706772992, 218251264, 346038272, 275787776, 959977472, 110371840, 157432320, 262219008, 400730240, 584273472, 578455072, 272071472, 673224600, 1006793700, 505428186, 523253621 + ], + [ + 536870912, 805306368, 671088640, 469762048, 503316480, 922746880, 1048576000, 750780416, 933232640, 359661568, 231211008, 302776320, 822476800, 1031995392, 276594688, 845529088, 728637440, 184496128, 78817280, 32168960, 336903680, 840550144, 18888320, 363856064, 208142752, 746339952, 474885448, 877595084, 677034022, 911655987 + ], + [ + 536870912, 268435456, 939524096, 872415232, 436207616, 419430400, 729808896, 943718400, 648019968, 433061888, 1071120384, 549715968, 72482816, 547684352, 384663552, 592920576, 805969920, 673255424, 203405312, 774009856, 54508032, 850544896, 331854720, 518413376, 1064150176, 639067344, 522851928, 615589252, 619162482, 913730613 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 1040187392, 754974720, 629145600, 775946240, 689963008, 397410304, 626524160, 496762880, 575537152, 253034496, 111771648, 1053310976, 517480448, 786182144, 921573376, 182795264, 886160896, 434400512, 1011746176, 303373888, 992588064, 747137968, 167263064, 342622364, 909516750, 960044373 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 234881024, 687865856, 427819008, 457179136, 333447168, 890241024, 664272896, 441712640, 911343616, 544669696, 491290624, 918994944, 176332800, 702935040, 504891392, 823397376, 229778944, 694621440, 886085504, 93516352, 626043488, 315809360, 280018040, 851632964, 547919818, 450289443 + ], + [ + 536870912, 805306368, 402653184, 67108864, 503316480, 318767104, 763363328, 708837376, 199229440, 328204288, 157810688, 1048313856, 1036648448, 478478336, 1053982720, 421904384, 144220160, 148959232, 371865600, 1058354176, 800753152, 593090304, 726832000, 124111168, 91790944, 208719312, 750920840, 942213868, 873504546, 101507001 + ], + [ + 536870912, 268435456, 402653184, 603979776, 771751936, 452984832, 947912704, 146800640, 253755392, 512753664, 802684928, 1032060928, 595460096, 56819712, 325877760, 189710336, 794304512, 21237760, 442374144, 586359808, 708095488, 621468416, 998643840, 343349440, 701142816, 178911888, 164274648, 447346308, 298492926, 1051328419 + ], + [ + 536870912, 268435456, 134217728, 603979776, 369098752, 620756992, 595591168, 616562688, 98566144, 544210944, 699924480, 737935360, 962199552, 807862272, 403210240, 739131392, 842047488, 858935296, 109750272, 124089344, 557465088, 630657280, 164674944, 37905856, 313692256, 156856752, 671098840, 872422220, 503319298, 16792235 + ], + [ + 536870912, 805306368, 939524096, 738197504, 369098752, 452984832, 243269632, 960495616, 228589568, 737148928, 450363392, 293339136, 700317696, 704577536, 1005355008, 315113472, 90578944, 327364608, 617789440, 779578368, 623556096, 834366208, 904697472, 365454656, 635831200, 499330288, 837991000, 667377468, 1020435614, 846680143 + ], + [ + 536870912, 268435456, 134217728, 469762048, 1040187392, 956301312, 276824064, 868220928, 614465536, 30408704, 732430336, 877395968, 919994368, 437583872, 53903360, 60735488, 945168384, 13963264, 1058441216, 764337152, 157163008, 206121216, 854104192, 806875072, 404667040, 336783568, 572527400, 118492044, 696788086, 593247941 + ], + [ + 536870912, 805306368, 402653184, 67108864, 100663296, 989855744, 377487360, 767557632, 1033895936, 326107136, 209190912, 752091136, 571342848, 219611136, 898400256, 1062518784, 376840192, 365113344, 159553536, 222544896, 863675904, 1012386560, 886353536, 640735680, 186647456, 246422640, 702022904, 1000619540, 678825774, 448989351 + ], + [ + 536870912, 805306368, 939524096, 201326592, 973078528, 922746880, 41943040, 171966464, 509607936, 407896064, 761790464, 350486528, 639500288, 84475904, 29065216, 1053409280, 423337984, 864677888, 1037801472, 765066240, 886284800, 372099840, 1025876096, 226541888, 81805024, 772806928, 822621064, 934559220, 871771542, 749548797 + ], + [ + 536870912, 805306368, 134217728, 67108864, 838860800, 922746880, 931135488, 868220928, 429916160, 183500800, 656932864, 263454720, 1073348608, 798162944, 267747328, 665632768, 198844416, 363016192, 1023248384, 573096960, 254284288, 1001654016, 100286336, 479410112, 175483808, 594345456, 637153448, 747834484, 41266778, 661447011 + ], + [ + 536870912, 805306368, 134217728, 469762048, 33554432, 83886080, 1048576000, 750780416, 1029701632, 101711872, 590872576, 764674048, 157155328, 673644544, 738951168, 169492480, 420323328, 1018785792, 702556160, 63974400, 718801408, 507779328, 730217600, 711141824, 93160416, 628714192, 570441304, 889199492, 914367078, 817895859 + ], + [ + 536870912, 268435456, 402653184, 738197504, 33554432, 922746880, 394264576, 1044381696, 434110464, 800063488, 38273024, 64225280, 882769920, 402456576, 179601408, 987217920, 103456768, 288018432, 379467776, 821902336, 87333376, 681040640, 499824000, 161143104, 55981664, 224996848, 675971496, 282785636, 355861334, 815336809 + ], + [ + 536870912, 805306368, 134217728, 67108864, 838860800, 385875968, 1015021568, 784334848, 920649728, 181403648, 886571008, 366739456, 208535552, 154730496, 765820928, 1065041920, 933601280, 477851648, 824551424, 565933056, 155556352, 313221888, 939370112, 593972672, 967544928, 894584592, 750265528, 382472908, 987105494, 1022700533 + ], + [ + 536870912, 268435456, 402653184, 603979776, 503316480, 50331648, 360710144, 213909504, 190840832, 1041235968, 319291392, 227278848, 684851200, 359596032, 1024557056, 109232128, 21651456, 599240704, 727713792, 772801536, 185075200, 697043200, 919734144, 376373440, 680625504, 172147504, 170549976, 497532804, 946343106, 597428067 + ], + [ + 536870912, 268435456, 939524096, 469762048, 234881024, 922746880, 377487360, 1010827264, 996147200, 386924544, 109576192, 73138176, 661520384, 420937728, 831750144, 316096512, 456138752, 577417216, 646449152, 341574656, 527306240, 85395200, 1066632064, 634867136, 229647776, 506117904, 501745368, 55312836, 434507682, 21693975 + ], + [ + 536870912, 805306368, 671088640, 67108864, 838860800, 184549376, 545259520, 666894336, 52428800, 915406848, 785907712, 11796480, 902955008, 941686784, 1040285696, 218775552, 832495616, 138809344, 913442816, 426839040, 1006209536, 1059995904, 412413056, 1003688640, 488734752, 194659824, 927394504, 217193636, 832573238, 709889773 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 973078528, 285212672, 662700032, 725614592, 576716800, 714080256, 114819072, 270794752, 325976064, 1024786432, 630489088, 239714304, 66494464, 718581760, 305530880, 913378304, 479887872, 634179328, 448409216, 632910912, 623813088, 183547600, 156762776, 929302948, 51252534, 981798729 + ], + [ + 536870912, 805306368, 939524096, 738197504, 1040187392, 318767104, 595591168, 423624704, 228589568, 11534336, 2621440, 49545216, 973209600, 151846912, 446464000, 1003569152, 443277312, 616706048, 937682944, 377895936, 902424064, 830420736, 727148928, 279147456, 136315232, 384828816, 671615496, 604244412, 705299458, 17367553 + ], + [ + 536870912, 268435456, 134217728, 201326592, 1040187392, 620756992, 796917760, 482344960, 526385152, 722468864, 310902784, 927203328, 832962560, 795803648, 856326144, 379305984, 88891392, 716615680, 635963392, 5506048, 355336704, 824902400, 321687424, 3459392, 111602656, 201160496, 759984088, 917946052, 333975202, 693373649 + ], + [ + 536870912, 268435456, 671088640, 335544320, 100663296, 50331648, 58720256, 465567744, 522190848, 691011584, 305659904, 766246912, 610664448, 1044709376, 401899520, 495796224, 885825536, 649408512, 602712064, 193278976, 534028800, 824783104, 1043506048, 397160896, 895886176, 953251632, 213025960, 452480380, 419440678, 43282967 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 436207616, 654311424, 192937984, 583008256, 27262976, 917504000, 623378432, 335282176, 876740608, 1073676288, 910458880, 217923584, 466493440, 320991232, 921053184, 215874560, 816062976, 673379072, 392209536, 555727552, 110003808, 642663024, 350268936, 266318812, 892241218, 201212963 + ], + [ + 536870912, 268435456, 671088640, 738197504, 503316480, 486539264, 729808896, 574619648, 652214272, 957349888, 159907840, 156499968, 1014366208, 786366464, 270958592, 1026670592, 784277504, 149975040, 470288384, 638845952, 420874752, 428804864, 558794624, 276154176, 817965792, 222001296, 381190584, 216713796, 772253794, 622508373 + ], + [ + 536870912, 805306368, 939524096, 469762048, 234881024, 486539264, 713031680, 977272832, 283115520, 1053818880, 129499136, 1017905152, 522584064, 636682240, 5537792, 402145280, 592879616, 409120768, 798132224, 1021004800, 481963520, 792131328, 501361536, 474676032, 435956896, 1045820816, 854499768, 365868020, 741641934, 577261051 + ], + [ + 536870912, 268435456, 134217728, 872415232, 973078528, 352321536, 964689920, 415236096, 694157312, 781189120, 407371776, 237240320, 69861376, 153419776, 213286912, 444252160, 471293952, 504705024, 654444544, 412156928, 458523136, 616287488, 1047260800, 773518656, 1057744480, 613085744, 356769880, 196014756, 317317778, 256638921 + ], + [ + 536870912, 268435456, 939524096, 603979776, 704643072, 16777216, 931135488, 331350016, 295698432, 762314752, 811073536, 7602176, 568197120, 615448576, 150568960, 110182400, 206774272, 510636032, 852666368, 909833216, 111642112, 100551936, 118137984, 277805376, 324636512, 987840688, 864757640, 702265004, 682404606, 1055260417 + ], + [ + 536870912, 805306368, 939524096, 201326592, 704643072, 1023410176, 494927872, 734003200, 517996544, 510656512, 405274624, 353632256, 427950080, 902758400, 99450880, 351617024, 325951488, 1033916416, 851945472, 763059200, 380118528, 4267776, 707267712, 336855104, 369230816, 789513904, 747473496, 474300972, 136685266, 486823977 + ], + [ + 536870912, 805306368, 939524096, 201326592, 771751936, 956301312, 276824064, 339738624, 228589568, 839909376, 521666560, 496762880, 650510336, 251068416, 372015104, 700465152, 460201984, 82628608, 85985280, 441453568, 79171072, 445383424, 123603840, 1043009088, 768246816, 23545104, 536519528, 44080260, 663760838, 232250215 + ], + [ + 536870912, 805306368, 402653184, 67108864, 771751936, 218103808, 159383552, 457179136, 782237696, 684720128, 1056440320, 519831552, 787087360, 921894912, 853573632, 485867520, 301604864, 409210880, 53118976, 764857344, 88253952, 1002295552, 625124224, 196992832, 1027779680, 264100816, 323137064, 45995124, 448964702, 436068143 + ], + [ + 536870912, 805306368, 402653184, 201326592, 301989888, 184549376, 629145600, 868220928, 929038336, 770703360, 363331584, 268697600, 672268288, 335740928, 504004608, 421412864, 781099008, 374378496, 78948352, 446143488, 944516608, 96132864, 939526784, 1006636480, 167775200, 117443888, 931135544, 952108364, 316670418, 506463117 + ], + [ + 536870912, 268435456, 671088640, 603979776, 301989888, 150994944, 192937984, 767557632, 757071872, 149946368, 299368448, 591134720, 536215552, 625147904, 510754816, 496451584, 650125312, 129626112, 179415040, 53392384, 267485696, 223825152, 979381888, 260700992, 801746528, 203603248, 662670248, 773342284, 119513534, 479310259 + ], + [ + 536870912, 268435456, 671088640, 872415232, 167772160, 218103808, 159383552, 180355072, 522190848, 315621376, 321388544, 79953920, 540147712, 172032000, 779386880, 371572736, 692183040, 150097920, 745834496, 1059439616, 46262784, 993156352, 819235456, 708167488, 122284128, 669409200, 485395784, 912311284, 438791338, 1061592705 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 33554432, 822083584, 796917760, 801112064, 98566144, 682622976, 1058537472, 614203392, 625606656, 1002373120, 831094784, 214384640, 863248384, 351997952, 388999168, 954160128, 494404096, 267127552, 900860544, 982713152, 106662752, 220481456, 232237720, 619925980, 791283390, 751765259 + ], + [ + 536870912, 268435456, 134217728, 738197504, 570425344, 788529152, 629145600, 46137344, 1033895936, 328204288, 1002962944, 824442880, 365297664, 741933056, 390299648, 661438464, 170156032, 642207744, 132515840, 778634240, 514556416, 68733696, 503998592, 84564928, 646676832, 88655024, 274885992, 197025764, 713395826, 928367497 + ], + [ + 536870912, 268435456, 402653184, 201326592, 704643072, 117440512, 75497472, 20971520, 597688320, 292552704, 1058537472, 411303936, 860487680, 682819584, 1072070656, 962183168, 1067900928, 594243584, 873621504, 906343424, 890768896, 260310784, 801770624, 636682944, 910592928, 791265680, 71231944, 984577036, 620261166, 264681085 + ], + [ + 536870912, 268435456, 671088640, 872415232, 838860800, 1056964608, 310378496, 759169024, 631242752, 1001390080, 985137152, 959184896, 1073086464, 680460288, 910196736, 757186560, 502489088, 1066643456, 282290176, 845394944, 122380800, 381663488, 119893632, 787265216, 51112480, 77495696, 139854664, 1010762620, 913868262, 223201591 + ], + [ + 536870912, 268435456, 671088640, 469762048, 637534208, 1056964608, 847249408, 943718400, 652214272, 447741952, 1045954560, 167510016, 2752512, 436535296, 152076288, 631029760, 383279104, 950259712, 55109632, 377426944, 267420160, 791462656, 8414080, 761256128, 627240224, 863638992, 878708504, 854592444, 817366446, 256642067 + ], + [ + 536870912, 268435456, 939524096, 469762048, 234881024, 956301312, 1015021568, 532676608, 1008730112, 393216000, 9961472, 30670848, 1026686976, 939065344, 289636352, 83279872, 382967808, 682684416, 748824576, 784282624, 565315072, 943260416, 358845824, 260491584, 407612576, 275052976, 756033576, 109458988, 215058734, 733988521 + ], + [ + 536870912, 805306368, 402653184, 738197504, 771751936, 922746880, 528482304, 314572800, 908066816, 581959680, 703070208, 235143168, 117571584, 126681088, 1054507008, 404963328, 363667456, 913682432, 482813952, 826063872, 624930304, 388167424, 371197312, 313526976, 837290592, 570688112, 687997416, 814547420, 559579154, 182669213 + ], + [ + 536870912, 268435456, 671088640, 872415232, 33554432, 1056964608, 377487360, 926941184, 157286400, 435159040, 733478912, 390856704, 426115072, 838795264, 532447232, 358203392, 644440064, 661344256, 686778368, 472142848, 1066131968, 214014208, 1069318784, 89769664, 241790752, 325803792, 720334712, 589582444, 688647958, 998348671 + ], + [ + 536870912, 805306368, 939524096, 469762048, 838860800, 520093696, 8388608, 683671552, 287309824, 730857472, 240648192, 821821440, 188612608, 546373632, 415989760, 691159040, 932405248, 1011224576, 803604480, 195890176, 139824640, 166938368, 44100736, 970479552, 213084192, 618010160, 725484104, 277938660, 550207766, 892488959 + ], + [ + 536870912, 268435456, 134217728, 469762048, 905969664, 318767104, 209715200, 432013312, 547356672, 1072693248, 865599488, 994836480, 1047134208, 969211904, 817528832, 939245568, 798793728, 223064064, 762062848, 893744128, 695339520, 390660864, 275812224, 1053737920, 373173920, 188510896, 280658696, 670813580, 664577742, 290174511 + ], + [ + 536870912, 268435456, 939524096, 67108864, 436207616, 922746880, 612368384, 1044381696, 367001600, 321912832, 915931136, 626262016, 394133504, 75431936, 720273408, 464371712, 785080320, 430886912, 232515584, 524030976, 10356224, 877593856, 452364416, 867814592, 315977632, 128045648, 550331480, 213245788, 441675486, 536533145 + ], + [ + 536870912, 805306368, 939524096, 469762048, 838860800, 385875968, 360710144, 432013312, 85983232, 944766976, 989331456, 1013710848, 774242304, 801964032, 203522048, 819052544, 1034444800, 118935552, 495421440, 1037880320, 724168192, 492246784, 947381376, 808851904, 852517728, 314236272, 243370952, 910278868, 804284766, 116054955 + ], + [ + 536870912, 268435456, 939524096, 201326592, 973078528, 150994944, 343932928, 54525952, 1021313024, 728760320, 498597888, 42205184, 542244864, 426180608, 816807936, 403423232, 471556096, 34574336, 85026816, 782013440, 173336064, 678713088, 674367616, 559351104, 704087456, 1040171408, 468804760, 283940940, 23913846, 749756077 + ], + [ + 536870912, 268435456, 134217728, 603979776, 838860800, 318767104, 159383552, 952107008, 85983232, 808452096, 12058624, 251396096, 747503616, 4653056, 795246592, 542523392, 1063264256, 675786752, 460859392, 441168896, 141437440, 331398400, 817800832, 384694720, 9831648, 374015984, 242257320, 987582460, 238071686, 363525443 + ], + [ + 536870912, 268435456, 671088640, 738197504, 838860800, 251658240, 461373440, 448790528, 807403520, 762314752, 228065280, 467402752, 1050804224, 255787008, 249987072, 323371008, 904568832, 786329600, 372123648, 342307840, 117572096, 663686912, 14583424, 321538240, 82881120, 407729520, 812819176, 151157228, 848047470, 945304235 + ], + [ + 536870912, 805306368, 939524096, 469762048, 771751936, 117440512, 293601280, 272629760, 140509184, 770703360, 128450560, 47448064, 195690496, 617938944, 681738240, 122699776, 301293568, 432001024, 1038051328, 103472128, 446555648, 667589376, 991989120, 101796544, 320725472, 462066384, 624985592, 820069036, 724953490, 236886233 + ], + [ + 536870912, 268435456, 402653184, 335544320, 503316480, 285212672, 494927872, 490733568, 564133888, 1049624576, 197656576, 913047552, 452591616, 171376640, 786202624, 635486208, 246915072, 570773504, 319948800, 512427008, 466519552, 778814720, 251209600, 338596928, 1070280544, 947229520, 334341736, 60972708, 763792242, 357026011 + ], + [ + 536870912, 268435456, 671088640, 872415232, 301989888, 452984832, 411041792, 884998144, 195035136, 827326464, 1055391744, 631504896, 474087424, 125108224, 653492224, 698826752, 307421184, 979505152, 930711552, 518407168, 900426240, 876895488, 863169664, 888279744, 850494496, 181552176, 245460072, 1019565972, 799761690, 189027993 + ], + [ + 536870912, 805306368, 134217728, 67108864, 704643072, 754974720, 226492416, 834666496, 908066816, 141557760, 378011648, 123469824, 23461888, 17235968, 328957952, 1054097408, 314318848, 505868288, 1013032960, 881179648, 776866304, 652938496, 500533376, 675236416, 124365280, 840546096, 285738728, 731644524, 851839530, 1018626763 + ], + [ + 536870912, 805306368, 402653184, 201326592, 369098752, 83886080, 629145600, 12582912, 291504128, 30408704, 116916224, 102498304, 756940800, 830930944, 449085440, 41533440, 559079424, 597848064, 398231552, 1034275840, 917300736, 439710464, 694160768, 1037045056, 150474592, 253494064, 513671640, 877068596, 774146270, 57262519 + ], + [ + 536870912, 268435456, 134217728, 201326592, 838860800, 486539264, 998244352, 46137344, 769654784, 416284672, 753401856, 424935424, 1059979264, 1026359296, 942702592, 129548288, 997580800, 965226496, 131106816, 308855808, 605938176, 773600000, 656311424, 714457920, 189099232, 842068912, 245723128, 920712564, 407728090, 1052045797 + ], + [ + 536870912, 268435456, 134217728, 469762048, 570425344, 956301312, 327155712, 524288000, 618659840, 240123904, 996671488, 991166464, 981860352, 81068032, 666009600, 145276928, 204152832, 333950976, 517638144, 448578560, 757932544, 343062272, 1065877632, 625216064, 166594272, 599851216, 1060405688, 897437140, 941206074, 68122901 + ], + [ + 536870912, 805306368, 134217728, 738197504, 503316480, 50331648, 847249408, 465567744, 597688320, 47185920, 272105472, 1049886720, 902692864, 682295296, 474447872, 367935488, 507011072, 93753344, 593463296, 23743488, 586048000, 649698048, 659427200, 57347264, 937922208, 993938928, 268463976, 939692148, 605126830, 838944085 + ], + [ + 536870912, 268435456, 671088640, 201326592, 704643072, 687865856, 293601280, 583008256, 136314880, 944766976, 241696768, 19136512, 970850304, 78184448, 85360640, 731103232, 600104960, 364793856, 813729792, 793691136, 686057984, 358650624, 229433984, 77225536, 559842912, 669503408, 133358216, 401823572, 1072170362, 870581945 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 167772160, 184549376, 142606336, 968884224, 622854144, 426770432, 337117184, 638320640, 152698880, 1067122688, 994082816, 400670720, 885563392, 883322880, 388638720, 912307200, 578816512, 583011072, 631242880, 481299904, 993525920, 880544944, 360844136, 542574636, 393907278, 822792159 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 973078528, 83886080, 494927872, 859832320, 778043392, 418381824, 1027080192, 647233536, 1037697024, 665780224, 558989312, 528039936, 459923456, 224808960, 711714816, 250434560, 439905792, 35592960, 687997056, 1066076736, 173248480, 166871696, 783966840, 248781740, 221350838, 780748617 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 436207616, 754974720, 511705088, 750780416, 622854144, 389021696, 372768768, 448528384, 660733952, 114229248, 271155200, 1035911168, 484745216, 143405056, 63219712, 582759424, 58501632, 683686656, 457092224, 339685440, 61811488, 536738672, 487162472, 110022332, 417116134, 53492755 + ], + [ + 536870912, 805306368, 939524096, 67108864, 704643072, 788529152, 260046848, 826277888, 174063616, 240123904, 234356736, 51118080, 697958400, 139001856, 83197952, 897761280, 374808576, 973008896, 286099456, 42912768, 768421376, 448262400, 813171328, 692848576, 1048186336, 475598160, 653101080, 647940180, 936714398, 229375123 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 234881024, 486539264, 545259520, 633339904, 1025507328, 1053818880, 347602944, 295436288, 591790080, 569049088, 291536896, 482295808, 93872128, 155504640, 251168768, 586370048, 82208256, 1039392512, 796789632, 431426368, 419860000, 579094128, 784395464, 1017616628, 898032910, 290230551 + ], + [ + 536870912, 805306368, 402653184, 67108864, 1040187392, 654311424, 612368384, 926941184, 882900992, 586153984, 566755328, 921960448, 937295872, 233111552, 693141504, 599506944, 510320640, 311980032, 1012033536, 841464832, 145657344, 686738688, 550660480, 828881088, 437161632, 689883152, 463102472, 399750252, 1039172314, 827048129 + ], + [ + 536870912, 805306368, 939524096, 872415232, 100663296, 184549376, 109051904, 675282944, 681574400, 426770432, 336068608, 906756096, 856555520, 848101376, 776044544, 597868544, 535928832, 1010962432, 514205696, 712530944, 645923328, 406848256, 278922112, 762315584, 302514272, 1024196784, 898498664, 449643140, 115442314, 986890647 + ], + [ + 536870912, 268435456, 939524096, 469762048, 503316480, 285212672, 780140544, 910163968, 799014912, 36700160, 373817344, 1067712512, 977141760, 172949504, 564363264, 725237760, 616865792, 401477632, 76654592, 653536256, 27492864, 993673472, 482648960, 200151488, 445753824, 938749200, 790855912, 226116196, 862232954, 165548515 + ], + [ + 536870912, 805306368, 134217728, 335544320, 503316480, 385875968, 427819008, 20971520, 572522496, 198180864, 505937920, 836501504, 522846208, 727252992, 434995200, 524075008, 698081280, 193236992, 608659456, 782263296, 236708352, 767857408, 401041536, 808478016, 739501024, 13144688, 258304280, 737502548, 150233538, 1065177805 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 704643072, 117440512, 645922816, 1010827264, 106954752, 934281216, 841482240, 500432896, 127008768, 351469568, 382500864, 673234944, 584458240, 890458112, 1052735488, 1034722304, 1041932800, 171151616, 317282944, 150982592, 751163552, 120524144, 945552104, 592993540, 1071546950, 747880907 + ], + [ + 536870912, 268435456, 134217728, 335544320, 100663296, 251658240, 260046848, 658505728, 899678208, 34603008, 578289664, 604766208, 503709696, 319225856, 495222784, 776093696, 891297792, 718942208, 815577088, 330427392, 1046878720, 359832832, 662700672, 591396928, 1000341728, 420479408, 737673368, 206307972, 606471074, 911671893 + ], + [ + 536870912, 268435456, 671088640, 469762048, 704643072, 83886080, 578813952, 272629760, 35651584, 238026752, 432537600, 1004797952, 635043840, 337575936, 871792640, 1009205248, 758226944, 1011585024, 271075328, 1060826112, 222593536, 78397696, 7676544, 686281152, 945646240, 199048272, 521791528, 175209476, 1038928034, 852929571 + ], + [ + 536870912, 268435456, 939524096, 201326592, 436207616, 16777216, 528482304, 121634816, 1054867456, 663748608, 445120512, 650379264, 380502016, 301137920, 1054769152, 460079104, 836624384, 65327104, 169752576, 684270592, 296092160, 762773760, 722502528, 659505344, 787177888, 530354192, 377870840, 1019933812, 396409326, 242575225 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 33554432, 452984832, 327155712, 171966464, 891289600, 686817280, 781713408, 197394432, 208273408, 710475776, 841449472, 159006720, 668737536, 292384768, 752179200, 719369216, 43448832, 566462208, 862815104, 131285184, 560177568, 886256240, 384006424, 9749780, 985931882, 552169771 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 369098752, 83886080, 343932928, 843055104, 861929472, 309329920, 26738688, 464257024, 308150272, 906821632, 353271808, 1015988224, 239820800, 627847168, 393283584, 353723392, 702835200, 557077760, 612098176, 346026688, 657255392, 471570320, 325059112, 40895092, 697827582, 665584067 + ], + [ + 536870912, 268435456, 671088640, 738197504, 436207616, 251658240, 679477248, 717225984, 996147200, 554696704, 329777152, 24379392, 70385664, 18284544, 60850176, 695648256, 674603008, 454619136, 212318208, 33428480, 49619456, 545140992, 767171200, 307422912, 58760096, 608642544, 749189640, 301864300, 720708246, 209596705 + ], + [ + 536870912, 268435456, 402653184, 603979776, 436207616, 318767104, 880803840, 759169024, 790626304, 445644800, 736624640, 762576896, 681443328, 350552064, 1072988160, 684965888, 105816064, 799739904, 903686144, 868701184, 426516992, 1027199232, 573639040, 549357120, 956115872, 240604208, 67379400, 168677780, 185535186, 277579481 + ], + [ + 536870912, 268435456, 939524096, 872415232, 369098752, 989855744, 427819008, 46137344, 794820608, 250609664, 347602944, 698089472, 104988672, 656867328, 920027136, 367935488, 834215936, 387846144, 118228992, 327635968, 599820800, 803345664, 951396736, 463029824, 323780832, 832913904, 999662456, 55267548, 161589774, 261097331 + ], + [ + 536870912, 268435456, 939524096, 872415232, 301989888, 1056964608, 411041792, 1044381696, 748683264, 972029952, 369623040, 84148224, 730726400, 13434880, 1071939584, 853524480, 155066368, 31690752, 1003563008, 79002624, 740295168, 598737152, 279446400, 938738496, 923140384, 76088304, 541753736, 899859428, 208839370, 264786847 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 234881024, 251658240, 243269632, 113246208, 526385152, 1020264448, 345505792, 490471424, 915275776, 583598080, 627998720, 31408128, 454811648, 444452864, 564905984, 128998400, 306924032, 883301632, 608053888, 319065792, 277742176, 29950512, 770605192, 874464092, 83616254, 795726673 + ], + [ + 536870912, 268435456, 402653184, 738197504, 436207616, 50331648, 981467136, 784334848, 123731968, 946864128, 879230976, 183762944, 783155200, 1000275968, 265846784, 913817600, 291643392, 829583360, 367851520, 851241984, 487203328, 126251264, 960690560, 639889088, 844276640, 473018672, 364960296, 31562796, 347495382, 470376119 + ], + [ + 536870912, 268435456, 134217728, 469762048, 369098752, 385875968, 343932928, 801112064, 731906048, 254803968, 808976384, 683409408, 427687936, 970522624, 879525888, 1016152064, 721969152, 311267328, 818313216, 589640704, 922647040, 211367168, 855669376, 109065408, 986512352, 572618160, 897358504, 936437580, 929357842, 572314559 + ], + [ + 536870912, 268435456, 671088640, 469762048, 301989888, 318767104, 947912704, 901775360, 379584512, 254803968, 933756928, 884211712, 316801024, 198377472, 427196416, 542097408, 585408512, 869576704, 762316800, 776141824, 602710528, 407941376, 540674688, 220593600, 980951840, 550268976, 589834504, 729714332, 592218698, 845823171 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 234881024, 687865856, 595591168, 935329792, 559939584, 1009778688, 42467328, 407633920, 816447488, 140443648, 322666496, 68042752, 705617920, 856223744, 948230144, 860277760, 471990784, 152240896, 672236160, 126960576, 374694112, 574010000, 864172600, 801259388, 896325654, 238734531 + ], + [ + 536870912, 805306368, 134217728, 738197504, 167772160, 1023410176, 142606336, 1069547520, 761266176, 485490688, 116916224, 66322432, 796262400, 918355968, 752844800, 94420992, 874176512, 625020928, 1001146368, 387871744, 1053575680, 401504000, 976505472, 85620160, 398608928, 828864016, 519948968, 402109932, 25110654, 766682147 + ], + [ + 536870912, 268435456, 671088640, 335544320, 704643072, 150994944, 478150656, 448790528, 748683264, 141557760, 620232704, 104595456, 378929152, 551747584, 655458304, 883933184, 612294656, 855330816, 825358336, 689185792, 799537664, 234300672, 179730560, 609805376, 407411232, 90420432, 425288680, 1053266300, 1051106082, 1031582971 + ], + [ + 536870912, 805306368, 134217728, 469762048, 1040187392, 956301312, 75497472, 1035993088, 18874368, 588251136, 263716864, 769916928, 180224000, 661454848, 108298240, 1053540352, 648306688, 156487680, 752777216, 831663104, 662444544, 508100352, 828957312, 326898368, 205790048, 1047330384, 855040424, 184619852, 998807770, 339950637 + ], + [ + 536870912, 268435456, 134217728, 603979776, 301989888, 956301312, 226492416, 440401920, 622854144, 592445440, 811073536, 953942016, 287178752, 561446912, 25395200, 1011204096, 102932480, 869675008, 899577856, 1052126208, 451312128, 674901248, 740326016, 919678784, 102628256, 737406160, 423943032, 632036724, 782106922, 305595201 + ], + [ + 536870912, 268435456, 402653184, 469762048, 1040187392, 419430400, 25165824, 264241152, 954204160, 544210944, 396886016, 450101248, 654180352, 283836416, 880640000, 766459904, 568123392, 7614464, 128129024, 47582208, 989291008, 786723072, 763132288, 740720064, 773134816, 949554320, 668787608, 359936060, 539171310, 135663191 + ], + [ + 536870912, 268435456, 402653184, 335544320, 973078528, 553648128, 25165824, 809500672, 673185792, 357564416, 522715136, 198443008, 770572288, 657522688, 458260480, 337723392, 861724672, 137318400, 89516032, 119636992, 534045184, 401297664, 104065408, 450135360, 610427296, 461312784, 494504344, 444569156, 217443106, 842106437 + ], + [ + 536870912, 805306368, 939524096, 872415232, 167772160, 50331648, 964689920, 272629760, 354418688, 479199232, 187170816, 630980608, 161873920, 944832512, 113541120, 853655552, 687005696, 202493952, 300787712, 561116160, 609411584, 818008832, 937798528, 746452800, 752673440, 772592432, 17246232, 915224132, 399148018, 208454393 + ], + [ + 536870912, 268435456, 671088640, 335544320, 570425344, 788529152, 411041792, 734003200, 568328192, 667942912, 994574336, 237240320, 205127680, 664600576, 266633216, 114671616, 314646528, 610496512, 328284160, 1038685184, 31359488, 508084480, 765829760, 494317888, 45095456, 291137264, 830978952, 105240508, 27337374, 57897533 + ], + [ + 536870912, 805306368, 939524096, 201326592, 704643072, 352321536, 679477248, 725614592, 589299712, 944766976, 198705152, 856948736, 419037184, 860422144, 522944512, 710066176, 316596224, 832253952, 649558016, 955198464, 204831232, 44183296, 429717888, 582873024, 652974880, 1060707984, 355172776, 257081380, 39772570, 383463585 + ], + [ + 536870912, 805306368, 134217728, 335544320, 905969664, 16777216, 679477248, 759169024, 320864256, 9437184, 829947904, 503578624, 621674496, 377946112, 944275456, 229490688, 752508928, 182022144, 870029312, 122874880, 136280576, 741695232, 85983872, 831521344, 301466592, 658768208, 3015144, 387384004, 565216186, 1055507165 + ], + [ + 536870912, 268435456, 134217728, 603979776, 570425344, 989855744, 394264576, 96468992, 538968064, 435159040, 609746944, 929824768, 244711424, 985858048, 94732288, 791953408, 939139072, 156241920, 837400576, 64263168, 715495936, 45581568, 624009856, 955994944, 886577824, 724551152, 377323864, 228082412, 290202618, 241374083 + ], + [ + 536870912, 268435456, 402653184, 335544320, 973078528, 654311424, 8388608, 297795584, 1042284544, 225443840, 749207552, 666107904, 604897280, 838926336, 721977344, 780976128, 214867968, 430813184, 473933824, 55520256, 350265856, 98349312, 958343552, 683142464, 947913120, 364905328, 471859592, 1047527516, 371720258, 292815527 + ], + [ + 536870912, 268435456, 134217728, 603979776, 301989888, 754974720, 578813952, 725614592, 778043392, 1018167296, 422051840, 1020526592, 916062208, 477429760, 1015709696, 541343744, 1005002752, 1014763520, 746911744, 675421184, 535667200, 779636992, 25417856, 181276224, 882989856, 1986512, 1027373224, 333929972, 142213446, 914686555 + ], + [ + 536870912, 268435456, 134217728, 738197504, 503316480, 654311424, 1048576000, 633339904, 895483904, 1032847360, 691535872, 63700992, 644218880, 957939712, 435453952, 824328192, 665870336, 1040699392, 923576320, 915307520, 164121088, 728493312, 445940352, 397558720, 638083424, 319541424, 76196360, 818379820, 853854910, 30780549 + ], + [ + 536870912, 268435456, 671088640, 738197504, 503316480, 889192448, 729808896, 549453824, 698351616, 357564416, 469237760, 506200064, 329121792, 56164352, 317751296, 61652992, 710057984, 528240640, 309303296, 443620352, 31799808, 1051806976, 441229440, 15029184, 524229472, 361618832, 97491288, 706813020, 429734050, 744311961 + ], + [ + 536870912, 805306368, 939524096, 67108864, 570425344, 486539264, 1065353216, 557842432, 413138944, 745537536, 734527488, 174850048, 194904064, 605618176, 224165888, 704462848, 595910656, 927191040, 531032064, 184171520, 386564608, 780681984, 13001600, 48730176, 878610976, 74755536, 666929656, 342732052, 815532042, 613477767 + ], + [ + 536870912, 268435456, 402653184, 201326592, 905969664, 452984832, 578813952, 666894336, 954204160, 953155584, 999817216, 935067648, 17432576, 528547840, 105414656, 833110016, 301195264, 548376576, 377186304, 719846400, 299493888, 538885376, 335186816, 296054208, 33030368, 950796400, 443678920, 485294860, 182092486, 43335745 + ], + [ + 536870912, 805306368, 402653184, 201326592, 436207616, 1056964608, 578813952, 935329792, 668991488, 540016640, 79167488, 1047789568, 269615104, 861995008, 50298880, 651444224, 117891072, 512102400, 902195200, 350299136, 414476800, 208676608, 991161216, 132147136, 272566816, 481522736, 846520328, 169284428, 207743094, 544302671 + ], + [ + 536870912, 805306368, 671088640, 603979776, 100663296, 989855744, 729808896, 893386752, 308281344, 1039138816, 1008205824, 144965632, 752222208, 9109504, 113541120, 723861504, 228401152, 1022242816, 607848448, 984810496, 191900160, 701904640, 739221632, 302018880, 352496352, 881358320, 416153816, 472843236, 68321566, 883835595 + ], + [ + 536870912, 805306368, 134217728, 67108864, 100663296, 184549376, 343932928, 415236096, 266338304, 1022361600, 756547584, 652476416, 360579072, 576389120, 558137344, 950878208, 928309248, 46895104, 1055557632, 695804928, 677276160, 675460864, 556589696, 807375680, 23890144, 355869936, 930933544, 525399612, 918717238, 820134147 + ], + [ + 536870912, 268435456, 939524096, 201326592, 637534208, 956301312, 645922816, 482344960, 253755392, 974127104, 1073217536, 466354176, 212467712, 509411328, 420642816, 779862016, 746971136, 331845632, 681605120, 207195136, 169286144, 401988864, 801800576, 648528320, 22536672, 110531408, 339277832, 1064259164, 653818010, 759533421 + ], + [ + 536870912, 268435456, 134217728, 738197504, 369098752, 486539264, 679477248, 79691776, 387973120, 747634688, 270008320, 920387584, 251527168, 769982464, 448299008, 168017920, 319283200, 294375424, 373463040, 417364992, 238852608, 281378048, 891558528, 60211136, 530316256, 294743568, 681533800, 974656092, 903707162, 393719189 + ], + [ + 536870912, 268435456, 939524096, 67108864, 436207616, 50331648, 562036736, 62914560, 509607936, 974127104, 875036672, 196345856, 911605760, 411893760, 827097088, 70238208, 599777280, 173977600, 109262848, 676074496, 648372736, 33321216, 401628032, 587031616, 645512096, 423548208, 1008599960, 958988668, 187859910, 320259025 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 234881024, 721420288, 763363328, 566231040, 559939584, 326107136, 941096960, 40108032, 721027072, 869335040, 973635584, 822296576, 747151360, 357535744, 136931328, 358425600, 104974848, 698529536, 579904384, 808161472, 424896864, 273425776, 1051281464, 17954732, 987759438, 363856875 + ], + [ + 536870912, 805306368, 134217728, 335544320, 637534208, 520093696, 696254464, 406847488, 6291456, 1051721728, 264765440, 724303872, 760348672, 71106560, 873299968, 369737728, 386752512, 1032491008, 1045321728, 526519296, 390038016, 394576640, 726196352, 334451008, 200358496, 522558960, 995383448, 322113156, 159384198, 675283371 + ], + [ + 536870912, 268435456, 671088640, 335544320, 301989888, 721420288, 209715200, 71303168, 991952896, 651165696, 930611200, 1022099456, 1061027840, 969342976, 484802560, 791953408, 298115072, 149073920, 1027545088, 986274816, 73792000, 964488448, 31940736, 582873152, 234912672, 1023979504, 495158248, 936330228, 568812026, 851309417 + ], + [ + 536870912, 268435456, 402653184, 335544320, 704643072, 251658240, 964689920, 549453824, 463470592, 395313152, 710410240, 58458112, 1068105728, 899088384, 693207040, 82853888, 980230144, 414355456, 662779904, 365132800, 891861504, 450837760, 993500032, 4631616, 1005396256, 1014141104, 237058232, 424902588, 217102978, 912473733 + ], + [ + 536870912, 268435456, 671088640, 335544320, 436207616, 1056964608, 629145600, 146800640, 379584512, 103809024, 673710080, 158597120, 893517824, 845217792, 916226048, 521322496, 567533568, 779874304, 1020250112, 481180672, 289006080, 430895360, 464603776, 485358912, 299795360, 376685296, 13590744, 313078220, 876357834, 52809619 + ], + [ + 536870912, 268435456, 671088640, 603979776, 905969664, 721420288, 427819008, 423624704, 39845888, 1072693248, 117964800, 461635584, 743047168, 350814208, 155025408, 925024256, 1066557440, 234115072, 168138752, 17595392, 143131136, 969146624, 531235456, 374932032, 978682720, 945210032, 223371672, 467227028, 756160550, 490192895 + ], + [ + 536870912, 268435456, 402653184, 738197504, 1040187392, 687865856, 729808896, 876609536, 287309824, 1047527424, 745013248, 349437952, 1046347776, 93782016, 720732160, 1051410432, 272392192, 508416000, 975464448, 452701184, 916578816, 607293696, 205916544, 757169856, 409995744, 694321040, 22776120, 589184132, 1060268402, 550022839 + ], + [ + 536870912, 805306368, 939524096, 872415232, 100663296, 754974720, 293601280, 356515840, 90177536, 158334976, 446169088, 941883392, 806486016, 434831360, 1034977280, 851230720, 3547136, 637186048, 374884352, 604103680, 235170304, 553932544, 596025728, 1044803648, 971926496, 230380944, 180102008, 875933828, 603638478, 995501699 + ], + [ + 536870912, 268435456, 134217728, 201326592, 167772160, 452984832, 276824064, 557842432, 933232640, 829423616, 795344896, 940834816, 377094144, 770637824, 106201088, 929021952, 752459776, 353505280, 267520000, 53455872, 104800768, 29806848, 250423424, 47807680, 404359840, 108768432, 635773832, 173659092, 1028762458, 936558183 + ], + [ + 536870912, 805306368, 402653184, 67108864, 369098752, 117440512, 629145600, 633339904, 1004535808, 800063488, 1060634624, 510918656, 986841088, 717422592, 846102528, 7553024, 299114496, 88100864, 44378112, 252838912, 959392256, 30738176, 759933824, 513886016, 488311520, 673535792, 592871608, 755450220, 8790278, 155406487 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 637534208, 1056964608, 964689920, 432013312, 836763648, 407896064, 692584448, 380370944, 1039269888, 53936128, 257785856, 482983936, 560947200, 252899328, 82655232, 13775872, 34046464, 486720256, 344514688, 88093632, 145611360, 922617840, 548952472, 261867164, 732248478, 427701573 + ], + [ + 536870912, 268435456, 939524096, 738197504, 234881024, 721420288, 964689920, 926941184, 10485760, 103809024, 587726848, 1032060928, 760086528, 162201600, 447971328, 113426432, 870998016, 479449088, 741550080, 34475008, 889717248, 713294080, 583926656, 971702976, 764641504, 481477296, 700605336, 275239796, 584394762, 806423651 + ], + [ + 536870912, 268435456, 671088640, 603979776, 436207616, 251658240, 109051904, 180355072, 1059061760, 923795456, 657981440, 111935488, 56492032, 517668864, 814972928, 108216320, 919429120, 958566400, 773535744, 280488960, 535714304, 1060732160, 447438976, 357929792, 802601760, 589278896, 87079880, 94940508, 1004354330, 17886365 + ], + [ + 536870912, 268435456, 402653184, 469762048, 503316480, 117440512, 511705088, 490733568, 547356672, 1051721728, 414711808, 331087872, 188350464, 226295808, 760905728, 162217984, 791994368, 528461824, 743806976, 204157952, 854956544, 630928640, 751672192, 929510592, 425171552, 61486256, 842341256, 83719524, 916191618, 676316815 + ], + [ + 536870912, 268435456, 134217728, 872415232, 33554432, 117440512, 511705088, 289406976, 492830720, 433061888, 870842368, 278134784, 311033856, 1061748736, 610435072, 912048128, 959389696, 87134208, 435877888, 424879104, 61153792, 511217920, 932739200, 470804288, 638190112, 218694000, 763527528, 231522900, 187113974, 439718381 + ], + [ + 536870912, 268435456, 134217728, 738197504, 100663296, 385875968, 914358272, 767557632, 429916160, 686817280, 565706752, 819724288, 34471936, 755826688, 797474816, 542064640, 82436096, 194187264, 644397056, 340993024, 181287424, 924935424, 557275776, 303118272, 153092832, 36700848, 110625672, 434897260, 1008075410, 572588323 + ], + [ + 536870912, 268435456, 134217728, 469762048, 369098752, 654311424, 713031680, 71303168, 673185792, 883949568, 139984896, 965476352, 885391360, 358940672, 219316224, 69484544, 985096192, 995209216, 419436544, 25469952, 818149888, 392451328, 538837632, 531169472, 863273440, 1035027376, 31318984, 357167668, 900298794, 310122255 + ], + [ + 536870912, 805306368, 671088640, 738197504, 369098752, 587202560, 343932928, 121634816, 895483904, 435159040, 314048512, 30670848, 321781760, 958201856, 697073664, 751452160, 413294592, 618082304, 1017391104, 786314240, 564701696, 894727936, 610977920, 611534272, 477553120, 679048176, 980437672, 594543748, 49676670, 842596571 + ], + [ + 536870912, 268435456, 402653184, 335544320, 771751936, 16777216, 595591168, 792723456, 429916160, 118489088, 189267968, 1067712512, 169213952, 315424768, 1072660480, 825638912, 420864000, 38555648, 270804992, 526001152, 611287552, 443957504, 917889408, 274485568, 384576224, 247342096, 341409848, 552289268, 464674842, 433983793 + ], + [ + 536870912, 805306368, 134217728, 738197504, 704643072, 687865856, 25165824, 1027604480, 954204160, 110100480, 732430336, 671350784, 470155264, 570490880, 84246528, 730152960, 340074496, 962605056, 1003988992, 323951616, 781505024, 933983488, 167772288, 419430592, 159383584, 289407152, 316670120, 797966500, 707264518, 356778229 + ], + [ + 536870912, 805306368, 134217728, 67108864, 570425344, 989855744, 427819008, 1027604480, 564133888, 854589440, 391643136, 317980672, 660471808, 452263936, 593395712, 955334656, 408543232, 561147904, 622741504, 14042112, 401085952, 395095808, 85870720, 819348672, 535303712, 327986960, 656295944, 198591532, 107484742, 785166309 + ], + [ + 536870912, 268435456, 402653184, 67108864, 905969664, 553648128, 830472192, 901775360, 773849088, 401604608, 680001536, 925106176, 846331904, 860553216, 1006927872, 570736640, 252125184, 344371200, 843085824, 987882496, 139775488, 180070656, 831463552, 312651840, 699562080, 946529296, 745557720, 508520836, 662700102, 79691927 + ], + [ + 536870912, 268435456, 134217728, 603979776, 100663296, 285212672, 243269632, 12582912, 106954752, 26214400, 284688384, 185860096, 104464384, 343212032, 758022144, 38649856, 827891712, 191238144, 890615808, 725376000, 821185024, 518775552, 498055296, 797531200, 331139616, 959849360, 974067864, 1056656388, 773026330, 113213331 + ], + [ + 536870912, 268435456, 671088640, 67108864, 234881024, 922746880, 394264576, 171966464, 60817408, 600834048, 978845696, 105119744, 430047232, 852819968, 517505024, 361086976, 658825216, 86503424, 219269120, 708424704, 460757504, 336575232, 660111488, 952483904, 459595936, 683143184, 988399672, 950908124, 789355102, 719239977 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 167772160, 352321536, 209715200, 767557632, 463470592, 458227712, 566755328, 720633856, 530448384, 532611072, 615350272, 293617664, 893394944, 409227264, 603052032, 689505280, 1064952320, 260662528, 756152448, 439178432, 624966240, 811885040, 133569192, 521875860, 545014482, 369718663 + ], + [ + 536870912, 268435456, 134217728, 872415232, 436207616, 822083584, 411041792, 994050048, 174063616, 30408704, 375914496, 755236864, 646053888, 406913024, 400982016, 940785664, 374218752, 1043795968, 175990784, 692866048, 498121216, 280661248, 887619712, 927203392, 1013055520, 382795984, 300843112, 633815236, 1042554978, 808587501 + ], + [ + 536870912, 268435456, 402653184, 872415232, 973078528, 721420288, 746586112, 205520896, 1059061760, 986710016, 815267840, 158597120, 369754112, 516882432, 296255488, 39469056, 756473856, 696078336, 1036134400, 719639552, 741499392, 179179264, 652134528, 223773760, 408472160, 370187216, 502942312, 92658668, 801385042, 1038273441 + ], + [ + 536870912, 268435456, 402653184, 603979776, 704643072, 419430400, 276824064, 390070272, 593494016, 279969792, 142082048, 343670784, 176029696, 561840128, 217677824, 557629440, 203415552, 793636864, 549918720, 531067904, 286745088, 846032128, 194470528, 741174592, 544695008, 266169808, 560947784, 303132084, 870933002, 810577385 + ], + [ + 536870912, 268435456, 671088640, 603979776, 301989888, 117440512, 562036736, 918552576, 127926272, 424673280, 171442176, 787742720, 728367104, 684261376, 865763328, 379666432, 1037262848, 847245312, 437581824, 291267584, 989864448, 797301504, 801609856, 388207680, 454351520, 500809616, 659012296, 157699932, 317932198, 627714827 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 771751936, 16777216, 645922816, 188743680, 622854144, 657457152, 182976512, 83623936, 1059454976, 607584256, 728399872, 339623936, 432267264, 744747008, 85407744, 912231424, 231842304, 347818752, 1065712256, 700921664, 342089760, 286519472, 610220056, 584289524, 859808290, 306203433 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 771751936, 654311424, 1031798784, 356515840, 543162368, 860880896, 322437120, 660340736, 235536384, 271908864, 1072594944, 270614528, 800104448, 732532736, 784496640, 639816704, 78851584, 2633984, 545492608, 365011392, 94500448, 250836272, 566941912, 681002156, 26957486, 741336377 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 436207616, 553648128, 998244352, 289406976, 773849088, 942669824, 35127296, 176422912, 46530560, 459472896, 806846464, 19611648, 303570944, 579170304, 650586112, 1029784576, 185845248, 464462592, 954073216, 501678272, 819036256, 122175728, 59744360, 334377092, 561973486, 915682373 + ], + [ + 536870912, 268435456, 134217728, 67108864, 234881024, 1056964608, 343932928, 616562688, 920649728, 691011584, 492306432, 383516672, 916324352, 750714880, 930054144, 218513408, 965058560, 222638080, 866166784, 513209344, 231346688, 605182208, 101454464, 242309440, 268276384, 734533968, 253211288, 344680876, 296925898, 597208383 + ], + [ + 536870912, 268435456, 671088640, 335544320, 637534208, 956301312, 830472192, 1010827264, 966787072, 1064304640, 434634752, 656670720, 867303424, 294453248, 800489472, 864993280, 414588928, 789491712, 863127552, 334009344, 69475840, 154342656, 55320704, 584560704, 949930144, 1003443280, 387366552, 25060836, 253675590, 781145265 + ], + [ + 536870912, 805306368, 939524096, 67108864, 838860800, 721420288, 729808896, 247463936, 262144000, 577765376, 232259584, 664535040, 259653632, 1064108032, 820346880, 68665344, 93102080, 468897792, 404326400, 1002126336, 667652608, 253139200, 504107648, 758143424, 331297376, 734546384, 18324136, 51012988, 531832838, 502796359 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 771751936, 318767104, 511705088, 482344960, 207618048, 529530880, 220725248, 520355840, 142737408, 465895424, 15171584, 1045807104, 214589440, 47697920, 352950272, 389057536, 450785792, 935159040, 463995008, 801374272, 48365728, 726991088, 1028620472, 781303884, 380133498, 440586355 + ], + [ + 536870912, 805306368, 939524096, 469762048, 167772160, 1056964608, 461373440, 322961408, 903872512, 84934656, 878182400, 977010688, 476708864, 634716160, 117080064, 617201664, 69672960, 87347200, 392853504, 542204928, 79484416, 598672640, 1022490240, 860804544, 358682208, 735474096, 536541256, 843949132, 803305126, 840046017 + ], + [ + 536870912, 268435456, 939524096, 201326592, 838860800, 318767104, 260046848, 79691776, 39845888, 456130560, 436731904, 422838272, 554303488, 582156288, 466321408, 30752768, 477749248, 278704128, 65894400, 684129280, 543497728, 808598784, 428701824, 804715584, 812457696, 906378544, 84375624, 444988428, 642162398, 673414435 + ], + [ + 536870912, 805306368, 671088640, 469762048, 234881024, 318767104, 645922816, 1002438656, 127926272, 829423616, 1048051712, 230424576, 639238144, 829358080, 1343488, 623460352, 737222656, 1002106880, 823724032, 770227200, 986952192, 420252928, 348598912, 522571200, 834015776, 56573360, 151984664, 214401532, 723822722, 599198739 + ], + [ + 536870912, 805306368, 134217728, 469762048, 973078528, 251658240, 729808896, 272629760, 241172480, 519045120, 26738688, 718536704, 638451712, 171769856, 989954048, 1031815168, 759390208, 920760320, 523544576, 280845312, 297838080, 690353920, 789989504, 690793664, 271543840, 917314416, 376194664, 97060860, 806879246, 93585649 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 436207616, 754974720, 411041792, 759169024, 870318080, 640679936, 761790464, 774635520, 114163712, 662372352, 785678336, 484163584, 260071424, 146829312, 774199296, 76735488, 582959616, 141762304, 487309952, 584638272, 1015259680, 860139440, 283179592, 900811524, 799881258, 84841649 + ], + [ + 536870912, 805306368, 402653184, 335544320, 637534208, 956301312, 696254464, 826277888, 400556032, 384827392, 717750272, 1029963776, 758513664, 921370624, 800489472, 19578880, 26222592, 217690112, 1024321536, 591748096, 954609152, 511037696, 638460032, 1036431552, 354773088, 592485456, 157191832, 110731748, 213608486, 1064279045 + ], + [ + 536870912, 268435456, 402653184, 67108864, 905969664, 251658240, 125829120, 88080384, 228589568, 344981504, 196608000, 994836480, 218497024, 914423808, 298024960, 1030111232, 628563968, 436801536, 648304640, 890444800, 435693056, 896492800, 718724736, 1067329856, 966263008, 1050411088, 622723256, 308084780, 654147782, 988495913 + ], + [ + 536870912, 268435456, 402653184, 738197504, 771751936, 553648128, 729808896, 524288000, 157286400, 1048576, 180879360, 663486464, 703463424, 394067968, 728793088, 366559232, 1069768704, 379785216, 112490496, 343806976, 536245760, 404602624, 778499712, 781516608, 604870368, 313257968, 69201496, 140835700, 999758070, 227345417 + ], + [ + 536870912, 268435456, 134217728, 335544320, 234881024, 385875968, 998244352, 96468992, 232783872, 646971392, 921174016, 13369344, 616431616, 323420160, 983662592, 171065344, 937009152, 378556416, 787425280, 483095552, 1052333568, 172323584, 371291776, 880239424, 1073741472, 1038108432, 1050116248, 719929420, 449716470, 1035538459 + ], + [ + 536870912, 805306368, 134217728, 201326592, 369098752, 654311424, 780140544, 121634816, 710934528, 781189120, 916979712, 915144704, 368705536, 117637120, 512131072, 256000000, 644325376, 949219328, 296343552, 403469312, 314209792, 761613056, 806573696, 971570112, 284110496, 761823216, 380109048, 109838444, 502923458, 184746161 + ], + [ + 536870912, 805306368, 939524096, 67108864, 503316480, 50331648, 981467136, 88080384, 52428800, 554696704, 314048512, 610009088, 371851264, 589627392, 286359552, 716980224, 543105024, 137293824, 539138048, 731257856, 804826624, 595144960, 691801728, 849248704, 264779360, 970337744, 6234136, 942600412, 404920434, 798366729 + ], + [ + 536870912, 805306368, 134217728, 469762048, 503316480, 184549376, 880803840, 113246208, 719323136, 877658112, 586678272, 174850048, 863109120, 953090048, 302415872, 755384320, 730046464, 809791488, 958760960, 557114368, 619529728, 79039744, 665734784, 487893440, 39364768, 102421680, 221867608, 822712668, 912261162, 512753911 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 771751936, 620756992, 444596224, 448790528, 400556032, 753926144, 554172416, 115081216, 230817792, 912326656, 833650688, 178929664, 151871488, 853405696, 667224064, 23536640, 540156416, 804216576, 514509440, 319802304, 1037598816, 172376112, 170352728, 311488612, 348096722, 510682367 + ], + [ + 536870912, 805306368, 939524096, 738197504, 905969664, 16777216, 176160768, 742391808, 736100352, 986710016, 36175872, 473694208, 850526208, 976814080, 1001816064, 616382464, 234217472, 945483776, 1017190400, 481514496, 658159104, 1060321024, 637480576, 445916096, 802093152, 535602288, 371142200, 1011098548, 602339442, 785425525 + ], + [ + 536870912, 805306368, 134217728, 872415232, 503316480, 553648128, 142606336, 138412032, 383778816, 667942912, 1006108672, 510918656, 793640960, 547160064, 526680064, 387235840, 760979456, 457199616, 761325568, 605481984, 651846144, 277048064, 71813248, 887520448, 752298528, 209508304, 1069007608, 963263300, 435003522, 363417649 + ], + [ + 536870912, 805306368, 671088640, 335544320, 771751936, 352321536, 109051904, 641728512, 513802240, 1034944512, 628621312, 270794752, 1073086464, 1037893632, 748060672, 839630848, 515612672, 188764160, 337774592, 167179264, 349709824, 269682432, 793616512, 329076928, 372541600, 163394640, 985892536, 870537044, 412592282, 739222617 + ], + [ + 536870912, 268435456, 402653184, 201326592, 905969664, 687865856, 528482304, 817889280, 966787072, 384827392, 198705152, 334757888, 844759040, 305594368, 410746880, 33669120, 50765824, 411447296, 172144640, 551683072, 915531264, 990756608, 1041938560, 332792896, 627828320, 868925232, 465123416, 723764452, 196560414, 163287027 + ], + [ + 536870912, 805306368, 671088640, 335544320, 838860800, 352321536, 226492416, 482344960, 853540864, 464519168, 285736960, 351535104, 338558976, 723582976, 1020559360, 712720384, 287055872, 1013837824, 914765824, 306605056, 748760576, 957488384, 454867072, 627846336, 889294496, 1031843152, 885039176, 652390548, 699668630, 67804195 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 771751936, 50331648, 780140544, 205520896, 312475648, 558891008, 620232704, 776732672, 952500224, 669319168, 879788032, 912932864, 399613952, 79671296, 720328704, 647126016, 60734976, 360469760, 847824512, 489158976, 110526560, 329203888, 762912856, 243921148, 857798658, 93645885 + ], + [ + 536870912, 805306368, 134217728, 872415232, 704643072, 385875968, 713031680, 826277888, 1033895936, 789577728, 943194112, 861143040, 1966080, 998572032, 717258752, 660881408, 7626752, 206049280, 353945600, 33612800, 319080960, 143078144, 306202752, 1025549504, 156674592, 790504400, 755367976, 92340380, 667320458, 317014037 + ], + [ + 536870912, 805306368, 939524096, 335544320, 503316480, 50331648, 528482304, 348127232, 480247808, 533725184, 609746944, 689700864, 108658688, 1015873536, 80183296, 346046464, 869670912, 777703424, 874432512, 452500480, 936117760, 211942656, 399607424, 140295616, 588785248, 460991888, 537579032, 260399516, 482836582, 815808719 + ], + [ + 536870912, 805306368, 134217728, 469762048, 503316480, 922746880, 998244352, 675282944, 819986432, 430964736, 333971456, 57933824, 936247296, 837091328, 959807488, 371900416, 819027968, 991604736, 620685312, 583592960, 325516800, 368443648, 688744576, 801320128, 916725280, 374829424, 769220856, 652128284, 861464782, 605678801 + ], + [ + 536870912, 805306368, 939524096, 738197504, 369098752, 486539264, 226492416, 281018368, 65011712, 617611264, 941096960, 239337472, 530972672, 343343104, 1055752192, 183418880, 15310848, 871149568, 258643968, 69876736, 168655360, 549409536, 749961344, 420331712, 742007008, 535916720, 992524376, 277826676, 251380278, 51584835 + ], + [ + 536870912, 805306368, 671088640, 67108864, 973078528, 352321536, 713031680, 188743680, 778043392, 124780544, 176685056, 653524992, 877527040, 340852736, 949911552, 109985792, 686825472, 860426240, 802310144, 593058816, 917333504, 727837952, 905201792, 768367808, 915793568, 473607440, 559736936, 1068371092, 401018378, 364224829 + ], + [ + 536870912, 805306368, 134217728, 469762048, 1040187392, 83886080, 109051904, 415236096, 929038336, 783286272, 608698368, 69468160, 731250688, 324599808, 549421056, 500023296, 90415104, 766791680, 869160960, 946211840, 1060398592, 151970048, 872554624, 302289088, 855930912, 528915568, 541466360, 715226388, 525581978, 305933731 + ], + [ + 536870912, 268435456, 402653184, 335544320, 1040187392, 822083584, 612368384, 339738624, 1012924416, 705691648, 601358336, 167510016, 210632704, 583335936, 589529088, 636895232, 470507520, 411136000, 910309376, 1063425024, 361940480, 471430400, 878323328, 708724032, 53182176, 527540496, 692944920, 409157844, 470867978, 517681349 + ], + [ + 536870912, 805306368, 402653184, 67108864, 973078528, 117440512, 595591168, 658505728, 887095296, 785383424, 778567680, 1025245184, 474087424, 426049536, 747864064, 974110720, 755736576, 646877184, 499750912, 388756480, 83723776, 236336896, 936132224, 942445504, 997949664, 391364816, 1042915464, 846958604, 298981478, 971519105 + ], + [ + 536870912, 268435456, 939524096, 872415232, 771751936, 218103808, 260046848, 968884224, 689963008, 45088768, 364380160, 1066139648, 393609216, 916258816, 641564672, 877477888, 290807808, 749457408, 650545152, 430111744, 469230080, 500893952, 23030400, 303625536, 24840288, 154123408, 335708760, 1040243172, 889315846, 998640019 + ], + [ + 536870912, 805306368, 134217728, 603979776, 503316480, 822083584, 880803840, 272629760, 320864256, 1001390080, 162004992, 390856704, 119144448, 73596928, 957579264, 14565376, 142958592, 306540544, 270776320, 70417408, 40688128, 296617728, 189282944, 890910656, 258433696, 579894096, 354345176, 1063727252, 714397834, 823659541 + ], + [ + 536870912, 268435456, 134217728, 872415232, 570425344, 150994944, 931135488, 247463936, 375390208, 74448896, 260571136, 1062469632, 559546368, 600637440, 376471552, 512704512, 886218752, 966668288, 514439168, 746953728, 675341824, 321144064, 181508224, 916057152, 170622496, 683715024, 627205640, 116524388, 550090878, 217423019 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 301989888, 553648128, 763363328, 423624704, 362807296, 420478976, 781713408, 581173248, 194379776, 828047360, 516128768, 568606720, 725032960, 868888576, 639461376, 140809216, 745771520, 225082112, 261038208, 4075712, 590571616, 667653360, 270406216, 123812740, 854949942, 414138533 + ], + [ + 536870912, 805306368, 671088640, 201326592, 369098752, 1056964608, 1048576000, 171966464, 958398464, 311427072, 752353280, 785645568, 452853760, 717291520, 812089344, 725073920, 118382592, 329846784, 335325184, 457700352, 748788224, 341114624, 985344128, 316683456, 796392096, 623505200, 632914136, 476495932, 221372506, 269144089 + ], + [ + 536870912, 268435456, 402653184, 201326592, 503316480, 721420288, 562036736, 809500672, 916455424, 649068544, 954728448, 373555200, 27394048, 20119552, 799637504, 526893056, 1012359168, 788475904, 790333440, 277550080, 227849728, 941337856, 654934144, 47693888, 1027563616, 83570736, 102336632, 470291628, 995440262, 24669633 + ], + [ + 536870912, 268435456, 134217728, 603979776, 838860800, 117440512, 528482304, 490733568, 916455424, 347078656, 145227776, 845938688, 630063104, 429850624, 344162304, 79806464, 383983616, 512872448, 752809984, 371354624, 712382976, 1028652800, 24877696, 319897408, 647707296, 922824656, 126280296, 826446796, 547749910, 565379257 + ], + [ + 536870912, 805306368, 402653184, 469762048, 771751936, 83886080, 75497472, 297795584, 945815552, 969932800, 789053440, 769392640, 726794240, 399310848, 658276352, 440680448, 706764800, 670085120, 586999808, 941904896, 1022756352, 997946112, 828567168, 995305408, 1070524640, 590959792, 675448536, 19084132, 644910634, 935237523 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 503316480, 553648128, 394264576, 1069547520, 849346560, 210763776, 501743616, 1043070976, 42860544, 387514368, 561414144, 1050230784, 800284672, 599298048, 551675904, 317914112, 861801984, 437527296, 631803520, 189621056, 12316256, 409334704, 598869528, 364580660, 98699334, 662056139 + ], + [ + 536870912, 268435456, 402653184, 872415232, 301989888, 855638016, 629145600, 549453824, 987758592, 9437184, 864550912, 417595392, 999424000, 973799424, 505577472, 544227328, 740122624, 686698496, 581982208, 771243008, 570237440, 402172160, 788357248, 209596480, 456677472, 840711376, 770646600, 1043573196, 801103894, 207515843 + ], + [ + 536870912, 805306368, 671088640, 603979776, 637534208, 989855744, 746586112, 532676608, 387973120, 938475520, 675807232, 278134784, 131989504, 768147456, 651591680, 348110848, 1012588544, 747622400, 456611840, 133141504, 916575744, 666187008, 2963584, 763528384, 306507424, 895725968, 714593816, 651703596, 273528978, 747652143 + ], + [ + 536870912, 268435456, 134217728, 469762048, 838860800, 452984832, 8388608, 37748736, 346030080, 66060288, 246939648, 281804800, 968228864, 505085952, 893288448, 34324480, 659693568, 357298176, 175151104, 125729792, 246077952, 816255232, 905200256, 868117824, 625875104, 309705776, 326695656, 548200732, 430234186, 779096357 + ], + [ + 536870912, 805306368, 671088640, 738197504, 234881024, 117440512, 125829120, 549453824, 44040192, 1007681536, 515375104, 925106176, 232128512, 412942336, 242319360, 940556288, 294248448, 105869312, 728422400, 465187840, 161755648, 93351680, 293593216, 503476416, 520312992, 58848432, 46387768, 195436316, 1016248478, 972719171 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 637534208, 989855744, 8388608, 390070272, 509607936, 999292928, 760741888, 58458112, 805961728, 579272704, 776241152, 400965632, 223617024, 972795904, 172595200, 795030528, 1041585664, 362517760, 282982016, 532309440, 296373792, 741728560, 15335608, 962003164, 335315002, 1061830721 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 167772160, 553648128, 125829120, 29360128, 262144000, 240123904, 133693440, 121896960, 434241536, 674562048, 974094336, 82657280, 945430528, 823390208, 169392128, 427176960, 149498368, 173829888, 68518016, 1000095808, 867672224, 566997232, 38606888, 227050628, 1026273822, 603564807 + ], + [ + 536870912, 268435456, 671088640, 603979776, 100663296, 922746880, 310378496, 851443712, 488636416, 34603008, 22544384, 58982400, 121765888, 358940672, 167018496, 409518080, 936042496, 387731456, 593844224, 116401152, 115933696, 655264512, 993656960, 82903104, 669941920, 713670800, 1065115672, 756125916, 266025034, 994358475 + ], + [ + 536870912, 268435456, 134217728, 469762048, 1040187392, 251658240, 847249408, 633339904, 249561088, 808452096, 525860864, 989593600, 267255808, 694616064, 309362688, 603799552, 1047109632, 136736768, 709888000, 296334336, 1002643968, 299897088, 179569280, 647766336, 169683616, 819897648, 79667288, 223178764, 586582034, 658502875 + ], + [ + 536870912, 805306368, 671088640, 872415232, 704643072, 251658240, 1015021568, 146800640, 836763648, 999292928, 910688256, 820248576, 974520320, 286064640, 725778432, 497238016, 515170304, 574164992, 406345728, 255712256, 801104384, 964579584, 765255808, 630001856, 663115936, 776264912, 505635496, 49549628, 790397042, 944390371 + ], + [ + 536870912, 268435456, 939524096, 201326592, 234881024, 1056964608, 142606336, 138412032, 375390208, 506462208, 271056896, 213647360, 243662848, 323289088, 619085824, 728776704, 1070473216, 759885824, 135141376, 535479296, 840534528, 982549248, 154743424, 390461248, 249954400, 779419760, 172916952, 478953676, 564666394, 394260701 + ], + [ + 536870912, 268435456, 939524096, 738197504, 1040187392, 285212672, 780140544, 482344960, 375390208, 309329920, 273154048, 252968960, 129630208, 370868224, 797671424, 150388736, 243965952, 242520064, 105510912, 168950784, 993633792, 635063552, 107698304, 683764800, 341991136, 91533744, 63667832, 55763204, 471475930, 1015582083 + ], + [ + 536870912, 268435456, 402653184, 201326592, 973078528, 553648128, 41943040, 155189248, 576716800, 340787200, 486014976, 104595456, 664666112, 216858624, 270827520, 95928320, 459923456, 1038528512, 764418048, 47846400, 76168704, 1031090432, 399031936, 773058880, 421256928, 934248816, 122070536, 627369460, 366305282, 977105105 + ], + [ + 536870912, 268435456, 671088640, 335544320, 33554432, 285212672, 461373440, 213909504, 698351616, 529530880, 915931136, 236716032, 811466752, 851116032, 508133376, 232898560, 544727040, 1072599040, 376834048, 1022344192, 888606208, 1068137728, 328273536, 412974400, 555650592, 752598288, 922676776, 833613140, 748062278, 740229479 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 100663296, 285212672, 8388608, 12582912, 979369984, 519045120, 444071936, 884736000, 735969280, 397213696, 638746624, 1062092800, 455237632, 752316416, 438953984, 811000832, 216947200, 53667072, 782031488, 529311040, 826718944, 707253680, 1011962616, 49033716, 909478138, 337417463 + ], + [ + 536870912, 805306368, 939524096, 469762048, 234881024, 218103808, 327155712, 994050048, 849346560, 131072000, 768081920, 257687552, 355598336, 708378624, 998277120, 793001984, 413622272, 416305152, 1028446208, 714906624, 257351168, 604711680, 591038080, 168032192, 788740192, 679775408, 969369304, 342026052, 53608694, 188284953 + ], + [ + 536870912, 805306368, 134217728, 738197504, 234881024, 452984832, 729808896, 4194304, 564133888, 11534336, 590872576, 645660672, 257556480, 2818048, 553025536, 849035264, 784998400, 6311936, 676386816, 883862528, 422648320, 243068160, 325032576, 103525824, 402111136, 387775856, 898359960, 172101916, 681990198, 909503517 + ], + [ + 536870912, 805306368, 134217728, 67108864, 33554432, 956301312, 1031798784, 700448768, 920649728, 688914432, 163053568, 268173312, 299499520, 1068171264, 818118656, 996655104, 148299776, 995643392, 619309056, 560034816, 232158720, 148795648, 842004096, 285389248, 159553184, 599859664, 199728808, 378733876, 427524190, 77316243 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 33554432, 285212672, 192937984, 197132288, 962592768, 743440384, 135790592, 26476544, 242876416, 222494720, 723877888, 938950656, 716021760, 740110336, 798316544, 628841472, 734032384, 694415104, 340842624, 874257472, 60150496, 528146416, 113737864, 551567364, 244457678, 117010655 + ], + [ + 536870912, 268435456, 402653184, 872415232, 1040187392, 620756992, 679477248, 784334848, 559939584, 206569472, 427294720, 99876864, 894042112, 509542400, 369131520, 419872768, 981540864, 29642752, 317110272, 789945344, 1046036992, 101112576, 17242240, 243731520, 1069996640, 937629648, 127066744, 278612948, 660602946, 223346731 + ], + [ + 536870912, 805306368, 402653184, 201326592, 234881024, 1023410176, 1065353216, 926941184, 719323136, 663748608, 948436992, 402391040, 199360512, 1041563648, 650805248, 10240000, 674521088, 788353024, 510105600, 777384960, 212651520, 483275520, 262092416, 1018599360, 389832928, 843141360, 694523992, 114357444, 594431686, 32404265 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 973078528, 285212672, 562036736, 171966464, 379584512, 844103680, 129499136, 954466304, 452067328, 183304192, 165380096, 584138752, 1014833152, 201502720, 33785856, 84063232, 663214592, 558026496, 640065664, 429125696, 459188384, 470811888, 790385384, 901020484, 734755334, 851984233 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 100663296, 117440512, 343932928, 817889280, 564133888, 17825792, 756547584, 532414464, 2752512, 351469568, 90734592, 638730240, 161062912, 662679552, 495577088, 333675520, 796028416, 757949696, 963890816, 305059264, 435168928, 418294064, 961726648, 176000044, 806004330, 77850927 + ], + [ + 536870912, 805306368, 671088640, 67108864, 570425344, 385875968, 310378496, 289406976, 996147200, 867172352, 285736960, 240386048, 167641088, 523829248, 10125312, 596328448, 789929984, 446533632, 680331264, 865147904, 987475456, 879645952, 350644352, 326470848, 598484640, 79956240, 547399176, 898779548, 1071203946, 434739605 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 838860800, 855638016, 947912704, 557842432, 1042284544, 70254592, 616038400, 1047789568, 371064832, 755171328, 830570496, 784416768, 702668800, 441536512, 355092480, 121426944, 330739200, 1064981248, 705939584, 680105152, 516509408, 644350960, 974651464, 386138124, 109445122, 407306357 + ], + [ + 536870912, 268435456, 402653184, 469762048, 234881024, 956301312, 461373440, 222298112, 383778816, 403701760, 175636480, 1072431104, 232128512, 693698560, 349995008, 882655232, 872144896, 229298176, 1035311104, 898569216, 838913536, 654832896, 981685888, 180478272, 363272416, 938890288, 166309464, 953443732, 618639062, 1016948113 + ], + [ + 536870912, 268435456, 671088640, 335544320, 33554432, 553648128, 1048576000, 37748736, 354418688, 972029952, 221773824, 280231936, 60424192, 1065418752, 750813184, 1063600128, 953589760, 919572480, 1015572480, 766211072, 1046246912, 107119360, 709945472, 176829504, 514381472, 165155664, 782368904, 1060438212, 123371610, 350503001 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 905969664, 721420288, 1031798784, 264241152, 119537664, 214958080, 676855808, 9699328, 666501120, 685834240, 469073920, 210485248, 349102080, 288321536, 610244608, 244569088, 415113728, 526438144, 154146944, 489231424, 710754976, 831553520, 792420440, 228897004, 412186710, 599565519 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 905969664, 654311424, 293601280, 138412032, 396361728, 625999872, 817364992, 392429568, 406192128, 160104448, 812351488, 228376576, 771088384, 141078528, 27215872, 66409472, 325696000, 639192832, 749756544, 357265600, 185542752, 195962096, 662606552, 595815324, 356577990, 254221281 + ], + [ + 536870912, 805306368, 134217728, 469762048, 1040187392, 184549376, 360710144, 960495616, 685768704, 617611264, 301465600, 283901952, 3276800, 858718208, 504791040, 660226048, 1062969344, 458903552, 827938816, 408671232, 953972224, 522169600, 456765056, 776812992, 864221344, 373392560, 392507096, 882145628, 429774894, 335451145 + ], + [ + 536870912, 805306368, 134217728, 738197504, 503316480, 352321536, 427819008, 851443712, 73400320, 116391936, 1012400128, 676593664, 718143488, 687669248, 432504832, 954515456, 632692736, 654143488, 885209088, 90643456, 628405760, 698146560, 1051891840, 310291648, 998354464, 29799344, 753211128, 531984276, 33521862, 641777851 + ], + [ + 536870912, 805306368, 134217728, 469762048, 704643072, 352321536, 109051904, 197132288, 425721856, 179306496, 297271296, 84672512, 129105920, 859766784, 818839552, 1037352960, 581632, 959770624, 754542592, 531149824, 140610048, 36735232, 830005888, 971521472, 1061251232, 597996720, 726895240, 869239076, 878076466, 273481147 + ], + [ + 536870912, 805306368, 134217728, 335544320, 771751936, 754974720, 830472192, 29360128, 392167424, 680525824, 171442176, 111411200, 133562368, 1051262976, 916357120, 39305216, 635084800, 946974720, 577337344, 411012096, 1057358336, 377851648, 994320512, 505835712, 565434400, 420363344, 49248952, 574227380, 581050950, 569638855 + ], + [ + 536870912, 805306368, 402653184, 335544320, 838860800, 989855744, 1031798784, 843055104, 341835776, 1060110336, 887619584, 854327296, 199884800, 359202816, 246120448, 445497344, 182099968, 1015353344, 147281920, 631493632, 68628992, 725298944, 234304128, 374026176, 897528544, 261566352, 947728936, 319958908, 12366558, 783740853 + ], + [ + 536870912, 268435456, 134217728, 738197504, 33554432, 822083584, 964689920, 163577856, 127926272, 458227712, 639107072, 188481536, 19791872, 416743424, 719224832, 320389120, 213770240, 871256064, 1005758464, 63454208, 174343680, 586255616, 105883264, 161799488, 945131168, 647963120, 394045608, 223296564, 891471566, 773147987 + ], + [ + 536870912, 268435456, 134217728, 67108864, 33554432, 83886080, 629145600, 826277888, 467664896, 904921088, 857210880, 633602048, 354549760, 374407168, 1049133056, 359415808, 949919744, 126070784, 608544768, 912440320, 11984384, 721040128, 355631232, 62472256, 47456288, 810479632, 919308296, 889801748, 925882006, 167395269 + ], + [ + 536870912, 805306368, 134217728, 335544320, 503316480, 419430400, 159383552, 524288000, 660602880, 632291328, 794296320, 460062720, 124911616, 964624384, 146767872, 270221312, 202104832, 717459456, 35952640, 232023040, 241895936, 1022846208, 1027445376, 895222208, 610867360, 200287376, 633301592, 933213492, 38464222, 271054297 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 436207616, 654311424, 276824064, 641728512, 1012924416, 791674880, 145227776, 949747712, 78774272, 342556672, 767459328, 996589568, 263495680, 116158464, 956176384, 830923776, 1002936832, 94415616, 428966528, 666521536, 73668640, 187819056, 111876808, 966617964, 691249834, 95223749 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 838860800, 721420288, 964689920, 457179136, 836763648, 212860928, 911736832, 837550080, 238157824, 1016922112, 1061715968, 1029947392, 527835136, 712953856, 544839680, 125596672, 352123392, 415073536, 584934016, 506327488, 538155232, 101545008, 260471464, 239289692, 157532846, 963698945 + ], + [ + 536870912, 805306368, 671088640, 201326592, 704643072, 889192448, 998244352, 775946240, 929038336, 347078656, 876085248, 58982400, 977666048, 962920448, 129073152, 280838144, 591568896, 417427456, 888195072, 274689024, 867423744, 784213760, 407240832, 811925696, 1043431584, 134037552, 94544040, 387018964, 203999470, 690711737 + ], + [ + 536870912, 805306368, 671088640, 335544320, 838860800, 385875968, 8388608, 406847488, 694157312, 600834048, 722993152, 994312192, 736493568, 76873728, 385515520, 852639744, 1050468352, 478220288, 239568896, 610692096, 542382592, 31142656, 492994688, 567689408, 337305760, 801378384, 27592904, 988818524, 900659714, 26157921 + ], + [ + 536870912, 805306368, 402653184, 872415232, 33554432, 150994944, 427819008, 322961408, 329252864, 812646400, 1011351552, 673447936, 439746560, 778764288, 1058177024, 937312256, 1061036032, 15708160, 584263680, 163107840, 690814464, 514851072, 380117120, 787787968, 965322848, 574788816, 237297160, 959754532, 317294822, 64103565 + ], + [ + 536870912, 805306368, 671088640, 872415232, 637534208, 687865856, 327155712, 373293056, 492830720, 590348288, 735576064, 454295552, 219021312, 825819136, 946110464, 985120768, 782147584, 787755008, 620570624, 726006784, 417619456, 880140032, 289343616, 140643520, 313644704, 446239696, 150273560, 234418020, 952541294, 245379145 + ], + [ + 536870912, 805306368, 134217728, 738197504, 838860800, 419430400, 41943040, 37748736, 878706688, 967835648, 866648064, 991166464, 188612608, 619511808, 267878400, 566837248, 228827136, 1024823296, 876357632, 694975488, 137588224, 1047302400, 431360128, 61713600, 856909344, 657997232, 384626248, 384946596, 592160938, 266681465 + ], + [ + 536870912, 268435456, 134217728, 738197504, 838860800, 553648128, 58720256, 180355072, 950009856, 158334976, 964165632, 209977344, 37879808, 887160832, 647331840, 292438016, 648552448, 932081664, 826169344, 761631744, 827452928, 273272576, 672792704, 131399744, 521109536, 763052208, 176660680, 893726852, 140638222, 1020568619 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 1040187392, 553648128, 1048576000, 4194304, 1067450368, 560988160, 127401984, 133955584, 938344448, 115539968, 609255424, 212680704, 482369536, 820391936, 693565440, 607104000, 25170432, 264571136, 694612608, 579959104, 659483168, 1484208, 151576792, 917991476, 720935074, 258645109 + ], + [ + 536870912, 805306368, 939524096, 201326592, 301989888, 486539264, 478150656, 809500672, 102760448, 219152384, 941096960, 48496640, 1064697856, 355401728, 887980032, 369639424, 427728896, 878120960, 213698560, 145990656, 214716928, 605584128, 417669248, 376459456, 397404384, 195884080, 296630856, 950849396, 976075506, 91197185 + ], + [ + 536870912, 268435456, 134217728, 872415232, 100663296, 285212672, 125829120, 146800640, 383778816, 753926144, 4718592, 800849920, 796262400, 378208256, 341540864, 905986048, 151117824, 998592512, 986163200, 31532032, 980783616, 252477184, 832191104, 358701888, 976332960, 1001006224, 919474744, 821837716, 961796742, 412617511 + ], + [ + 536870912, 268435456, 134217728, 738197504, 436207616, 419430400, 595591168, 88080384, 383778816, 68157440, 677904384, 569638912, 251265024, 190644224, 179011584, 341065728, 386768896, 833073152, 1073170432, 838847488, 601815552, 426658048, 1047718016, 431782976, 683389472, 926451120, 545100520, 60519716, 1041201710, 170330597 + ], + [ + 536870912, 268435456, 134217728, 738197504, 1040187392, 654311424, 159383552, 213909504, 866123776, 361758720, 629669888, 617349120, 430833664, 782172160, 469925888, 637616128, 50831360, 461869056, 365135872, 488782848, 282357248, 451538688, 49868416, 699903808, 803065504, 560037872, 288482904, 832099180, 562036862, 817889375 + ], + [ + 536870912, 805306368, 939524096, 603979776, 234881024, 1056964608, 243269632, 390070272, 60817408, 846200832, 1018691584, 722731008, 246284288, 943390720, 1029079040, 76070912, 931684352, 453939200, 558483456, 963625984, 601699840, 973253376, 956377216, 763794624, 868490976, 635453328, 5453496, 386509628, 55552090, 342512653 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 1040187392, 788529152, 645922816, 37748736, 127926272, 854589440, 448266240, 114556928, 831127552, 906952704, 902397952, 850051072, 129982464, 961646592, 508356608, 393118720, 333014528, 348134144, 232884352, 290722880, 709758560, 225402864, 1054609016, 591683580, 103255674, 842375097 + ], + [ + 536870912, 805306368, 671088640, 738197504, 301989888, 989855744, 159383552, 281018368, 207618048, 814743552, 1065877504, 774635520, 777650176, 956760064, 713457664, 490913792, 580952064, 368316416, 1033652224, 149332992, 483624448, 732786432, 480093824, 644333504, 1066618400, 537791344, 1005060200, 45875356, 735183054, 2818079 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 1040187392, 721420288, 1048576000, 1002438656, 924844032, 691011584, 385351680, 156499968, 1043202048, 3735552, 267747328, 945602560, 857989120, 858886144, 402184192, 517460992, 778849792, 425665280, 346077312, 192120000, 849016480, 998352880, 910282360, 644342636, 668293338, 502207711 + ], + [ + 536870912, 805306368, 402653184, 738197504, 973078528, 452984832, 998244352, 37748736, 685768704, 827326464, 105381888, 314310656, 281149440, 237305856, 779517952, 280674304, 398467072, 396496896, 456407040, 970511360, 1070626304, 42697472, 983232128, 129468352, 303857888, 980664432, 918331528, 784453852, 455120902, 418710629 + ], + [ + 536870912, 268435456, 939524096, 201326592, 771751936, 654311424, 847249408, 163577856, 320864256, 472907776, 860356608, 395575296, 196739072, 947585024, 1046446080, 569163776, 48521216, 320278528, 964597760, 265851904, 11259392, 486966528, 662763648, 172262464, 56809184, 441897264, 312301112, 424284636, 982595242, 70844759 + ], + [ + 536870912, 805306368, 134217728, 469762048, 234881024, 721420288, 293601280, 20971520, 962592768, 110100480, 606601216, 477364224, 922615808, 868024320, 551124992, 390774784, 468049920, 844591104, 101582848, 445004800, 549480960, 807784704, 603318400, 750537920, 325050912, 990719344, 67527352, 705162604, 822313702, 679517621 + ], + [ + 536870912, 268435456, 939524096, 201326592, 167772160, 989855744, 360710144, 398458880, 56623104, 376438784, 355991552, 1000603648, 378667008, 495910912, 259883008, 856113152, 830627840, 700723200, 1046624256, 855002112, 746528256, 981921536, 340254848, 497512512, 932337888, 185433136, 20489768, 765715436, 529571542, 1057926943 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 369098752, 922746880, 394264576, 406847488, 929038336, 26214400, 746061824, 850132992, 909508608, 961085440, 1046511616, 353845248, 297738240, 9408512, 910505984, 744621056, 403746304, 1060893952, 72160896, 417509696, 903125216, 354407600, 943470136, 466100524, 614932614, 682856701 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 167772160, 889192448, 1065353216, 985661440, 106954752, 258998272, 930611200, 452722688, 289275904, 920322048, 7110656, 838189056, 339697664, 828280832, 783206400, 26510336, 609200640, 211854592, 823241344, 738960704, 461711904, 885155248, 761547272, 871888228, 222167798, 752529807 + ], + [ + 536870912, 268435456, 939524096, 469762048, 167772160, 855638016, 796917760, 725614592, 262144000, 1007681536, 547880960, 308019200, 575012864, 992280576, 483688448, 306888704, 418062336, 578654208, 219256832, 136977408, 949990912, 597767936, 504467072, 934050624, 735871072, 805748784, 671424712, 604278972, 369301654, 956685409 + ], + [ + 536870912, 268435456, 134217728, 738197504, 973078528, 754974720, 830472192, 46137344, 765460480, 590348288, 58195968, 751042560, 245497856, 565248000, 188579840, 623067136, 511156224, 522137600, 684840960, 178844672, 1038927360, 344841984, 85819520, 366166080, 858759200, 321597616, 53205224, 187561140, 657147590, 489398027 + ], + [ + 536870912, 268435456, 671088640, 201326592, 301989888, 889192448, 243269632, 750780416, 165675008, 948961280, 816316416, 29097984, 911605760, 877592576, 329809920, 876462080, 454549504, 652865536, 312379392, 740803584, 368320000, 905932544, 678729344, 79407936, 14026784, 1015678064, 72089320, 732602340, 272375538, 85159719 + ], + [ + 536870912, 805306368, 939524096, 603979776, 1040187392, 587202560, 662700032, 390070272, 39845888, 80740352, 15204352, 1002700800, 514195456, 871825408, 1063026688, 91996160, 911106048, 607252480, 67069952, 260574208, 865450496, 848186624, 118653056, 977846464, 909435104, 50147472, 286099704, 508705932, 590131870, 828617053 + ], + [ + 536870912, 268435456, 939524096, 872415232, 234881024, 922746880, 461373440, 1027604480, 702545920, 70254592, 592969728, 354680832, 965869568, 437190656, 545947648, 357548032, 745529344, 1073541120, 619833344, 486120448, 561075712, 784012032, 655843456, 432812096, 447514848, 324971728, 1025859128, 898990044, 537878254, 428769205 + ], + [ + 536870912, 268435456, 939524096, 335544320, 301989888, 855638016, 595591168, 171966464, 1054867456, 87031808, 430440448, 564396032, 693239808, 1046413312, 992903168, 727990272, 108224512, 466219008, 190154752, 626654208, 883537408, 656575744, 429252736, 242856000, 993847520, 811273296, 640204360, 98841036, 447985166, 770280809 + ], + [ + 536870912, 805306368, 134217728, 469762048, 234881024, 822083584, 562036736, 566231040, 534773760, 254803968, 996671488, 316932096, 280363008, 598278144, 814186496, 810008576, 908533760, 215461888, 979236864, 411687936, 601347584, 316429568, 214900864, 267628736, 1024194592, 672193648, 641226296, 25138628, 199098374, 21823559 + ], + [ + 536870912, 805306368, 402653184, 201326592, 570425344, 16777216, 763363328, 88080384, 1021313024, 449839104, 745013248, 1029963776, 227934208, 160104448, 104169472, 112869376, 151986176, 1022767104, 639232000, 247020544, 755575296, 183518464, 152641664, 4010176, 80504928, 517176368, 711854728, 174224644, 253151286, 38735061 + ], + [ + 536870912, 805306368, 671088640, 201326592, 503316480, 385875968, 713031680, 440401920, 2097152, 737148928, 16252928, 157024256, 409600000, 804716544, 586842112, 677068800, 703242240, 20148224, 798914560, 688741376, 413438464, 145888512, 358363776, 510289344, 485673504, 444299760, 991852632, 340614316, 436507250, 889328901 + ], + [ + 536870912, 805306368, 402653184, 603979776, 369098752, 822083584, 864026624, 406847488, 618659840, 644874240, 81264640, 818675712, 128057344, 34930688, 913276928, 775045120, 138076160, 717180928, 830208000, 366760960, 860615168, 132474112, 49343104, 102719936, 468541664, 191959120, 895162424, 394921044, 96832150, 430076325 + ], + [ + 536870912, 268435456, 671088640, 335544320, 100663296, 822083584, 125829120, 742391808, 874512384, 760217600, 112721920, 218890240, 1023803392, 763822080, 658997248, 279068672, 831971328, 677302272, 1069119488, 244124672, 1061170688, 1017183488, 194393728, 190472512, 255328288, 340525072, 547750072, 160891028, 341803014, 767443061 + ], + [ + 536870912, 805306368, 402653184, 738197504, 570425344, 553648128, 578813952, 952107008, 794820608, 927989760, 1027080192, 852754432, 545128448, 821493760, 218857472, 213598208, 563322880, 559747072, 503429120, 721845248, 931303936, 340245248, 346536064, 464878784, 271520352, 407894960, 177838088, 450899012, 839944938, 320657235 + ], + [ + 536870912, 268435456, 939524096, 872415232, 838860800, 721420288, 612368384, 624951296, 782237696, 831520768, 491257856, 287047680, 699793408, 849149952, 1047887872, 410697728, 448798720, 124088320, 913405952, 75144192, 616904192, 711348992, 200789632, 784011072, 195516512, 269675664, 160026152, 326766460, 776263898, 438643833 + ], + [ + 536870912, 805306368, 134217728, 738197504, 167772160, 922746880, 813694976, 994050048, 90177536, 13631488, 554172416, 29097984, 870449152, 915865600, 736919552, 648593408, 651010048, 94105600, 156760064, 197919744, 975148544, 647105280, 334352000, 44695488, 13607072, 949809264, 248739848, 574572, 70792938, 589495089 + ], + [ + 536870912, 268435456, 939524096, 335544320, 167772160, 754974720, 41943040, 29360128, 463470592, 938475520, 462946304, 775159808, 70909952, 734199808, 648052736, 225853440, 241115136, 1066733568, 516921344, 853025792, 156386816, 317474560, 309270656, 44983360, 1032677088, 951670608, 486572200, 713441524, 768024810, 94441559 + ], + [ + 536870912, 805306368, 671088640, 469762048, 570425344, 754974720, 696254464, 583008256, 371195904, 581959680, 108527616, 146014208, 125698048, 724631552, 347963392, 915750912, 969416704, 256405504, 822638592, 409777152, 809053696, 232258304, 623409280, 668775616, 935407264, 1000602480, 376862728, 56472692, 210021894, 658684923 + ], + [ + 536870912, 268435456, 671088640, 201326592, 33554432, 587202560, 864026624, 339738624, 308281344, 1028653056, 968359936, 149159936, 630325248, 639434752, 479559680, 43663360, 492134400, 700313600, 551798784, 697674752, 605854208, 1066688256, 824139904, 152367168, 1004292256, 498527280, 271481352, 754904972, 436488270, 386067473 + ], + [ + 536870912, 805306368, 671088640, 872415232, 637534208, 352321536, 1065353216, 163577856, 954204160, 699400192, 821559296, 519307264, 677249024, 996212736, 40927232, 320454656, 700456960, 149237760, 28743680, 83782656, 955567616, 1029546752, 81795200, 196259008, 737832608, 7361488, 941498392, 524562580, 749082718, 60271863 + ], + [ + 536870912, 268435456, 402653184, 335544320, 905969664, 218103808, 25165824, 524288000, 853540864, 1064304640, 992477184, 336330752, 241041408, 136642560, 752058368, 935280640, 869392384, 87904256, 739604480, 186450944, 96705024, 824702720, 190315136, 1039984448, 347529952, 319484688, 685531192, 568791076, 804722878, 535761945 + ], + [ + 536870912, 805306368, 134217728, 201326592, 33554432, 419430400, 964689920, 163577856, 576716800, 131072000, 214433792, 815005696, 1039007744, 946143232, 718766080, 860438528, 777428992, 1024028672, 385292288, 876411904, 799834624, 986019072, 1055299712, 1033157824, 845914656, 782517552, 641114248, 534343844, 700389574, 409533463 + ], + [ + 536870912, 805306368, 402653184, 738197504, 301989888, 117440512, 830472192, 281018368, 568328192, 63963136, 936902656, 577503232, 262275072, 125108224, 590249984, 243515392, 1027907584, 992333824, 154249216, 395076608, 40936960, 1034858752, 466071168, 845284800, 202383584, 197070960, 595167272, 513766572, 390803086, 194299231 + ], + [ + 536870912, 805306368, 134217728, 67108864, 234881024, 150994944, 729808896, 1010827264, 52428800, 227540992, 109576192, 670302208, 297664512, 464322560, 459440128, 817283072, 169385984, 251146240, 67987456, 3617792, 652003840, 287014144, 511658112, 416138432, 399966752, 950630672, 132410040, 645090788, 452599822, 839839777 + ], + [ + 536870912, 268435456, 939524096, 335544320, 100663296, 318767104, 1031798784, 272629760, 815792128, 806354944, 434634752, 400818176, 322043904, 113180672, 288260096, 830914560, 306667520, 497168384, 177227776, 841790464, 604492288, 772048128, 1057087616, 796979264, 88418528, 505513040, 500242968, 957018444, 391336566, 986268929 + ], + [ + 536870912, 268435456, 671088640, 738197504, 1040187392, 620756992, 427819008, 163577856, 115343360, 674234368, 438829056, 927727616, 498991104, 368246784, 919240704, 8077312, 688971776, 704598016, 416425984, 723162112, 585531904, 708218624, 690512512, 667606848, 871942688, 1071057904, 26781912, 1000461412, 43409982, 725212931 + ], + [ + 536870912, 268435456, 939524096, 469762048, 503316480, 721420288, 545259520, 499122176, 975175680, 1003487232, 264765440, 1039400960, 974782464, 557514752, 997031936, 417513472, 192143360, 953896960, 26908672, 880538624, 948744704, 454268160, 174684288, 23110720, 993405664, 146301296, 590203640, 210186732, 734352098, 891536711 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 503316480, 385875968, 142606336, 826277888, 425721856, 363855872, 756547584, 761528320, 665976832, 203227136, 249790464, 7454720, 859824128, 179474432, 161474560, 706792448, 366355968, 254626560, 96460928, 1022529600, 813688992, 852544752, 1068377720, 553208668, 127262882, 751538309 + ], + [ + 536870912, 268435456, 402653184, 67108864, 570425344, 989855744, 243269632, 759169024, 782237696, 661651456, 80216064, 72613888, 343539712, 964624384, 654213120, 574177280, 156950528, 885526528, 206768128, 142517248, 528233984, 1073517824, 398190720, 714978368, 925613664, 92565776, 734248456, 534802860, 802275034, 985362917 + ], + [ + 536870912, 805306368, 939524096, 603979776, 503316480, 352321536, 947912704, 46137344, 983564288, 550502400, 292028416, 827588608, 556662784, 976420864, 853180416, 801685504, 1065623552, 491114496, 400652288, 255263744, 979182080, 353159424, 556234880, 596640960, 327787232, 115804560, 431085816, 362353812, 858454530, 489872795 + ], + [ + 536870912, 805306368, 939524096, 603979776, 1040187392, 587202560, 276824064, 1010827264, 106954752, 328204288, 307757056, 304873472, 136445952, 619773952, 273383424, 364331008, 766353408, 921006080, 534190080, 742360064, 633232896, 612362496, 366929536, 149429696, 218505312, 998387792, 818067480, 539423772, 150161082, 843935101 + ], + [ + 536870912, 268435456, 939524096, 67108864, 503316480, 956301312, 880803840, 843055104, 824180736, 326107136, 728236032, 548667392, 780795904, 732102656, 808615936, 315408384, 461611008, 331829248, 367421440, 856699904, 448783872, 661154048, 313976960, 898364480, 1009043168, 301005072, 472490232, 1058295972, 683468850, 1013511385 + ], + [ + 536870912, 268435456, 939524096, 201326592, 838860800, 721420288, 796917760, 901775360, 652214272, 17825792, 396886016, 97255424, 916324352, 101777408, 439123968, 588038144, 872194048, 13094912, 6465536, 139940864, 654894592, 637328128, 767706752, 988154688, 185757280, 816619376, 407546024, 677074140, 259450518, 788388683 + ], + [ + 536870912, 805306368, 402653184, 201326592, 973078528, 50331648, 343932928, 423624704, 509607936, 164626432, 553123840, 729546752, 884604928, 614006784, 296255488, 415744000, 446930944, 24588288, 915347456, 1064391680, 730672640, 116412672, 323956352, 743788992, 171814624, 383488496, 256806408, 1045914108, 490223194, 878183833 + ], + [ + 536870912, 268435456, 402653184, 738197504, 167772160, 889192448, 209715200, 62914560, 618659840, 313524224, 491257856, 697565184, 689569792, 661585920, 927170560, 455098368, 609230848, 385699840, 844863488, 911059968, 639024640, 22793472, 365443200, 72399936, 117245536, 710619568, 441261736, 739433876, 878280914, 424624383 + ], + [ + 536870912, 805306368, 939524096, 469762048, 704643072, 318767104, 1031798784, 683671552, 572522496, 519045120, 861405184, 1065091072, 881459200, 995426304, 510296064, 931512320, 197304320, 665292800, 708003840, 997960704, 848093696, 978600192, 753812096, 147050944, 304417376, 653557168, 794552520, 360267004, 663562942, 114699679 + ], + [ + 536870912, 268435456, 134217728, 335544320, 704643072, 419430400, 1065353216, 708837376, 996147200, 386924544, 271056896, 875298816, 103677952, 53411840, 44924928, 468238336, 101441536, 81530880, 97605632, 495596544, 480171520, 1001902848, 186570368, 368563008, 310302368, 266851088, 399955464, 143381364, 353949430, 922014685 + ], + [ + 536870912, 805306368, 939524096, 469762048, 33554432, 822083584, 209715200, 138412032, 119537664, 1045430272, 45613056, 362545152, 600440832, 91553792, 250249216, 505462784, 651419648, 754511872, 1035548672, 572144640, 839714304, 412117248, 215934592, 409508288, 191356512, 393389488, 938137704, 916638836, 815021786, 416961941 + ], + [ + 536870912, 268435456, 671088640, 469762048, 369098752, 889192448, 192937984, 239075328, 421527552, 529530880, 1042808832, 467402752, 214302720, 451346432, 368476160, 790183936, 572547072, 85315584, 435009536, 868051968, 586421760, 194877184, 753356416, 821062464, 211320864, 811745328, 170975480, 863735972, 101931126, 929955053 + ], + [ + 536870912, 268435456, 671088640, 67108864, 838860800, 855638016, 595591168, 876609536, 1050673152, 521142272, 631767040, 926679040, 467009536, 483328000, 180977664, 466141184, 592125952, 814321664, 141506560, 450558976, 65267200, 624037632, 930799232, 796390208, 483964960, 987839568, 431441512, 381444060, 613893830, 770465629 + ], + [ + 536870912, 268435456, 671088640, 201326592, 637534208, 419430400, 897581056, 641728512, 2097152, 829423616, 211288064, 557580288, 34471936, 213057536, 805208064, 736903168, 211836928, 850808832, 50190336, 476789760, 434307584, 940910848, 961372800, 51411264, 802044448, 131532144, 690837688, 54819860, 732291822, 708000205 + ], + [ + 536870912, 268435456, 671088640, 469762048, 838860800, 117440512, 343932928, 926941184, 1050673152, 768606208, 697827328, 793509888, 408289280, 861863936, 791314432, 870563840, 410099712, 181202944, 714455040, 792566784, 916004352, 533295360, 689219200, 620293440, 595310624, 1052679216, 710778472, 917090668, 589399578, 722787713 + ], + [ + 536870912, 805306368, 134217728, 603979776, 570425344, 788529152, 125829120, 826277888, 295698432, 976224256, 988282880, 619446272, 904527872, 325779456, 212828160, 650887168, 345907200, 858181632, 938801152, 931712000, 893028864, 18306816, 689605248, 828856256, 802327200, 368793424, 351308328, 101472236, 24971830, 472946473 + ], + [ + 536870912, 805306368, 671088640, 872415232, 436207616, 822083584, 998244352, 432013312, 111149056, 93323264, 1055391744, 874250240, 297926656, 44236800, 932413440, 1005436928, 362373120, 956518400, 1065830400, 734030848, 61187584, 605163264, 371723904, 154989504, 227770400, 988659728, 102326472, 348344340, 589777030, 525364387 + ], + [ + 536870912, 805306368, 671088640, 67108864, 838860800, 520093696, 847249408, 767557632, 882900992, 791674880, 410517504, 353107968, 563216384, 474677248, 636583936, 39370752, 167550976, 609169408, 972204032, 475745280, 553312768, 1003254016, 968084096, 934870464, 380504096, 941915344, 468732520, 458964332, 1048258690, 537889803 + ], + [ + 536870912, 805306368, 939524096, 469762048, 301989888, 218103808, 528482304, 549453824, 752877568, 691011584, 148373504, 10223616, 171573248, 112001024, 677806080, 628146176, 1014980608, 722440192, 712378368, 653972480, 810537472, 676755712, 1009472128, 52935104, 525382240, 984213936, 174414376, 275869060, 1073569878, 432967687 + ], + [ + 536870912, 268435456, 134217728, 469762048, 503316480, 318767104, 528482304, 926941184, 828375040, 630194176, 78118912, 914096128, 330694656, 140181504, 54951936, 593641472, 546349056, 338300928, 12244992, 110404608, 53112320, 356273920, 550909568, 550153024, 191690912, 1037890608, 889198168, 142801724, 583434374, 388120785 + ], + [ + 536870912, 805306368, 939524096, 201326592, 838860800, 721420288, 1065353216, 364904448, 908066816, 907018240, 445120512, 436469760, 788922368, 965148672, 12681216, 279330816, 928342016, 116387840, 267827200, 901301248, 253608448, 793301248, 471859328, 554696896, 789053664, 683933744, 346423496, 827785388, 334070014, 695353431 + ], + [ + 536870912, 268435456, 134217728, 872415232, 838860800, 50331648, 1048576000, 373293056, 681574400, 986710016, 144179200, 285999104, 649461760, 447414272, 853770240, 208846848, 1062150144, 571813888, 779704320, 1065008128, 318578176, 842907904, 954189440, 413777216, 702806176, 251022480, 789112552, 1001426396, 690790578, 522711061 + ], + [ + 536870912, 268435456, 671088640, 469762048, 771751936, 520093696, 41943040, 20971520, 551550976, 516947968, 586678272, 937164800, 867041280, 937623552, 273973248, 633028608, 339320832, 33058816, 190355456, 99410944, 159559168, 566311168, 950111872, 1068566848, 300693024, 729996592, 952213656, 958689356, 309762066, 793764873 + ], + [ + 536870912, 268435456, 402653184, 67108864, 301989888, 251658240, 1031798784, 381681664, 715128832, 466616320, 845676544, 173801472, 411435008, 809566208, 199458816, 749912064, 748396544, 975327232, 932669440, 797740032, 1005235712, 110720768, 556000896, 1338176, 843972832, 1053622352, 76382248, 74432556, 123609278, 838963303 + ], + [ + 536870912, 805306368, 671088640, 335544320, 369098752, 385875968, 360710144, 289406976, 23068672, 588251136, 43515904, 1054605312, 658112512, 1039073280, 802521088, 918241280, 581672960, 95555584, 36419584, 812766208, 948606464, 46601472, 522655360, 200299968, 852407840, 1008813456, 947031672, 478728652, 1019492398, 472224905 + ], + [ + 536870912, 268435456, 134217728, 738197504, 838860800, 687865856, 847249408, 826277888, 425721856, 825229312, 798490624, 154402816, 463077376, 523567104, 748650496, 917716992, 106602496, 739577856, 525109248, 735984640, 148286976, 384683776, 88901760, 1054751808, 5680672, 581816240, 481069128, 397294820, 70168298, 736743285 + ], + [ + 536870912, 268435456, 671088640, 335544320, 1040187392, 251658240, 964689920, 859832320, 631242752, 30408704, 631767040, 746323968, 232128512, 934215680, 561741824, 290668544, 208216064, 18698240, 1071781888, 1056177152, 750640640, 976525056, 224380544, 466053952, 811735072, 112458768, 647880280, 329553772, 181913246, 170617777 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 637534208, 150994944, 461373440, 792723456, 710934528, 881852416, 153616384, 22806528, 36044800, 946929664, 192708608, 509034496, 688906240, 976048128, 635377664, 669082624, 450133504, 483165952, 9078400, 242070336, 523985120, 884347056, 576649464, 1050752212, 565307126, 266052505 + ], + [ + 536870912, 268435456, 134217728, 603979776, 100663296, 654311424, 796917760, 289406976, 484442112, 279969792, 765984768, 416546816, 970588160, 903675904, 131760128, 786415616, 39804928, 983478272, 272467968, 870960128, 531787264, 908742912, 126937216, 641629248, 217015840, 472997264, 91186840, 980508124, 1041196574, 528571797 + ], + [ + 536870912, 805306368, 939524096, 201326592, 33554432, 989855744, 394264576, 440401920, 195035136, 328204288, 538443776, 54788096, 388366336, 643235840, 1039761408, 427048960, 531193856, 311029760, 869844992, 597963776, 395678208, 370684672, 910262400, 966803648, 278356192, 1000009776, 453462024, 663188716, 574976606, 128287593 + ], + [ + 536870912, 805306368, 939524096, 469762048, 234881024, 620756992, 713031680, 633339904, 115343360, 61865984, 698875904, 558104576, 908460032, 399966208, 333152256, 901120, 836149248, 584863744, 9189376, 588291072, 633083392, 696009984, 52265088, 610975936, 866459872, 529895536, 159160376, 857459860, 476819114, 799086999 + ], + [ + 536870912, 805306368, 939524096, 738197504, 771751936, 452984832, 159383552, 415236096, 488636416, 422576128, 426246144, 927727616, 66715648, 945094656, 188514304, 762527744, 101523456, 907841536, 71747584, 660950016, 760379904, 700112640, 70736512, 803884992, 470520416, 521798512, 12937432, 19110940, 255267454, 778650559 + ], + [ + 536870912, 268435456, 939524096, 67108864, 973078528, 855638016, 58720256, 4194304, 195035136, 175112192, 120061952, 987496448, 800456704, 298647552, 160137216, 371834880, 509091840, 779587584, 757774336, 836492288, 674753024, 730723072, 824922752, 534458176, 423049312, 521083984, 149703176, 658482140, 459786854, 303457165 + ], + [ + 536870912, 268435456, 134217728, 335544320, 905969664, 553648128, 645922816, 675282944, 807403520, 785383424, 242745344, 156499968, 280625152, 422903808, 440958976, 261865472, 1012965376, 821104640, 497723392, 61510656, 648819200, 1042823936, 594061440, 63673408, 610185760, 1015479120, 859867224, 497108164, 588561082, 664633329 + ], + [ + 536870912, 805306368, 939524096, 872415232, 704643072, 587202560, 914358272, 29360128, 836763648, 353370112, 329777152, 226754560, 860225536, 572981248, 871792640, 440221696, 1021861888, 967102464, 95500288, 866106368, 828203520, 104420608, 720240768, 1017315520, 238059744, 232407248, 352247976, 361336972, 477190362, 109014023 + ], + [ + 536870912, 805306368, 939524096, 67108864, 234881024, 16777216, 41943040, 297795584, 639631360, 495976448, 580386816, 908853248, 983695360, 89194496, 977240064, 813514752, 823910400, 762146816, 826796032, 887536640, 170989056, 659476736, 785718912, 628694464, 899276896, 28078288, 534800600, 934804500, 218691122, 531800387 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 704643072, 83886080, 864026624, 1019215872, 199229440, 36700160, 446169088, 189005824, 958529536, 315686912, 942637056, 832126976, 868655104, 761622528, 91297792, 297516032, 680633856, 613384960, 814579840, 914899008, 294199328, 453783792, 1045412008, 208325652, 909819598, 307314675 + ], + [ + 536870912, 805306368, 939524096, 469762048, 503316480, 855638016, 125829120, 1027604480, 1038090240, 858783744, 484966400, 829685760, 814612480, 671285248, 335904768, 973389824, 822468608, 713240576, 163694592, 120015872, 865193472, 305930496, 514607232, 488082624, 704261856, 210506096, 100663544, 520093708, 562036990, 306184325 + ], + [ + 536870912, 805306368, 939524096, 738197504, 100663296, 419430400, 260046848, 1052770304, 165675008, 705691648, 212336640, 348913664, 85590016, 836042752, 80510976, 220086272, 634675200, 785059840, 303794176, 860902400, 529090048, 624540416, 279389824, 959949760, 1029189216, 24493936, 234817656, 138548244, 145172166, 624405295 + ], + [ + 536870912, 805306368, 134217728, 738197504, 637534208, 520093696, 1015021568, 1027604480, 257949696, 258998272, 268959744, 819200000, 176291840, 440598528, 400588800, 942850048, 644505600, 472248320, 457820160, 414503936, 494040576, 1024014080, 290971776, 507657536, 769785888, 154337328, 703102984, 1004978220, 912810022, 606531615 + ], + [ + 536870912, 805306368, 939524096, 603979776, 369098752, 486539264, 729808896, 641728512, 983564288, 460324864, 102236160, 596377600, 313393152, 530382848, 455507968, 131645440, 91201536, 612331520, 108349440, 947055616, 479749632, 609116416, 558688384, 516901952, 378357920, 355286128, 870219928, 243732564, 1009337998, 330694985 + ], + [ + 536870912, 268435456, 939524096, 469762048, 704643072, 754974720, 142606336, 96468992, 924844032, 179306496, 663224320, 914096128, 724434944, 230096896, 489717760, 197869568, 505208832, 578793472, 892336128, 783713280, 246605312, 25847040, 159355264, 313429056, 720636320, 47249488, 1054603160, 920955212, 78247986, 583894049 + ], + [ + 536870912, 805306368, 671088640, 335544320, 905969664, 419430400, 1065353216, 994050048, 845152256, 877658112, 527958016, 659816448, 678297600, 903413760, 136675328, 908443648, 187113472, 715485184, 484747264, 654699520, 823435776, 596617984, 197840512, 247388352, 677637280, 391164912, 871891464, 412490532, 835503774, 774603981 + ], + [ + 536870912, 268435456, 671088640, 67108864, 33554432, 452984832, 411041792, 725614592, 455081984, 890241024, 138936320, 915668992, 192806912, 45809664, 892305408, 30457856, 514416640, 115806208, 679901184, 599006208, 862926336, 594717440, 796557696, 541921216, 40032160, 221492432, 165260808, 329148180, 1070280618, 1062693087 + ], + [ + 536870912, 268435456, 134217728, 201326592, 369098752, 352321536, 260046848, 205520896, 597688320, 862978048, 992477184, 823918592, 5111808, 89587712, 826507264, 807485440, 556867584, 25751552, 468502528, 573008896, 409536000, 238831872, 771555200, 303903808, 181344160, 244688976, 312564136, 921947484, 1013678142, 71122953 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 704643072, 150994944, 92274688, 968884224, 656408576, 124780544, 395837440, 175374336, 485359616, 119078912, 741769216, 319569920, 516448256, 790409216, 549488640, 178365440, 447897088, 649661696, 772041344, 133603520, 825111712, 775663088, 876895800, 571739404, 570223282, 680780021 + ], + [ + 536870912, 805306368, 134217728, 67108864, 100663296, 620756992, 109051904, 448790528, 530579456, 781189120, 603455488, 967049216, 413007872, 43581440, 1050116096, 955695104, 440737792, 57651200, 408156160, 240804864, 1010214400, 484903680, 561914496, 107629504, 232719520, 863731952, 1046742568, 230587188, 885586574, 567255009 + ], + [ + 536870912, 805306368, 671088640, 872415232, 771751936, 50331648, 260046848, 331350016, 10485760, 552599552, 892862464, 446431232, 485621760, 523960320, 530481152, 611401728, 762961920, 268349440, 195147776, 728816640, 553302528, 759019264, 495095680, 985830336, 169981984, 196140080, 131775016, 705541940, 102404014, 61772739 + ], + [ + 536870912, 268435456, 402653184, 335544320, 1040187392, 1023410176, 880803840, 314572800, 341835776, 380633088, 642252800, 3932160, 83492864, 141885440, 566722560, 739131392, 91316224, 615124992, 189556736, 357719040, 1002126848, 206921472, 14026368, 370533056, 611800608, 466027280, 923613336, 418430420, 1021923486, 820961773 + ], + [ + 536870912, 805306368, 134217728, 201326592, 436207616, 218103808, 897581056, 272629760, 559939584, 948961280, 653787136, 221511680, 985006080, 334823424, 420839424, 717570048, 266133504, 314060800, 173369344, 488991744, 26016256, 736310016, 743586944, 811114432, 92552352, 708681712, 501857448, 478994428, 644046002, 940699633 + ], + [ + 536870912, 805306368, 134217728, 872415232, 637534208, 989855744, 595591168, 121634816, 1025507328, 233832448, 9961472, 797704192, 565575680, 1015611392, 478642176, 275890176, 819601408, 724389888, 33867776, 1068575744, 557553152, 683603200, 340755072, 643167040, 202912928, 491738736, 685047336, 467290372, 816676014, 960936527 + ], + [ + 536870912, 268435456, 939524096, 335544320, 234881024, 184549376, 41943040, 188743680, 912261120, 516947968, 181927936, 117702656, 254672896, 96665600, 925007872, 364036096, 160014336, 169627648, 1040881664, 551394304, 766136832, 422497024, 180363392, 60829120, 32754336, 862579408, 344752152, 3260420, 843784246, 507416607 + ], + [ + 536870912, 268435456, 402653184, 469762048, 369098752, 16777216, 461373440, 415236096, 333447168, 101711872, 563609600, 529793024, 832962560, 491716608, 890404864, 555302912, 332734464, 1007071232, 503302144, 414884864, 291785216, 45085440, 1023473280, 495176128, 29400736, 342007248, 147864760, 863664844, 34064430, 150905869 + ], + [ + 536870912, 805306368, 671088640, 872415232, 167772160, 83886080, 1048576000, 641728512, 694157312, 896532480, 8912896, 255590400, 622460928, 587661312, 957120512, 41041920, 386473984, 33394688, 289015808, 244683776, 288730624, 1013226240, 125819520, 460956352, 838108704, 524787504, 225377448, 360836596, 264327850, 681735925 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 838860800, 855638016, 92274688, 113246208, 710934528, 9437184, 591921152, 205783040, 1013579776, 762773504, 693338112, 245940224, 555130880, 214102016, 358643712, 789765120, 713637376, 296174848, 154772096, 568300864, 591797792, 1005221168, 11860632, 984840572, 989591570, 457055235 + ], + [ + 536870912, 268435456, 134217728, 603979776, 33554432, 419430400, 545259520, 759169024, 551550976, 378535936, 16252928, 165937152, 733347840, 376373248, 213614592, 898088960, 1046798336, 158658560, 676083712, 168332288, 214774272, 893960960, 1026527360, 660214976, 311830688, 392059088, 254966440, 747285492, 713994794, 606798637 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 503316480, 1023410176, 494927872, 222298112, 748683264, 846200832, 543686656, 293339136, 566362112, 711000064, 177307648, 20692992, 757456896, 485871616, 946788352, 12211200, 778406400, 357992192, 731707008, 865107904, 784039968, 459718672, 752246808, 81727548, 1009956894, 1011369021 + ], + [ + 536870912, 805306368, 134217728, 201326592, 33554432, 721420288, 243269632, 88080384, 668991488, 1045430272, 277348352, 752091136, 629538816, 26017792, 119111680, 100614144, 375545856, 59854848, 522909696, 518441984, 698147328, 988970752, 473693056, 764163264, 890831776, 654244080, 350478760, 80840700, 331979306, 775353111 + ], + [ + 536870912, 805306368, 939524096, 603979776, 301989888, 520093696, 830472192, 666894336, 702545920, 567279616, 429391872, 504102912, 740163584, 107282432, 985300992, 146718720, 974577664, 735285248, 312166400, 93148160, 819894784, 201797376, 598307456, 155566144, 570997408, 934696048, 723566744, 179497812, 537590282, 548830987 + ], + [ + 536870912, 805306368, 402653184, 201326592, 301989888, 184549376, 427819008, 465567744, 455081984, 344981504, 592969728, 79429632, 583925760, 891617280, 131104768, 356139008, 256663552, 15159296, 502335488, 522851328, 1012192768, 263890688, 688676480, 101031744, 121747104, 677550960, 317720760, 816412796, 714573866, 404313143 + ], + [ + 536870912, 805306368, 939524096, 872415232, 704643072, 587202560, 981467136, 1052770304, 392167424, 78643200, 1057488896, 823394304, 979501056, 1060306944, 340492288, 1010253824, 510697472, 174665728, 446965760, 569027584, 971298304, 550238976, 66328704, 479452480, 345546784, 84750384, 447621176, 1014869044, 944068138, 253475619 + ], + [ + 536870912, 268435456, 939524096, 335544320, 637534208, 251658240, 947912704, 843055104, 106954752, 154140672, 837287936, 902037504, 808845312, 721354752, 283672576, 1044889600, 821469184, 601673728, 238655488, 56597504, 947546624, 456982784, 709587840, 877972928, 583822240, 981701072, 859840920, 501317828, 837970494, 751370507 + ], + [ + 536870912, 805306368, 939524096, 67108864, 973078528, 855638016, 494927872, 675282944, 1033895936, 972029952, 873988096, 803995648, 119668736, 1043529728, 788234240, 138166272, 730439680, 920924160, 168056832, 282575872, 285145600, 451571456, 209058176, 193800896, 489922592, 997929008, 478009400, 673743876, 102029882, 278798131 + ], + [ + 536870912, 805306368, 134217728, 872415232, 1040187392, 285212672, 276824064, 591396864, 677380096, 315621376, 490209280, 1039400960, 380764160, 1038811136, 869040128, 549797888, 932896768, 75927552, 444123136, 328569856, 694351360, 978416896, 41521024, 529874240, 727853088, 559088688, 1039810056, 1028972852, 818117054, 950028369 + ], + [ + 536870912, 268435456, 671088640, 67108864, 838860800, 352321536, 595591168, 541065216, 601882624, 30408704, 634912768, 600571904, 298188800, 550699008, 207323136, 982433792, 665149440, 641822720, 1021372416, 458423296, 270227968, 124539648, 91695232, 119233856, 166501024, 716567120, 850978824, 215940116, 943544858, 930042641 + ], + [ + 536870912, 805306368, 671088640, 738197504, 1040187392, 654311424, 998244352, 1027604480, 253755392, 1028653056, 1050148864, 885260288, 1063911424, 374276096, 739540992, 733200384, 1042964480, 1064185856, 843356160, 1017857024, 783071744, 329644288, 530116480, 474250048, 61358624, 288329008, 1021595048, 163120748, 1033271198, 1005600599 + ], + [ + 536870912, 805306368, 939524096, 469762048, 1040187392, 16777216, 494927872, 650117120, 673185792, 1062207488, 285736960, 878444544, 915013632, 27197440, 69828608, 412008448, 943874048, 476237824, 355579904, 557562880, 719632896, 95389952, 814959232, 816471232, 936294944, 748718384, 672320184, 434674908, 1043257886, 995186993 + ], + [ + 536870912, 268435456, 402653184, 201326592, 301989888, 855638016, 914358272, 801112064, 60817408, 1039138816, 310902784, 939261952, 364511232, 760545280, 1073184768, 260554752, 273653760, 366047232, 523896832, 412462080, 458719744, 452418304, 201668224, 604982976, 775031328, 187250448, 755963032, 800089548, 342406322, 745346531 + ], + [ + 536870912, 805306368, 134217728, 67108864, 570425344, 520093696, 914358272, 339738624, 467664896, 550502400, 284688384, 323747840, 210370560, 403111936, 246317056, 559497216, 696098816, 992161792, 7473152, 357176320, 858220032, 920387840, 940639616, 1012559808, 821972512, 299918640, 198429576, 209210052, 470590850, 65626095 + ], + [ + 536870912, 805306368, 939524096, 872415232, 570425344, 352321536, 713031680, 641728512, 65011712, 462422016, 366477312, 975962112, 997326848, 600506368, 238518272, 981286912, 76226560, 894816256, 715941888, 204604416, 279694848, 317096192, 617017728, 376932544, 849299488, 245093424, 793617976, 681805108, 921747362, 839600597 + ], + [ + 536870912, 268435456, 671088640, 738197504, 905969664, 1056964608, 864026624, 188743680, 10485760, 217055232, 167247872, 744751104, 1024589824, 480837632, 233734144, 206356480, 809263104, 520515584, 729839616, 524456960, 849402368, 703702784, 863732608, 732344384, 91396128, 465052688, 138723880, 622936876, 682697142, 316179327 + ], + [ + 536870912, 805306368, 671088640, 469762048, 637534208, 654311424, 159383552, 230686720, 748683264, 512753664, 956825600, 120324096, 837156864, 526974976, 211648512, 868040704, 300851200, 46632960, 54044672, 213279744, 29574656, 312568576, 227585408, 176872512, 200174496, 868677488, 95970824, 351779628, 111191438, 127019131 + ], + [ + 536870912, 268435456, 671088640, 335544320, 1040187392, 486539264, 696254464, 1002438656, 98566144, 193986560, 829947904, 431226880, 599654400, 90374144, 936607744, 979091456, 709271552, 479473664, 894191616, 801678336, 373105152, 77776640, 959569536, 289973440, 931009696, 637728720, 822124552, 730017796, 214026262, 257975305 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 570425344, 150994944, 813694976, 985661440, 123731968, 87031808, 382205952, 516161536, 891944960, 255262720, 125992960, 289456128, 203595776, 873680896, 207169536, 56572928, 144014848, 148045568, 607820416, 703528768, 52289056, 808890160, 268513928, 939590524, 872546306, 503513145 + ], + [ + 536870912, 268435456, 134217728, 201326592, 33554432, 385875968, 243269632, 490733568, 488636416, 927989760, 849870848, 1025245184, 561643520, 435486720, 96894976, 161464320, 1060872192, 206843904, 920029184, 1033323520, 834136576, 291797248, 621585536, 32682688, 423322144, 89537808, 626380424, 894766028, 1029072546, 827703239 + ], + [ + 536870912, 805306368, 671088640, 872415232, 1040187392, 654311424, 494927872, 373293056, 983564288, 208666624, 361234432, 443809792, 415891456, 123142144, 871923712, 654065664, 272588800, 542912512, 642627584, 81253376, 851005952, 702477056, 1041070720, 829819968, 390713888, 337031984, 970463912, 944585844, 332720670, 121186071 + ], + [ + 536870912, 805306368, 402653184, 67108864, 637534208, 150994944, 998244352, 641728512, 824180736, 242221056, 894959616, 898891776, 745144320, 1047461888, 265256960, 461193216, 398909440, 583028736, 232986624, 1049711616, 239737344, 278907648, 274140032, 252211264, 1061061152, 971497264, 103936408, 561572676, 979702150, 343128953 + ], + [ + 536870912, 268435456, 939524096, 67108864, 100663296, 83886080, 880803840, 1002438656, 723517440, 126877696, 35127296, 151257088, 458358784, 247005184, 1020755968, 959070208, 382558208, 204328960, 261883904, 26696704, 46801408, 939364608, 82210176, 392305216, 250841120, 501816336, 510476856, 1073561860, 686286214, 761398853 + ], + [ + 536870912, 805306368, 402653184, 335544320, 100663296, 721420288, 327155712, 876609536, 119537664, 651165696, 3670016, 1027866624, 179437568, 72024064, 485326848, 930037760, 657285120, 1041117184, 668792832, 845603840, 274948608, 242369792, 413691776, 56511040, 799283232, 33788976, 83950104, 880906516, 901936518, 509717355 + ], + [ + 536870912, 805306368, 134217728, 67108864, 503316480, 587202560, 58720256, 767557632, 870318080, 860880896, 812122112, 28049408, 1058406400, 806420480, 919306240, 593281024, 940548096, 1013370880, 734758912, 870130688, 508477952, 642161408, 897211264, 333711424, 738791840, 893302640, 161351720, 644670516, 167043606, 801213223 + ], + [ + 536870912, 805306368, 671088640, 872415232, 905969664, 788529152, 327155712, 549453824, 291504128, 491782144, 45613056, 590086144, 249692160, 663945216, 383418368, 16728064, 639197184, 161345536, 659142656, 153504768, 493286912, 994403584, 162919296, 473829056, 91971616, 634318896, 762525736, 793316404, 220698166, 56923439 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 234881024, 654311424, 75497472, 952107008, 463470592, 753926144, 868745216, 73138176, 983433216, 305987584, 273448960, 239550464, 1010540544, 823644160, 922916864, 746689536, 482438656, 698417408, 99839360, 273281088, 941616544, 436121712, 627854776, 259350604, 969987510, 49935467 + ], + [ + 536870912, 805306368, 939524096, 335544320, 838860800, 318767104, 998244352, 381681664, 274726912, 338690048, 628621312, 621019136, 320733184, 296288256, 487358464, 532725760, 618749952, 661753856, 383502336, 1003877376, 471292416, 754384128, 965015680, 1012842944, 1007338144, 920497392, 172749336, 671062308, 1054534282, 668207303 + ], + [ + 536870912, 805306368, 134217728, 335544320, 167772160, 150994944, 411041792, 62914560, 979369984, 617611264, 804782080, 200015872, 997851136, 774832128, 505053184, 92160000, 698490880, 649252864, 388605952, 974515200, 865373696, 81256704, 729108864, 583405504, 846106144, 70836528, 361746824, 497569748, 483700266, 125186361 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 503316480, 587202560, 713031680, 96468992, 761266176, 904921088, 594018304, 1055653888, 452329472, 783482880, 30048256, 528236544, 669786112, 561303552, 82843648, 485209088, 917449216, 987207936, 249762176, 867408960, 407511968, 138195280, 860657688, 669316140, 829000230, 737085727 + ], + [ + 536870912, 268435456, 671088640, 67108864, 704643072, 117440512, 109051904, 406847488, 811597824, 951058432, 526909440, 159121408, 704512000, 146735104, 995983360, 506314752, 99049472, 453709824, 600668160, 496499712, 692288000, 669004032, 661792640, 415948864, 845948832, 663085136, 146384776, 337911892, 564709282, 828125267 + ], + [ + 536870912, 805306368, 402653184, 67108864, 637534208, 486539264, 1031798784, 692060160, 203423744, 63963136, 961019904, 660340736, 456785920, 478609408, 353337344, 20004864, 284745728, 258215936, 188741632, 659039232, 240929280, 414888192, 751100544, 45005504, 916541984, 403801392, 44617880, 627929028, 524360326, 958504685 + ], + [ + 536870912, 805306368, 402653184, 201326592, 369098752, 788529152, 159383552, 650117120, 127926272, 198180864, 141033472, 6553600, 75890688, 137691136, 992772096, 1030766592, 20652032, 625922048, 276940800, 809657344, 820116992, 649261824, 303779200, 752793536, 84602272, 706029552, 809272760, 96064508, 252679086, 425956563 + ], + [ + 536870912, 268435456, 939524096, 603979776, 234881024, 1023410176, 377487360, 692060160, 1000341504, 766509056, 515375104, 530317312, 942800896, 880345088, 134184960, 761282560, 265412608, 15224832, 733423616, 249852928, 491743744, 106640128, 714063744, 414802880, 782051360, 1018262544, 171633208, 434008868, 34856846, 352875517 + ], + [ + 536870912, 805306368, 939524096, 201326592, 167772160, 956301312, 578813952, 817889280, 106954752, 1072693248, 582483968, 319553536, 432668672, 41353216, 790986752, 973979648, 860495872, 112709632, 793233408, 922614784, 175373824, 133761792, 2918784, 219698624, 941504032, 205780784, 966981560, 269524684, 973774762, 798454473 + ], + [ + 536870912, 268435456, 671088640, 201326592, 369098752, 1023410176, 914358272, 834666496, 333447168, 179306496, 820510720, 593231872, 735182848, 26804224, 56000512, 96387072, 199385088, 1051742208, 48834560, 73317376, 911314432, 1004081920, 401996416, 758044608, 576276512, 666364944, 982394408, 222916364, 525210774, 1017877757 + ], + [ + 536870912, 268435456, 939524096, 201326592, 838860800, 184549376, 880803840, 1035993088, 740294656, 328204288, 814219264, 1011089408, 107872256, 259719168, 423526400, 139542528, 967499776, 441716736, 950351872, 610055168, 371273216, 1016263424, 34180480, 881155776, 667698080, 514375120, 215381528, 912529180, 822082442, 175196615 + ], + [ + 536870912, 268435456, 939524096, 469762048, 436207616, 150994944, 209715200, 4194304, 1042284544, 594542592, 275251200, 122421248, 547487744, 506527744, 483098624, 729661440, 292265984, 1070436352, 518080512, 789627904, 540656128, 1054304000, 616984192, 41935040, 233414688, 126652432, 1019398200, 375456796, 961569306, 891025161 + ], + [ + 536870912, 805306368, 134217728, 738197504, 905969664, 184549376, 226492416, 1010827264, 891289600, 774897664, 73924608, 320077824, 168165376, 157089792, 178356224, 863059968, 164175872, 736432128, 1015875584, 907717632, 308268544, 1059206400, 724785024, 652788928, 953647008, 1046968560, 349026728, 289137116, 762257438, 197660695 + ], + [ + 536870912, 805306368, 402653184, 738197504, 973078528, 352321536, 696254464, 406847488, 555745280, 384827392, 608698368, 661913600, 854458368, 539033600, 426934272, 185286656, 383082496, 803008512, 671795200, 542481408, 320787968, 350952704, 902257536, 361151424, 681977248, 475319024, 18702392, 904458268, 172279842, 583310393 + ], + [ + 536870912, 805306368, 134217728, 201326592, 704643072, 956301312, 192937984, 29360128, 899678208, 709885952, 67633152, 444858368, 252313600, 470220800, 726302720, 929546240, 741875712, 712790016, 223647744, 566381568, 94552576, 575760640, 134857344, 814096704, 906674720, 394619184, 713802376, 46473548, 107627018, 779462921 + ], + [ + 536870912, 805306368, 134217728, 738197504, 167772160, 520093696, 75497472, 692060160, 161480704, 537919488, 616038400, 871104512, 532021248, 434700288, 16220160, 1028145152, 526737408, 305385472, 426276864, 1068956672, 703282688, 150303488, 290041472, 358901568, 221278368, 501908592, 385140264, 541839132, 686289026, 905102451 + ], + [ + 536870912, 268435456, 939524096, 603979776, 369098752, 285212672, 998244352, 650117120, 60817408, 326107136, 236453888, 619970560, 748290048, 901054464, 66682880, 107429888, 571531264, 550129664, 882726912, 267860992, 471458304, 871680768, 1041802112, 217527360, 815522336, 129354512, 83567544, 753235044, 1062371894, 94952193 + ], + [ + 536870912, 268435456, 134217728, 201326592, 301989888, 452984832, 394264576, 457179136, 627048448, 288358400, 421003264, 141295616, 901120000, 536543232, 69042176, 80625664, 338092032, 762515456, 570001408, 488483840, 5091840, 350596352, 22183552, 246074688, 45370528, 175775824, 207442472, 976076060, 206993050, 168370519 + ], + [ + 536870912, 268435456, 402653184, 67108864, 570425344, 285212672, 1031798784, 499122176, 727711744, 779091968, 206045184, 509870080, 960888832, 261554176, 701399040, 521322496, 658169856, 363786240, 803383296, 36713472, 82321920, 745936128, 368929152, 754672576, 97454496, 823153616, 138002872, 522999764, 1017228186, 403736261 + ], + [ + 536870912, 805306368, 939524096, 67108864, 167772160, 184549376, 176160768, 364904448, 123731968, 619708416, 311951360, 915668992, 461242368, 590413824, 720928768, 719831040, 321314816, 306515968, 196515840, 380580864, 1048267264, 908519680, 700849792, 670491840, 177065120, 36321776, 204347416, 599323700, 222669362, 53999887 + ], + [ + 536870912, 268435456, 402653184, 335544320, 100663296, 50331648, 679477248, 884998144, 832569344, 407896064, 434634752, 613679104, 150339584, 143065088, 142508032, 266584064, 271687680, 395874304, 728733696, 904631296, 647491072, 368368384, 923143552, 306161856, 159460768, 289470672, 585176504, 665910468, 31056830, 1057977287 + ], + [ + 536870912, 805306368, 671088640, 67108864, 704643072, 150994944, 461373440, 834666496, 513802240, 865075200, 875036672, 826015744, 467271680, 581369856, 723288064, 1024016384, 762257408, 978341888, 914905088, 78621696, 150110720, 723008768, 327656576, 726546624, 444693024, 507674928, 761290408, 540211652, 909804682, 1037396217 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 33554432, 419430400, 545259520, 650117120, 585105408, 68157440, 876085248, 440139776, 253886464, 661848064, 40402944, 338149376, 686694400, 569937920, 224233472, 124988416, 845860352, 472215808, 351083392, 603514816, 341745696, 670257200, 346662920, 1053080636, 285066754, 398630169 + ], + [ + 536870912, 805306368, 134217728, 201326592, 838860800, 1023410176, 679477248, 734003200, 249561088, 309329920, 554172416, 825491456, 991297536, 33882112, 977108992, 52510720, 663773184, 284733440, 276740096, 142787584, 465570304, 115440896, 510764416, 319548096, 204752288, 328604400, 700751272, 886927100, 290566042, 110794689 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 301989888, 50331648, 528482304, 1002438656, 962592768, 271581184, 1060634624, 813957120, 608043008, 293273600, 891781120, 351223808, 682745856, 226136064, 925140992, 1072604160, 187841024, 616094976, 222688384, 811348416, 264883872, 761261264, 961264136, 505191724, 174822586, 495837695 + ], + [ + 536870912, 268435456, 939524096, 335544320, 167772160, 788529152, 494927872, 574619648, 1038090240, 122683392, 379060224, 422838272, 71958528, 300744704, 110985216, 603340800, 963125248, 748498944, 485865472, 485110784, 450811392, 722843904, 884714368, 298110016, 274820640, 219319568, 125369784, 6763860, 936568234, 979071359 + ], + [ + 536870912, 268435456, 134217728, 603979776, 570425344, 721420288, 25165824, 901775360, 828375040, 533725184, 421003264, 420741120, 1071251456, 368377856, 466255872, 277823488, 361537536, 688910336, 474855424, 376187904, 782036480, 133689600, 684445568, 1024227392, 642674208, 292335888, 689794952, 993429604, 858347010, 379575611 + ], + [ + 536870912, 268435456, 402653184, 872415232, 838860800, 754974720, 41943040, 440401920, 828375040, 556793856, 818413568, 714342400, 354287616, 678100992, 738492416, 482656256, 199712768, 95907840, 1062156288, 949185536, 853049856, 638459136, 678437760, 942395328, 342106528, 359994064, 946692664, 784510244, 1008925610, 332403673 + ], + [ + 536870912, 268435456, 939524096, 67108864, 167772160, 352321536, 142606336, 641728512, 178257920, 523239424, 2621440, 743702528, 481165312, 650313728, 14843904, 596885504, 68739072, 1006497792, 188471296, 504359936, 368266752, 919083264, 348574080, 255186880, 654059424, 800592592, 239894552, 72400916, 1048207410, 791556113 + ], + [ + 536870912, 805306368, 402653184, 469762048, 167772160, 150994944, 931135488, 910163968, 543162368, 617611264, 374865920, 794558464, 866779136, 1027014656, 683638784, 154714112, 252583936, 892522496, 801708032, 602330112, 803614208, 233304320, 14948224, 560236224, 338073120, 180827440, 802619800, 799831004, 71317418, 90265337 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 167772160, 318767104, 931135488, 759169024, 627048448, 393216000, 661127168, 424411136, 948043776, 549650432, 589529088, 965984256, 391684096, 138752000, 20805632, 309056512, 1070519808, 893597440, 694294144, 628327616, 141164576, 617545776, 113344568, 841007164, 420683786, 1000009747 + ], + [ + 536870912, 268435456, 134217728, 335544320, 167772160, 1023410176, 511705088, 314572800, 383778816, 263192576, 258473984, 626262016, 603062272, 457768960, 872710144, 925581312, 997564416, 262230016, 286369792, 116984832, 443547136, 318747392, 1027934848, 562647872, 652683296, 983256080, 488562184, 1047896852, 488702602, 366022525 + ], + [ + 536870912, 268435456, 939524096, 469762048, 570425344, 889192448, 981467136, 247463936, 769654784, 458227712, 967311360, 655622144, 674627584, 344391680, 662470656, 1027686400, 731996160, 896741376, 698030080, 690893824, 778619392, 980758272, 749051264, 72106176, 49839520, 247345360, 924976536, 548615372, 301586362, 792473593 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 369098752, 721420288, 796917760, 792723456, 484442112, 1039138816, 443023360, 444858368, 175505408, 211615744, 47939584, 286146560, 25305088, 541265920, 828614656, 330398720, 336110080, 213275904, 205475712, 407381440, 869590944, 546134512, 163726728, 757206220, 886082078, 750348583 + ], + [ + 536870912, 268435456, 402653184, 67108864, 704643072, 184549376, 545259520, 255852544, 555745280, 196083712, 695730176, 810287104, 26345472, 306774016, 242581504, 352206848, 845783040, 1044656128, 172345344, 675615744, 1061585408, 834978560, 528747392, 354759360, 827615264, 911025168, 747719192, 264820484, 79104426, 991932875 + ], + [ + 536870912, 805306368, 134217728, 738197504, 1040187392, 889192448, 142606336, 247463936, 85983232, 349175808, 755499008, 760479744, 1019346944, 1042481152, 558923776, 122339328, 414703616, 405884928, 259753984, 801926144, 335319552, 243772672, 709361792, 70720832, 217088032, 760922160, 950001672, 229986348, 548505662, 163277877 + ], + [ + 536870912, 268435456, 402653184, 67108864, 100663296, 452984832, 293601280, 977272832, 65011712, 439353344, 1061683200, 356777984, 230817792, 849412096, 273776640, 456671232, 804020224, 431468544, 296359936, 234300416, 88866304, 474252032, 423732352, 107002944, 1047756832, 598294544, 418766872, 332132356, 897873926, 1038193691 + ], + [ + 536870912, 805306368, 402653184, 738197504, 973078528, 385875968, 612368384, 113246208, 765460480, 846200832, 543686656, 760479744, 1042415616, 540213248, 319389696, 512147456, 372875264, 974024704, 620611584, 106408960, 144833024, 99751680, 203992704, 121022784, 678666272, 124350512, 299255832, 350383148, 932305466, 914007831 + ], + [ + 536870912, 805306368, 939524096, 201326592, 436207616, 117440512, 159383552, 775946240, 429916160, 219152384, 856162304, 189005824, 940703744, 965410816, 42434560, 519225344, 968531968, 476049408, 417224704, 807289856, 981428736, 378407168, 741749888, 401260096, 813062176, 222970928, 451242552, 16845068, 478393498, 348356167 + ], + [ + 536870912, 268435456, 939524096, 872415232, 704643072, 587202560, 327155712, 46137344, 526385152, 498073600, 283639808, 734265344, 848166912, 563806208, 89030656, 947568640, 213704704, 464588800, 1038698496, 155464704, 885959168, 95991040, 643582336, 968998080, 685802400, 225630672, 411656728, 267796772, 61211538, 112990679 + ], + [ + 536870912, 805306368, 671088640, 603979776, 704643072, 251658240, 343932928, 910163968, 23068672, 602931200, 405274624, 765722624, 851836928, 741670912, 597655552, 586792960, 35479552, 389582848, 767449088, 233372672, 839354880, 1451264, 395280256, 73472448, 141696928, 317295088, 1048856456, 978679252, 418237858, 43143387 + ], + [ + 536870912, 805306368, 402653184, 469762048, 1040187392, 956301312, 1048576000, 4194304, 161480704, 36700160, 980942848, 633602048, 5636096, 689766400, 203456512, 200491008, 740007936, 211136512, 268277760, 70351872, 796521984, 1027931392, 622280320, 540846272, 928056992, 111699184, 195913912, 1058661868, 18194438, 842838037 + ], + [ + 536870912, 268435456, 402653184, 201326592, 771751936, 285212672, 192937984, 339738624, 505413632, 783286272, 651689984, 611057664, 171573248, 758972416, 221478912, 916045824, 5201920, 395038720, 1063737344, 664785920, 1027774976, 161599232, 217309056, 637154752, 794589728, 698539792, 485648280, 1039856076, 593319950, 128111617 + ], + [ + 536870912, 805306368, 671088640, 872415232, 771751936, 889192448, 713031680, 448790528, 677380096, 451936256, 129499136, 994312192, 49676288, 745340928, 335249408, 1072087040, 426057728, 27783168, 784635904, 833917952, 491758080, 187430144, 185502336, 143332544, 354390688, 234897648, 83923080, 42173892, 784474662, 106968369 + ], + [ + 536870912, 805306368, 134217728, 67108864, 637534208, 587202560, 142606336, 381681664, 580911104, 1060110336, 931659776, 14417920, 672792576, 1030160384, 1020166144, 266420224, 1003610112, 819654656, 147236864, 629095424, 162107904, 925734656, 305331840, 671675584, 815716896, 997743408, 242599048, 28729284, 311932550, 988166355 + ], + [ + 536870912, 805306368, 939524096, 738197504, 704643072, 318767104, 494927872, 1044381696, 501219328, 923795456, 227016704, 983302144, 888274944, 530251776, 731348992, 313311232, 1061920768, 868069376, 63084544, 329286656, 317836800, 379148544, 487867520, 493790144, 921253920, 172831792, 618354232, 452320556, 25135786, 182516435 + ], + [ + 536870912, 268435456, 402653184, 603979776, 436207616, 318767104, 25165824, 910163968, 417333248, 680525824, 125304832, 578551808, 189923328, 1004077056, 1024294912, 456671232, 563912704, 507686912, 887314432, 244532224, 712703488, 721367296, 797975424, 351973824, 993843232, 741475344, 738975256, 806732068, 639097754, 51856851 + ], + [ + 536870912, 268435456, 939524096, 603979776, 503316480, 687865856, 897581056, 1027604480, 346030080, 628097024, 411566080, 1038876672, 1966080, 509018112, 458784768, 991215616, 1006247936, 946089984, 779200512, 772365312, 976201216, 293476608, 960966016, 641844544, 438338976, 112433488, 401187736, 872300660, 142880262, 35878173 + ], + [ + 536870912, 805306368, 134217728, 738197504, 905969664, 553648128, 226492416, 499122176, 702545920, 955252736, 571998208, 30146560, 755630080, 640090112, 1029603328, 438550528, 605085696, 90722304, 85293056, 531016704, 43865600, 12782336, 710943616, 540028352, 477679136, 872281904, 175115656, 257526508, 107985814, 752472529 + ], + [ + 536870912, 268435456, 939524096, 67108864, 637534208, 822083584, 629145600, 364904448, 786432000, 684720128, 655884288, 648282112, 872022016, 225771520, 509706240, 781271040, 356114432, 18305024, 267532288, 321604608, 107951616, 583373056, 241827712, 718108480, 506910240, 1069728016, 367249336, 642923332, 73129990, 788942881 + ], + [ + 536870912, 268435456, 402653184, 603979776, 1040187392, 687865856, 243269632, 1010827264, 467664896, 617611264, 449314816, 659816448, 597557248, 1036713984, 148144128, 761118720, 6987776, 551940096, 885504000, 255167488, 59607552, 362892032, 70380928, 463147968, 1012688800, 988436688, 983927352, 572869428, 459795878, 201593805 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 234881024, 553648128, 595591168, 859832320, 987758592, 53477376, 251133952, 452198400, 585236480, 120651776, 351961088, 167231488, 778231808, 921899008, 1054390272, 56947712, 424234496, 567223040, 137779072, 1010981696, 677568544, 1005785104, 995670056, 757396540, 237587982, 817832737 + ], + [ + 536870912, 268435456, 402653184, 335544320, 570425344, 855638016, 478150656, 666894336, 471859200, 472907776, 702021632, 11272192, 793116672, 825425920, 945324032, 653049856, 220553216, 459411456, 433223680, 885748736, 751099392, 745738496, 179873408, 494707520, 562954400, 989120080, 715814968, 949449732, 284876346, 18616615 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 369098752, 218103808, 411041792, 46137344, 165675008, 569376768, 955777024, 1021575168, 354025472, 253165568, 48398336, 208715776, 381280256, 499585024, 638248960, 60816384, 482317824, 783086336, 614986112, 154878272, 747009568, 816571184, 231545224, 412401020, 262266934, 215158845 + ], + [ + 536870912, 805306368, 939524096, 603979776, 234881024, 318767104, 75497472, 356515840, 157286400, 963641344, 881328128, 528220160, 548274176, 712310784, 689078272, 612024320, 288694272, 57774080, 562731008, 352300032, 460179968, 727168256, 243530112, 943956032, 652263840, 213015664, 648557464, 1013781844, 702003222, 348273671 + ], + [ + 536870912, 268435456, 402653184, 201326592, 1040187392, 285212672, 864026624, 130023424, 379584512, 498073600, 913833984, 983826432, 210108416, 41353216, 334397440, 605700096, 1027055616, 437104640, 541722624, 387789824, 109084160, 239195392, 710990464, 462591168, 814316192, 1060906192, 158593720, 878203100, 374647942, 706573773 + ], + [ + 536870912, 805306368, 402653184, 67108864, 503316480, 16777216, 1031798784, 297795584, 316669952, 389021696, 718798848, 833880064, 382861312, 862650368, 875397120, 46546944, 321445888, 84840448, 68425728, 138525696, 757227008, 483621632, 74041728, 347003200, 881129504, 252390448, 1012680216, 364758788, 269227934, 261415489 + ], + [ + 536870912, 805306368, 402653184, 469762048, 503316480, 721420288, 696254464, 1069547520, 631242752, 800063488, 786956288, 682885120, 294518784, 415301632, 975339520, 1064321024, 549986304, 231165952, 407250944, 159671296, 522528256, 85319936, 171750784, 740980160, 999627680, 847044848, 88768568, 67387436, 317071366, 230051895 + ], + [ + 536870912, 268435456, 671088640, 335544320, 1040187392, 989855744, 293601280, 213909504, 73400320, 904921088, 412614656, 747896832, 1045823488, 288817152, 491094016, 488423424, 199958528, 995004416, 593528832, 510772224, 962281984, 376716544, 686204032, 973874624, 298001568, 48293328, 716178568, 20608452, 159812790, 897364479 + ], + [ + 536870912, 268435456, 939524096, 603979776, 234881024, 587202560, 1048576000, 767557632, 752877568, 554696704, 858259456, 142868480, 1071775744, 932249600, 48988160, 241582080, 871555072, 423309312, 422340608, 816225280, 160509440, 166371584, 753212032, 875754560, 416997408, 633286672, 281962552, 3644452, 1006284302, 156033315 + ], + [ + 536870912, 805306368, 671088640, 469762048, 503316480, 1023410176, 847249408, 306184192, 769654784, 282066944, 189267968, 358350848, 241827840, 372178944, 235962368, 971685888, 854548480, 464523264, 1004128256, 955544576, 409351680, 768395520, 264387200, 908275904, 351524384, 347674928, 308548264, 583898332, 910379070, 937538573 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 436207616, 184549376, 243269632, 297795584, 840957952, 623902720, 1041760256, 487849984, 697958400, 89587712, 922255360, 881115136, 191963136, 678981632, 1028114432, 760245248, 726231552, 308117248, 902163328, 496123456, 887843360, 338591536, 843017128, 479592060, 148425274, 599117627 + ], + [ + 536870912, 268435456, 671088640, 872415232, 1040187392, 989855744, 763363328, 515899392, 488636416, 737148928, 345505792, 860094464, 386269184, 191299584, 980779008, 79609856, 1053892608, 459837440, 836716544, 725754880, 266581504, 349268224, 241848448, 257891520, 738316448, 839048400, 419655816, 478383332, 910203062, 358873311 + ], + [ + 536870912, 805306368, 939524096, 335544320, 771751936, 687865856, 1048576000, 624951296, 81788928, 967835648, 338165760, 56360960, 201719808, 206635008, 924352512, 607567872, 918134784, 694644736, 589363200, 705952768, 41646592, 54789376, 129094016, 891990848, 299684768, 323390064, 263280664, 422087716, 735937046, 340195645 + ], + [ + 536870912, 805306368, 939524096, 603979776, 637534208, 16777216, 729808896, 373293056, 291504128, 776994816, 276299776, 524550144, 912130048, 726204416, 929857536, 6537216, 231940096, 440004608, 203745280, 1057995776, 296837632, 367643392, 824133248, 430687680, 326960288, 58457840, 466004504, 379553556, 99273886, 958247653 + ], + [ + 536870912, 805306368, 134217728, 469762048, 1040187392, 352321536, 427819008, 884998144, 216006656, 588251136, 369623040, 732692480, 463863808, 17367040, 690978816, 736575488, 1017847808, 203239424, 119506944, 1000207360, 517779968, 989755136, 722347392, 186034240, 791844768, 737730416, 1035252264, 914519852, 574629302, 514041929 + ], + [ + 536870912, 805306368, 402653184, 738197504, 838860800, 452984832, 260046848, 130023424, 748683264, 623902720, 637009920, 963379200, 252837888, 596312064, 544571392, 338477056, 854728704, 559624192, 677361664, 887856128, 870799872, 1004837632, 1071979392, 971407552, 1021810720, 443001904, 153575960, 767870764, 597156274, 268364763 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 905969664, 553648128, 1031798784, 666894336, 1029701632, 894435328, 758644736, 606339072, 220332032, 686882816, 25919488, 437239808, 681402368, 684003328, 28530688, 497761280, 662500864, 181921024, 95124352, 192902720, 81059872, 413913104, 16627768, 34991164, 407424566, 309119265 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 436207616, 251658240, 780140544, 759169024, 1008730112, 542113792, 122159104, 514064384, 442368000, 948109312, 541163520, 698564608, 93478912, 53039104, 592844800, 1048984576, 806229504, 952780544, 744763776, 79527616, 238149536, 767038928, 553517096, 429064236, 153714706, 609697843 + ], + [ + 536870912, 268435456, 402653184, 738197504, 33554432, 117440512, 696254464, 1061158912, 937426944, 907018240, 495452160, 573833216, 512884736, 709427200, 840269824, 547405824, 636559360, 496627712, 381442048, 270914560, 622333440, 964524288, 738684032, 422100288, 835082272, 705221648, 276270616, 871414060, 614059138, 574393671 + ], + [ + 536870912, 268435456, 134217728, 335544320, 100663296, 553648128, 662700032, 943718400, 769654784, 294649856, 308805632, 537657344, 299499520, 643104768, 399409152, 8011776, 338026496, 557174784, 329013248, 1018328064, 484079104, 198526208, 344804480, 958058432, 1031228960, 545104144, 270533256, 993160916, 882494630, 775262193 + ], + [ + 536870912, 268435456, 939524096, 335544320, 33554432, 218103808, 260046848, 1061158912, 111149056, 613416960, 882376704, 786694144, 209846272, 1002504192, 23298048, 200359936, 610803712, 168611840, 995031040, 921498624, 721218048, 933726464, 757246336, 835837504, 322568224, 334823440, 140083256, 285491220, 431071234, 1028165645 + ], + [ + 536870912, 268435456, 134217728, 335544320, 838860800, 956301312, 310378496, 88080384, 354418688, 177209344, 998768640, 671350784, 1032978432, 638124032, 1019510784, 309542912, 477765632, 616501248, 214853632, 1035236352, 965296640, 151339264, 856886400, 88810048, 585525280, 861959184, 808665608, 483934484, 787319986, 715481721 + ], + [ + 536870912, 805306368, 939524096, 872415232, 503316480, 989855744, 343932928, 155189248, 148897792, 277872640, 671612928, 459014144, 758775808, 86441984, 234717184, 1003110400, 704471040, 768176128, 519890944, 323699712, 851326464, 875083008, 1072523904, 495000256, 1019362848, 136364336, 179492024, 867933172, 426085054, 312355531 + ], + [ + 536870912, 268435456, 939524096, 67108864, 167772160, 251658240, 796917760, 515899392, 585105408, 269484032, 491257856, 941359104, 555089920, 766181376, 856588288, 568180736, 7856128, 360239104, 228902912, 592606208, 40555008, 325977856, 864907648, 10276672, 72819616, 596117584, 184365592, 151443220, 887208370, 18004811 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 100663296, 1056964608, 444596224, 482344960, 1067450368, 244318208, 823656448, 313262080, 206438400, 1061093376, 836075520, 642924544, 616046592, 222220288, 618133504, 768668672, 570158592, 853423872, 908357248, 930723904, 270519968, 579217488, 426481288, 80039020, 705306766, 502734675 + ], + [ + 536870912, 805306368, 939524096, 335544320, 771751936, 419430400, 914358272, 515899392, 429916160, 617611264, 429391872, 1069809664, 779747328, 427229184, 1041334272, 641351680, 773152768, 996331520, 259164160, 642513920, 870298112, 251609344, 535597952, 844388672, 570511904, 318820656, 964885432, 625161556, 534972430, 984726569 + ], + [ + 536870912, 268435456, 939524096, 335544320, 503316480, 285212672, 528482304, 390070272, 18874368, 108003328, 246939648, 386138112, 270401536, 480968704, 770605056, 860930048, 113876992, 817852416, 211527680, 99904512, 560330240, 122670336, 744528000, 542333376, 709545632, 461169872, 511278616, 90444036, 827287206, 291735749 + ], + [ + 536870912, 805306368, 402653184, 335544320, 1040187392, 385875968, 125829120, 1010827264, 543162368, 781189120, 11010048, 554958848, 70123520, 537985024, 476741632, 582270976, 580689920, 273387520, 71796736, 10845184, 469131776, 142540544, 874130304, 474843072, 713277856, 985793776, 10586168, 523271204, 454746662, 1070546691 + ], + [ + 536870912, 805306368, 134217728, 67108864, 637534208, 486539264, 947912704, 130023424, 610271232, 250609664, 691535872, 152305664, 891158528, 726728704, 782991360, 509394944, 384835584, 356036608, 588699648, 169718784, 684808704, 216594688, 92091520, 1000496832, 378615456, 231461872, 523073576, 1065993268, 1007657518, 517602585 + ], + [ + 536870912, 268435456, 402653184, 469762048, 503316480, 1023410176, 612368384, 281018368, 585105408, 506462208, 279445504, 871104512, 149028864, 691077120, 321486848, 950910976, 1027858432, 480432128, 185845760, 939052032, 708300288, 275200, 447496832, 239121088, 488890400, 592629776, 467388440, 736414748, 706596382, 690565949 + ], + [ + 536870912, 805306368, 402653184, 872415232, 838860800, 318767104, 645922816, 532676608, 195035136, 200278016, 250085376, 202113024, 280363008, 983629824, 376602624, 464175104, 510418944, 837029888, 171595776, 768939008, 326206976, 875259136, 405782912, 84293184, 883457952, 384587632, 589586488, 840437764, 1046763562, 1014502439 + ], + [ + 536870912, 268435456, 402653184, 738197504, 905969664, 553648128, 1048576000, 952107008, 383778816, 892338176, 14155776, 33816576, 566624256, 245825536, 81166336, 950812672, 398139392, 880226304, 868210688, 749786112, 798554624, 648481024, 550892672, 984607936, 750482592, 502770896, 352212152, 1007918332, 881396878, 95160541 + ], + [ + 536870912, 805306368, 402653184, 603979776, 973078528, 1023410176, 176160768, 20971520, 262144000, 569376768, 505937920, 219938816, 34734080, 318439424, 260407296, 8667136, 990289920, 919031808, 455501824, 955610112, 837700096, 649594624, 111537792, 641017792, 160253984, 397042736, 836534808, 594617124, 325602490, 79435005 + ], + [ + 536870912, 268435456, 402653184, 603979776, 33554432, 822083584, 864026624, 834666496, 106954752, 32505856, 640155648, 436994048, 596246528, 614268928, 198410240, 259735552, 120954880, 186601472, 202381312, 572034048, 541367808, 762798848, 280900736, 897783744, 314752544, 484668176, 666078360, 327732196, 748435490, 936483873 + ], + [ + 536870912, 268435456, 134217728, 201326592, 100663296, 218103808, 746586112, 230686720, 958398464, 363855872, 58195968, 298057728, 199622656, 601292800, 267354112, 734740480, 641540096, 333639680, 454277120, 847913984, 115185152, 1030929664, 182186624, 129346240, 817812128, 220420816, 129198760, 209354460, 977763502, 564429777 + ], + [ + 536870912, 805306368, 402653184, 335544320, 1040187392, 956301312, 478150656, 197132288, 887095296, 821035008, 301465600, 65798144, 435814400, 1072627712, 737902592, 753811456, 813195264, 44945408, 333031424, 226323456, 103998976, 798647040, 232651136, 174284224, 3335712, 848978736, 928905624, 748903892, 374531614, 816472841 + ], + [ + 536870912, 268435456, 939524096, 67108864, 838860800, 855638016, 260046848, 1019215872, 270532608, 36700160, 588775424, 1002700800, 14548992, 790298624, 633765888, 1037942784, 630743040, 394694656, 767428608, 80434176, 441212416, 661858560, 519784064, 760533952, 381098144, 690485968, 1070358040, 1018374420, 190531210, 614781943 + ], + [ + 536870912, 805306368, 134217728, 335544320, 838860800, 989855744, 796917760, 314572800, 912261120, 439353344, 954728448, 104071168, 215351296, 262471680, 703430656, 747159552, 520478720, 129978368, 1028794368, 442024960, 765379072, 859926784, 161740672, 47243456, 815273888, 134131952, 259112872, 944485604, 275193242, 17651167 + ], + [ + 536870912, 805306368, 939524096, 67108864, 1040187392, 520093696, 360710144, 734003200, 996147200, 881852416, 1017643008, 161218560, 753532928, 239009792, 177831936, 398934016, 634281984, 211857408, 99760128, 288918528, 1001737728, 624289024, 762696832, 517387456, 1051119136, 1012770096, 948581560, 388842692, 435197470, 456825135 + ], + [ + 536870912, 805306368, 671088640, 738197504, 369098752, 587202560, 796917760, 624951296, 648019968, 97517568, 844627968, 644612096, 318111744, 293142528, 738033664, 244203520, 33988608, 1034997760, 376145920, 105221120, 898870784, 678993664, 25126016, 256853312, 40323744, 763402864, 608374280, 941707036, 370240702, 725125455 + ], + [ + 536870912, 268435456, 939524096, 872415232, 771751936, 352321536, 578813952, 616562688, 278921216, 458227712, 105381888, 940834816, 617742336, 470351872, 779583488, 539049984, 412344320, 57331712, 704997376, 259697664, 1017993728, 22945024, 759588992, 664333120, 1050634272, 443001872, 42523192, 951475508, 125962414, 776174421 + ], + [ + 536870912, 268435456, 134217728, 67108864, 838860800, 788529152, 998244352, 440401920, 882900992, 632291328, 354942976, 28573696, 614858752, 1044316160, 161710080, 556908544, 1022091264, 727027712, 129263616, 564653056, 650040832, 509834496, 315794304, 964297408, 973941664, 1036549840, 363304360, 213706708, 1029955610, 525439035 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 704643072, 654311424, 209715200, 20971520, 769654784, 405798912, 618135552, 1050935296, 546701312, 827129856, 275349504, 725368832, 1003741184, 904400896, 805083136, 586378240, 1023123968, 1043708160, 664541312, 1040421056, 16810144, 159448304, 381887144, 169952716, 328284674, 495703339 + ], + [ + 536870912, 805306368, 939524096, 201326592, 1040187392, 486539264, 142606336, 1035993088, 589299712, 573571072, 336068608, 26476544, 170786816, 787546112, 833126400, 996622336, 965025792, 244789248, 296736768, 1051792384, 734678528, 968188160, 832510848, 834223552, 870092192, 953698544, 479156248, 159536188, 54619654, 937644305 + ], + [ + 536870912, 805306368, 134217728, 335544320, 637534208, 117440512, 92274688, 432013312, 48234496, 598736896, 186122240, 18087936, 441319424, 175702016, 208109568, 506970112, 622731264, 970166272, 837478400, 1034839040, 893968896, 4152576, 864140928, 650316480, 459332768, 141727728, 687391272, 539348260, 219469486, 273592019 + ], + [ + 536870912, 805306368, 671088640, 603979776, 973078528, 855638016, 444596224, 457179136, 115343360, 594542592, 247988224, 796655616, 362938368, 831717376, 1069187072, 917913600, 442343424, 208809984, 306718720, 826110976, 616795648, 438413056, 89191552, 1033415616, 1072111648, 969175088, 982878248, 34554916, 174827066, 996987699 + ], + [ + 536870912, 805306368, 671088640, 469762048, 369098752, 654311424, 964689920, 742391808, 320864256, 47185920, 946339840, 859570176, 694812672, 499056640, 346587136, 1054785536, 324657152, 593801216, 562984960, 359691264, 108677632, 515365120, 342330496, 1034944, 221399584, 526113072, 761629864, 848087772, 653314614, 456792343 + ], + [ + 536870912, 268435456, 939524096, 738197504, 1040187392, 520093696, 377487360, 750780416, 18874368, 776994816, 379060224, 205783040, 560070656, 649134080, 443252736, 63881216, 568188928, 27717632, 504489984, 645565440, 750170624, 283653376, 957288832, 738136128, 729047072, 88682512, 580880440, 432454700, 220248638, 5327135 + ], + [ + 536870912, 805306368, 402653184, 872415232, 704643072, 251658240, 478150656, 817889280, 790626304, 680525824, 684195840, 1025769472, 199098368, 635502592, 548569088, 819642368, 992862208, 1020809216, 355350528, 31015936, 850247168, 127490816, 575452544, 480884416, 315937696, 644151792, 213868600, 546476036, 885774386, 992285755 + ], + [ + 536870912, 268435456, 402653184, 201326592, 838860800, 318767104, 578813952, 281018368, 136314880, 812646400, 629669888, 787218432, 83755008, 434569216, 852656128, 20463616, 625369088, 929091584, 990984192, 614175744, 225928704, 353085696, 1026420096, 912136512, 894842272, 762977616, 212110264, 649244764, 279533578, 85738511 + ], + [ + 536870912, 805306368, 939524096, 201326592, 167772160, 922746880, 713031680, 1027604480, 962592768, 571473920, 105381888, 697040896, 193069056, 583204864, 765689856, 179355648, 494444544, 691499008, 294955008, 44487680, 907875840, 705192192, 929858688, 827328704, 103415840, 673120304, 722042936, 418365452, 496050186, 579383351 + ], + [ + 536870912, 805306368, 939524096, 335544320, 301989888, 318767104, 293601280, 339738624, 505413632, 204472320, 1017643008, 968622080, 859963392, 369164288, 151093248, 780255232, 62955520, 190877696, 277911552, 894995456, 259301888, 418312448, 366698880, 437609792, 763334112, 134478352, 396361736, 1013973004, 143130638, 848035845 + ], + [ + 536870912, 268435456, 402653184, 201326592, 369098752, 218103808, 1015021568, 465567744, 236978176, 867172352, 594018304, 163315712, 58589184, 866582528, 158564352, 464601088, 661135360, 196874240, 343848960, 338050048, 590533120, 852495104, 20517504, 356837312, 219837216, 1032679760, 441850152, 192628308, 543021486, 552577687 + ], + [ + 536870912, 268435456, 402653184, 603979776, 704643072, 721420288, 427819008, 624951296, 815792128, 934281216, 344457216, 1066663936, 775553024, 662241280, 960266240, 48152576, 740958208, 213962752, 501291008, 990981120, 758733312, 706579712, 590227840, 897729088, 195351456, 1022560592, 231522824, 200696068, 9393030, 800202569 + ], + [ + 536870912, 805306368, 402653184, 603979776, 905969664, 687865856, 125829120, 566231040, 731906048, 521142272, 556269568, 181141504, 191234048, 19988480, 821657600, 918863872, 486219776, 387887104, 649447424, 887323648, 556527104, 286739712, 304627840, 508304704, 237450336, 936431664, 1023993864, 740084748, 636462598, 585953545 + ], + [ + 536870912, 805306368, 671088640, 335544320, 570425344, 654311424, 327155712, 943718400, 421527552, 544210944, 465043456, 123469824, 706084864, 339542016, 742883328, 7618560, 1055072256, 824135680, 339286016, 958221312, 506927616, 348972288, 1044343168, 21622976, 1042630496, 648730224, 1035717000, 877846732, 88571754, 452250229 + ], + [ + 536870912, 805306368, 402653184, 335544320, 1040187392, 654311424, 947912704, 398458880, 916455424, 521142272, 382205952, 87818240, 813039616, 149356544, 359563264, 389169152, 1039458304, 977932288, 202483712, 541600768, 771584512, 710366976, 1043777408, 302448064, 899569184, 210483856, 20053544, 907581084, 693373998, 5931417 + ], + [ + 536870912, 805306368, 939524096, 603979776, 1040187392, 520093696, 360710144, 12582912, 182452224, 751828992, 1049100288, 921960448, 855506944, 20512768, 913145856, 224641024, 962732032, 258174976, 207861760, 65195008, 572757504, 574832384, 466788992, 796538432, 1069425312, 521757808, 375131656, 607879948, 446631054, 346555721 + ], + [ + 536870912, 268435456, 402653184, 67108864, 570425344, 285212672, 75497472, 1027604480, 94371840, 508559360, 452460544, 315883520, 280363008, 853213184, 312049664, 509886464, 482271232, 103165952, 71440384, 1056828416, 198946304, 437860096, 489023360, 773806400, 804661088, 914055184, 273280744, 1037913684, 701156878, 432031493 + ], + [ + 536870912, 268435456, 134217728, 469762048, 637534208, 1056964608, 226492416, 1010827264, 748683264, 149946368, 508035072, 947650560, 170786816, 139395072, 232751104, 59228160, 501424128, 520622080, 73197568, 1042154496, 241608192, 959685376, 1030788224, 638090944, 651976992, 132016720, 42385704, 996325972, 348686634, 230452819 + ], + [ + 536870912, 805306368, 671088640, 469762048, 167772160, 419430400, 394264576, 473956352, 799014912, 233832448, 455606272, 1033633792, 866516992, 761331712, 831619072, 288964608, 316989440, 199380992, 921946112, 420101120, 227484160, 1031560448, 796270464, 410575168, 952412384, 928127792, 66805768, 640028684, 69249034, 732965895 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 369098752, 587202560, 511705088, 859832320, 970981376, 347078656, 179830784, 371458048, 851836928, 756088832, 560562176, 795688960, 1035722752, 675524608, 159881216, 418460672, 198752768, 987094784, 589229440, 180619712, 66537248, 510228272, 401471496, 100385804, 857915914, 947280655 + ], + [ + 536870912, 268435456, 402653184, 335544320, 100663296, 721420288, 562036736, 264241152, 102760448, 164626432, 955777024, 354680832, 66453504, 693567488, 902266880, 1029652480, 1011605504, 246796288, 686786560, 310576128, 530135552, 982805248, 473838976, 955996736, 821921632, 914561744, 295200616, 496356052, 801009518, 440045265 + ], + [ + 536870912, 268435456, 671088640, 335544320, 838860800, 150994944, 109051904, 843055104, 824180736, 768606208, 275251200, 156499968, 243138560, 134152192, 406814720, 1021231104, 15622144, 204992512, 16496640, 1021938688, 504700416, 937301760, 930036096, 83335872, 630915168, 454663056, 741146728, 438475668, 858030178, 294083473 + ], + [ + 536870912, 805306368, 939524096, 872415232, 838860800, 654311424, 92274688, 1010827264, 736100352, 714080256, 769130496, 917766144, 925761536, 15269888, 303923200, 181649408, 715825152, 107941888, 227047424, 189647872, 598348288, 720328448, 759779456, 946723008, 236668064, 411525360, 244664840, 689851148, 599890574, 211833805 + ], + [ + 536870912, 805306368, 939524096, 469762048, 100663296, 1023410176, 411041792, 851443712, 312475648, 600834048, 159907840, 355205120, 160563200, 504430592, 749305856, 62767104, 536535040, 722284544, 176318464, 439878656, 634713600, 317154560, 287774336, 352729152, 488085344, 79674768, 998500360, 213500940, 236197390, 46617863 + ], + [ + 536870912, 268435456, 402653184, 469762048, 100663296, 989855744, 494927872, 1010827264, 937426944, 19922944, 481820672, 278134784, 15335424, 26673152, 455180288, 605044736, 262676480, 482136064, 119007232, 719336448, 934383104, 628661504, 120936064, 809163840, 656324960, 177074160, 137341416, 959728308, 121348110, 614436867 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 570425344, 889192448, 176160768, 666894336, 891289600, 982515712, 77070336, 873725952, 916586496, 293404672, 132087808, 648200192, 427646976, 64966656, 950175744, 243016704, 1012909568, 367228160, 480038528, 871254976, 736821536, 739336016, 827941000, 204835532, 984768942, 270849439 + ], + [ + 536870912, 268435456, 671088640, 469762048, 771751936, 385875968, 914358272, 700448768, 60817408, 590348288, 832045056, 379846656, 480378880, 693043200, 402751488, 604094464, 436314112, 620859392, 260163584, 138480640, 484506112, 156324608, 285803648, 67933504, 1000290784, 592007216, 770518888, 357485172, 637534210, 452984835 + ], + [ + 536870912, 805306368, 402653184, 872415232, 503316480, 587202560, 679477248, 171966464, 106954752, 439353344, 946339840, 82575360, 607780864, 233242624, 389316608, 796868608, 110125056, 712560640, 651503616, 361757696, 601417216, 323287296, 1064789632, 592306368, 715826976, 1000279856, 65071528, 871437308, 818456718, 956163521 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 838860800, 687865856, 411041792, 79691776, 627048448, 89128960, 326631424, 610009088, 581042176, 739835904, 1007517696, 526106624, 730128384, 944640000, 55805952, 1037149184, 666498560, 960250624, 468885120, 224486848, 827327968, 628628880, 56432136, 555897612, 425268878, 86819279 + ], + [ + 536870912, 268435456, 134217728, 738197504, 436207616, 285212672, 1048576000, 1035993088, 589299712, 709885952, 950534144, 73662464, 486146048, 318701568, 867532800, 169000960, 620371968, 654192640, 230004736, 756210688, 293267968, 884887296, 768878464, 430155200, 547493216, 572774768, 233018088, 331582644, 487833482, 159021519 + ], + [ + 536870912, 805306368, 939524096, 67108864, 234881024, 788529152, 343932928, 1027604480, 224395264, 504365056, 996671488, 272367616, 700055552, 426442752, 178421760, 112148480, 571301888, 1000476672, 892332032, 936184832, 25298432, 123649280, 691340672, 51897024, 251198752, 177502704, 900175144, 698430972, 397439782, 484038909 + ], + [ + 536870912, 805306368, 402653184, 603979776, 369098752, 352321536, 377487360, 658505728, 442499072, 449839104, 483917824, 214171648, 178913280, 460259328, 189038592, 493568000, 726589440, 963973120, 706959360, 875756544, 860528128, 8368384, 851278208, 891252288, 837652960, 654719728, 831055976, 534598844, 307198350, 905211461 + ], + [ + 536870912, 805306368, 402653184, 872415232, 838860800, 788529152, 444596224, 448790528, 547356672, 179306496, 845676544, 764149760, 480903168, 428277760, 329023488, 645087232, 828530688, 205172736, 194947072, 886590464, 702902784, 874928896, 78498944, 945466560, 546258976, 662830000, 524348584, 954328956, 80807054, 712528065 + ], + [ + 536870912, 805306368, 671088640, 872415232, 1040187392, 889192448, 377487360, 1027604480, 786432000, 418381824, 1004011520, 623116288, 124649472, 114753536, 155353088, 781565952, 1062690816, 830607360, 45447168, 679881728, 168498688, 165214464, 35963520, 116363840, 303447648, 123898256, 105138280, 425681052, 607089378, 758587089 + ], + [ + 536870912, 805306368, 671088640, 603979776, 1040187392, 520093696, 310378496, 549453824, 312475648, 428867584, 986185728, 145489920, 858128384, 540344320, 660832256, 837697536, 345612288, 642068480, 349870080, 8078336, 988450304, 547567872, 231718528, 533288256, 187495648, 912752624, 617883784, 848521292, 521561194, 770515897 + ], + [ + 536870912, 268435456, 134217728, 603979776, 905969664, 788529152, 8388608, 381681664, 245366784, 466616320, 904396800, 617873408, 983695360, 835911680, 82542592, 727171072, 685826048, 464539648, 211396608, 418245632, 849246720, 2408192, 433756544, 101642944, 304906848, 910094960, 787860072, 296963700, 765073514, 527310205 + ], + [ + 536870912, 268435456, 939524096, 738197504, 33554432, 16777216, 461373440, 1010827264, 362807296, 227540992, 653787136, 161218560, 833224704, 923598848, 634552320, 223395840, 328851456, 560844800, 128149504, 614059008, 99445248, 459518208, 1006235264, 941427392, 418113632, 388761232, 386041480, 612943556, 810844782, 534689691 + ], + [ + 536870912, 268435456, 671088640, 201326592, 369098752, 721420288, 562036736, 792723456, 1054867456, 632291328, 134742016, 1055129600, 611188736, 542310400, 606175232, 370262016, 173613056, 64802816, 558098432, 569988096, 898430464, 779865344, 366328448, 682057152, 437694304, 496908368, 54209512, 573844628, 899063810, 769527815 + ], + [ + 536870912, 268435456, 134217728, 603979776, 704643072, 922746880, 645922816, 725614592, 635437056, 1009778688, 585629696, 798228480, 1008336896, 97845248, 511344640, 86327296, 766746624, 597692416, 273684480, 1058546688, 232636928, 392121088, 915800960, 454200384, 108005152, 143145104, 191136648, 634637380, 340895522, 85534873 + ], + [ + 536870912, 268435456, 134217728, 67108864, 100663296, 150994944, 343932928, 264241152, 383778816, 636485632, 881328128, 657719296, 540672000, 501678080, 584679424, 980205568, 504782848, 256970752, 30996480, 904702976, 39254528, 267516160, 797528192, 884240320, 914015200, 373800816, 386468200, 695482804, 664527370, 708281605 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 503316480, 687865856, 478150656, 624951296, 861929472, 890241024, 506986496, 163315712, 814350336, 801439744, 483885056, 471842816, 164323328, 849653760, 415754240, 581317632, 993522176, 407799552, 512921216, 84538560, 502549600, 337590800, 499842184, 145011660, 331850470, 153583327 + ], + [ + 536870912, 268435456, 402653184, 603979776, 301989888, 889192448, 729808896, 188743680, 132120576, 500170752, 192413696, 654049280, 1041629184, 109379584, 946503680, 55820288, 449748992, 650760192, 487901184, 728902656, 960446976, 960617216, 585105536, 777028288, 607652960, 857490160, 382157448, 645749188, 366349542, 983941177 + ], + [ + 536870912, 805306368, 939524096, 335544320, 100663296, 956301312, 1015021568, 373293056, 501219328, 166723584, 361234432, 1052508160, 125435904, 878641152, 870350848, 753942528, 50946048, 66883584, 421263360, 779037696, 290051584, 270277888, 99336320, 359101376, 112468384, 252158512, 310685480, 951021820, 15294470, 386699273 + ], + [ + 536870912, 268435456, 671088640, 738197504, 838860800, 117440512, 998244352, 331350016, 119537664, 898629632, 566755328, 693895168, 142213120, 693567488, 81100800, 1002946560, 245178368, 693792768, 768075776, 127730688, 266015232, 780648192, 452802944, 699028672, 108968352, 876124080, 778356776, 1000241012, 805940098, 293415887 + ], + [ + 536870912, 805306368, 134217728, 201326592, 973078528, 251658240, 310378496, 1069547520, 190840832, 907018240, 1073217536, 698613760, 332005376, 784531456, 416186368, 91799552, 711303168, 715911168, 466798592, 263699456, 471716352, 542019840, 230221184, 931421248, 360349280, 441081520, 226673768, 493847484, 327793642, 1003303679 + ], + [ + 536870912, 268435456, 671088640, 469762048, 1040187392, 452984832, 914358272, 994050048, 656408576, 143654912, 146276352, 97779712, 395968512, 912326656, 112230400, 1000947712, 128770048, 112193536, 772528128, 559428608, 61086208, 30578944, 767317120, 123203008, 33489568, 265532112, 247226376, 97955844, 415184906, 234079239 + ], + [ + 536870912, 805306368, 939524096, 67108864, 503316480, 117440512, 159383552, 29360128, 639631360, 667942912, 577241088, 338427904, 212992000, 1058340864, 45580288, 946520064, 887136256, 510701568, 1064949760, 65313792, 663668224, 963527936, 102759552, 870804544, 641978080, 556652624, 271770248, 307541324, 836203630, 685453585 + ], + [ + 536870912, 805306368, 939524096, 335544320, 301989888, 251658240, 931135488, 549453824, 392167424, 313524224, 272105472, 238288896, 640811008, 698023936, 570851328, 615071744, 370991104, 1030746112, 5588992, 369284096, 232915456, 705831168, 982186112, 317667136, 76851680, 727896048, 72582120, 531335932, 461263206, 339605689 + ], + [ + 536870912, 805306368, 134217728, 201326592, 301989888, 285212672, 411041792, 37748736, 295698432, 324009984, 225968128, 764674048, 827981824, 912982016, 404914176, 905887744, 578330624, 102051840, 848967680, 822852608, 177360384, 729158400, 155476352, 367222336, 161360096, 1028139824, 475803880, 155674428, 697067242, 897464383 + ], + [ + 536870912, 268435456, 402653184, 67108864, 570425344, 587202560, 847249408, 138412032, 1063256064, 384827392, 457703424, 946601984, 560332800, 809304064, 1031700480, 147439616, 833396736, 1019727872, 367802368, 765854720, 505190912, 24039168, 498083200, 111712576, 1054683360, 21932912, 1017134472, 609324356, 840544998, 636842097 + ], + [ + 536870912, 805306368, 671088640, 469762048, 570425344, 218103808, 142606336, 952107008, 698351616, 783286272, 919076864, 404488192, 100007936, 654114816, 329744384, 761544704, 329474048, 735531008, 84674560, 344953856, 380177920, 93157632, 5147520, 889796416, 977053536, 470170352, 416574344, 518727500, 747261802, 337362679 + ], + [ + 536870912, 805306368, 134217728, 738197504, 33554432, 922746880, 343932928, 113246208, 681574400, 328204288, 303562752, 745275392, 1057882112, 207290368, 937984000, 289783808, 887824384, 337670144, 156248064, 817454080, 620622336, 999777024, 301425024, 885401664, 139396512, 968523280, 983086632, 279725404, 78543370, 625708807 + ], + [ + 536870912, 268435456, 671088640, 738197504, 905969664, 587202560, 494927872, 4194304, 467664896, 902823936, 299368448, 437518336, 5373952, 851247104, 439255040, 498221056, 476897280, 309751808, 501626880, 316652544, 731539968, 198216448, 249057408, 429185984, 252871968, 47998160, 213803656, 168549572, 870868906, 404551707 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 771751936, 922746880, 864026624, 289406976, 123731968, 1034944512, 1036517376, 395051008, 934412288, 124059648, 1064206336, 49168384, 883843072, 676311040, 952014848, 739757056, 824926720, 147869440, 158864256, 113552192, 1056920800, 150428496, 903582088, 242816068, 222674794, 1002343455 + ], + [ + 536870912, 805306368, 134217728, 738197504, 973078528, 318767104, 1065353216, 759169024, 350224384, 829423616, 755499008, 246153216, 360054784, 69140480, 251822080, 802996224, 8298496, 783544320, 208971776, 46363648, 603729408, 330236160, 900353664, 165724352, 871370912, 852083600, 227319464, 187052700, 222754858, 469124695 + ], + [ + 536870912, 268435456, 402653184, 469762048, 234881024, 587202560, 1031798784, 130023424, 991952896, 877658112, 769130496, 533987328, 580255744, 735117312, 253263872, 1047838720, 1049026560, 401174528, 20813824, 1059793920, 465296896, 717367552, 797440640, 392766144, 8130720, 575374768, 487299080, 728378372, 341532166, 3336455 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 838860800, 822083584, 343932928, 826277888, 752877568, 544210944, 459800576, 43778048, 1035075584, 636157952, 838828032, 304136192, 475013120, 339292160, 455473152, 1062648832, 891135488, 963823872, 80457344, 808378304, 936942624, 349473328, 620708392, 815808308, 974219938, 324606459 + ], + [ + 536870912, 805306368, 939524096, 335544320, 570425344, 16777216, 796917760, 708837376, 509607936, 212860928, 601358336, 130809856, 49414144, 481886208, 352157696, 862699520, 286629888, 952012800, 218810368, 765811712, 593887744, 516332288, 223750528, 1054741696, 632969568, 343714832, 833331720, 297011980, 984539534, 465717445 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 301989888, 318767104, 327155712, 490733568, 178257920, 611319808, 491257856, 821821440, 929693696, 94437376, 904953856, 722059264, 366862336, 475697152, 21600256, 855383040, 476785152, 706786560, 984691584, 849982016, 573373408, 475251024, 991289352, 568758276, 75733006, 791485455 + ], + [ + 536870912, 805306368, 134217728, 872415232, 905969664, 251658240, 763363328, 784334848, 828375040, 986710016, 182976512, 302252032, 507379712, 56557568, 59670528, 208060416, 1055088640, 446484480, 618899456, 798770176, 207876608, 568137984, 121773952, 640475328, 89896160, 464647952, 137942248, 619521820, 238779626, 610362129 + ], + [ + 536870912, 268435456, 402653184, 603979776, 301989888, 989855744, 1048576000, 1061158912, 375390208, 34603008, 115867648, 197918720, 417202176, 519766016, 996769792, 1040990208, 1006624768, 361410560, 319866880, 929590272, 912896, 788461824, 638249856, 1003588544, 466102048, 364654992, 52896424, 1063207764, 742125070, 281671949 + ], + [ + 536870912, 268435456, 134217728, 872415232, 1040187392, 1023410176, 763363328, 876609536, 10485760, 999292928, 749207552, 509870080, 331481088, 508231680, 503283712, 490061824, 1007378432, 73338880, 1025783808, 769897472, 152815104, 473373440, 841065344, 89217216, 1053332704, 898963312, 597308136, 519445620, 708847978, 765538489 + ], + [ + 536870912, 805306368, 402653184, 201326592, 100663296, 654311424, 394264576, 230686720, 748683264, 303038464, 295174144, 747372544, 924975104, 1022820352, 846757888, 360529920, 994746368, 236146688, 448759808, 936231936, 381940224, 432896, 479206784, 282650688, 74228384, 793983600, 39832872, 935070012, 611045902, 63146767 + ], + [ + 536870912, 805306368, 402653184, 201326592, 100663296, 352321536, 645922816, 884998144, 257949696, 261095424, 946339840, 356253696, 635043840, 660537344, 997228544, 28917760, 83140608, 789991424, 16619520, 909777920, 386880000, 871972096, 257259392, 937932736, 990187168, 493828400, 854078248, 402518012, 666581006, 38751247 + ], + [ + 536870912, 268435456, 939524096, 67108864, 33554432, 117440512, 75497472, 247463936, 622854144, 592445440, 426246144, 207355904, 679608320, 841285632, 1062633472, 755679232, 344563712, 523063296, 691787776, 693179392, 845733376, 920450304, 658729088, 377783360, 289859936, 453145040, 275050120, 683058500, 763002862, 733057169 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 436207616, 822083584, 260046848, 71303168, 861929472, 842006528, 137887744, 1040973824, 129368064, 637337600, 766410752, 992034816, 55664640, 1057525760, 531916800, 385526784, 799713792, 832726784, 697725824, 120453824, 31953376, 863339632, 492477320, 540743364, 353033186, 833762175 + ], + [ + 536870912, 805306368, 671088640, 335544320, 100663296, 855638016, 612368384, 717225984, 304087040, 95420416, 1041760256, 1042546688, 770310144, 373227520, 707559424, 522633216, 780722176, 386732032, 471263232, 659627008, 948552192, 1007492864, 77019264, 529644352, 531138784, 775739376, 886036584, 425046204, 634581634, 61581385 + ], + [ + 536870912, 805306368, 939524096, 738197504, 905969664, 486539264, 662700032, 398458880, 987758592, 1005584384, 446169088, 356253696, 959315968, 212402176, 776306688, 358858752, 861822976, 754003968, 504932352, 746429440, 697200128, 830050048, 256740224, 292984512, 687186144, 224129520, 615728648, 341299980, 233145742, 238168523 + ], + [ + 536870912, 268435456, 402653184, 872415232, 838860800, 520093696, 696254464, 750780416, 1033895936, 464519168, 113770496, 409206784, 978714624, 318308352, 258768896, 823312384, 39755776, 943460352, 520796160, 1038298112, 452384256, 935970048, 551848320, 1041689664, 857309216, 20727344, 193621512, 1067706628, 370597766, 253356365 + ], + [ + 536870912, 268435456, 939524096, 469762048, 100663296, 452984832, 276824064, 121634816, 631242752, 265289728, 315097088, 797179904, 623771648, 695533568, 695631872, 312000512, 546070528, 223080448, 833304576, 215692288, 1061331456, 38734080, 1002755200, 604959552, 65359520, 522160432, 1062046856, 464205636, 970609838, 281244727 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 33554432, 620756992, 914358272, 71303168, 664797184, 883949568, 182976512, 1021575168, 825360384, 27852800, 80052224, 1027751936, 832626688, 531730432, 325675008, 388256768, 642920960, 871961856, 733843840, 1002321216, 289290784, 662617104, 769634824, 334451980, 524775810, 553821519 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 167772160, 989855744, 125829120, 4194304, 392167424, 632291328, 272105472, 275513344, 790233088, 917831680, 864518144, 913719296, 19881984, 485724160, 533854208, 856247296, 345319936, 332852992, 557816704, 484138176, 664071136, 408374672, 58708360, 213590988, 262473834, 858725727 + ], + [ + 536870912, 268435456, 402653184, 872415232, 167772160, 251658240, 478150656, 708837376, 530579456, 187695104, 1062731776, 624689152, 45481984, 530513920, 685473792, 857817088, 695328768, 217657344, 269322240, 955173888, 690146816, 481086208, 425703040, 356204096, 196147872, 588820112, 329006248, 604498324, 319202350, 730213593 + ], + [ + 536870912, 268435456, 671088640, 872415232, 436207616, 721420288, 998244352, 884998144, 333447168, 709885952, 974651392, 815529984, 802291712, 735772672, 100630528, 197181440, 576741376, 495988736, 645408768, 873223168, 757801472, 177726720, 620096384, 57138496, 572319392, 127064752, 830106792, 227453876, 48842018, 653616121 + ], + [ + 536870912, 268435456, 134217728, 469762048, 838860800, 922746880, 612368384, 197132288, 148897792, 164626432, 864550912, 608960512, 1029308416, 83558400, 319520768, 640925696, 963059712, 366522368, 444860416, 624405504, 1094144, 342463744, 488409984, 722603968, 760641952, 872506736, 1040243112, 218174836, 260075946, 490850675 + ], + [ + 536870912, 268435456, 402653184, 335544320, 637534208, 83886080, 679477248, 717225984, 740294656, 1028653056, 722993152, 146014208, 939917312, 237961216, 255033344, 124338176, 847044608, 258691072, 62699520, 181066752, 44956160, 909333248, 367603072, 935189312, 1019888608, 531366736, 179462632, 422091860, 513633902, 689625105 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 33554432, 822083584, 713031680, 297795584, 933232640, 311427072, 362283008, 428081152, 940441600, 928710656, 1026392064, 142786560, 944283648, 209547264, 62642176, 769408000, 237718016, 700840704, 569318784, 522970688, 323237344, 942546128, 344682600, 64226964, 481767306, 663703883 + ], + [ + 536870912, 268435456, 134217728, 201326592, 100663296, 956301312, 461373440, 549453824, 639631360, 653262848, 1009254400, 40632320, 852885504, 729088000, 506626048, 931086336, 718921728, 642052096, 884729856, 329485312, 172457472, 198042880, 652627328, 175949376, 305073632, 1036067952, 664820616, 825356100, 881450594, 433977139 + ], + [ + 536870912, 268435456, 134217728, 67108864, 973078528, 150994944, 142606336, 851443712, 912261120, 355467264, 376963072, 857997312, 859701248, 732495872, 632061952, 327303168, 163782656, 492982272, 909346816, 830186496, 774350336, 658361088, 925603200, 200251840, 195149856, 80742768, 101256712, 511524612, 705379202, 520074945 + ], + [ + 536870912, 268435456, 671088640, 335544320, 704643072, 83886080, 562036736, 297795584, 882900992, 506462208, 403177472, 877920256, 652869632, 644153344, 954368000, 19939328, 76029952, 940838912, 1032488960, 603282432, 442115584, 489482496, 861298560, 302675264, 624188192, 913992464, 224188296, 557787460, 676232490, 900104725 + ], + [ + 536870912, 268435456, 939524096, 872415232, 570425344, 150994944, 25165824, 809500672, 446693376, 340787200, 739770368, 15466496, 251527168, 403374080, 991526912, 913129472, 406740992, 745254912, 791205888, 742720512, 201059840, 818996992, 467251072, 957105728, 1016023456, 864237456, 873269288, 923768532, 113503750, 959244041 + ], + [ + 536870912, 805306368, 671088640, 603979776, 973078528, 16777216, 813694976, 834666496, 589299712, 600834048, 383254528, 88342528, 599392256, 849149952, 645890048, 149307392, 331587584, 927469568, 217966592, 290337792, 701396480, 202360064, 1026481280, 1006585280, 665228192, 304256144, 574139016, 45383884, 288509738, 1061212505 + ], + [ + 536870912, 805306368, 402653184, 872415232, 973078528, 16777216, 310378496, 725614592, 1012924416, 164626432, 586678272, 863240192, 347471872, 811663360, 936476672, 33079296, 351641600, 393728000, 641796096, 283186176, 26319360, 957891328, 962961024, 544153536, 606343072, 588152752, 477470728, 221761548, 278988806, 108073997 + ], + [ + 536870912, 805306368, 939524096, 738197504, 301989888, 452984832, 696254464, 675282944, 102760448, 835715072, 1045954560, 914096128, 439484416, 139526144, 504987648, 610123776, 367222784, 1057591296, 451237888, 1068403712, 869474816, 383787264, 825300608, 577248960, 546636256, 510044304, 416765960, 738167820, 130720270, 96329995 + ], + [ + 536870912, 805306368, 134217728, 603979776, 905969664, 687865856, 58720256, 88080384, 216006656, 97517568, 668467200, 83623936, 123076608, 337051648, 32931840, 262586368, 155181056, 924995584, 480581632, 753533952, 748727808, 682625280, 810076032, 558180672, 918214304, 339281936, 464279208, 776980508, 1028372138, 965842965 + ], + [ + 536870912, 805306368, 402653184, 335544320, 436207616, 452984832, 327155712, 339738624, 824180736, 74448896, 906493952, 537657344, 100270080, 389349376, 39813120, 1030995968, 234364928, 1011191808, 232175616, 171961344, 1050814976, 557944064, 329383296, 11545408, 350749408, 454895632, 497217416, 381782604, 98694502, 1049632341 + ], + [ + 536870912, 268435456, 671088640, 67108864, 301989888, 150994944, 1031798784, 390070272, 417333248, 655360000, 749207552, 515112960, 680919040, 887554048, 656375808, 56803328, 898686976, 627666944, 160806912, 732369920, 738102784, 510810368, 339241344, 341688512, 1061396320, 975181008, 1018218344, 693727444, 403468642, 889912789 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 704643072, 150994944, 192937984, 88080384, 459276288, 869269504, 783810560, 971767808, 61997056, 84738048, 656637952, 232079360, 815685632, 111022080, 362752000, 522177536, 769606144, 436139776, 944737408, 782748352, 1018306528, 495844688, 686025864, 611637964, 930002914, 160919903 + ], + [ + 536870912, 268435456, 671088640, 872415232, 100663296, 452984832, 243269632, 952107008, 161480704, 498073600, 645398528, 737935360, 212205568, 18808832, 163807232, 236240896, 265445376, 954060800, 1071106048, 499571712, 84888064, 436932352, 932241024, 780777280, 778391456, 965441552, 584156584, 224966420, 817183522, 384028761 + ], + [ + 536870912, 268435456, 671088640, 335544320, 905969664, 721420288, 645922816, 616562688, 174063616, 355467264, 495452160, 894697472, 55443456, 679936000, 359890944, 174899200, 416505856, 935153664, 715835392, 704748544, 419523072, 327201024, 1027613824, 1042322112, 277975392, 609762192, 422411112, 569592468, 195936226, 590497873 + ], + [ + 536870912, 805306368, 402653184, 67108864, 570425344, 285212672, 511705088, 725614592, 480247808, 275775488, 167247872, 892600320, 541982720, 674824192, 148209664, 564051968, 154214400, 744001536, 667174912, 620155904, 850217472, 929819904, 899659648, 53589440, 559488160, 524675568, 1018612232, 562834700, 316348294, 193455553 + ], + [ + 536870912, 268435456, 671088640, 469762048, 838860800, 788529152, 880803840, 1002438656, 958398464, 831520768, 1042808832, 435421184, 790495232, 938409984, 909606912, 379240448, 954736640, 726970368, 969885696, 388410368, 359862784, 423365376, 475733888, 273242816, 243659616, 528991888, 547560296, 393484948, 937353570, 542100883 + ], + [ + 536870912, 805306368, 671088640, 872415232, 436207616, 251658240, 394264576, 423624704, 144703488, 978321408, 790102016, 1062469632, 900333568, 919273472, 502956032, 315867136, 120479744, 87601152, 885377024, 886240256, 372145664, 800594688, 17127808, 682785088, 849326048, 634425520, 844713960, 99934396, 888825826, 340944049 + ], + [ + 536870912, 268435456, 402653184, 872415232, 167772160, 654311424, 310378496, 843055104, 56623104, 441450496, 8912896, 802947072, 38141952, 970784768, 323387392, 710787072, 713498624, 620597248, 880154624, 495256576, 810781184, 698818304, 1053579392, 774806336, 328296032, 103410032, 489445512, 87989060, 284780134, 317057405 + ], + [ + 536870912, 805306368, 134217728, 201326592, 570425344, 520093696, 494927872, 448790528, 270532608, 984612864, 957874176, 1006895104, 411172864, 254738432, 783319040, 790216704, 84156416, 872640512, 896460800, 651203584, 46791168, 206337792, 462300288, 306246976, 878820576, 131161648, 440961640, 269305980, 586082314, 521180175 + ], + [ + 536870912, 268435456, 939524096, 469762048, 905969664, 452984832, 998244352, 926941184, 606076928, 858783744, 480772096, 214695936, 898236416, 560660480, 658210816, 260194304, 190226432, 804851712, 150259712, 866096128, 296021504, 447131392, 925943424, 648567744, 432927136, 151760880, 464179624, 794558452, 588462502, 328154099 + ], + [ + 536870912, 268435456, 134217728, 335544320, 369098752, 520093696, 75497472, 390070272, 60817408, 621805568, 731381760, 538181632, 991559680, 391708672, 678723584, 384450560, 410099712, 266874880, 1039972352, 132547584, 524225024, 847996160, 796970112, 365004480, 65097120, 909121616, 264866312, 388769028, 983559298, 278591173 + ], + [ + 536870912, 268435456, 134217728, 872415232, 234881024, 855638016, 360710144, 717225984, 111149056, 1049624576, 642252800, 861143040, 181534720, 335216640, 488603648, 768983040, 429088768, 228233216, 741328896, 495748096, 13566464, 234708736, 670457728, 219215808, 461905504, 645202288, 428080232, 680726132, 152767466, 309259705 + ], + [ + 536870912, 268435456, 939524096, 469762048, 771751936, 452984832, 427819008, 683671552, 81788928, 1041235968, 230162432, 43253760, 856031232, 711000064, 156270592, 513392640, 333766656, 493842432, 590206976, 932334592, 644318720, 145835776, 168411264, 186488256, 31148192, 534410800, 752541704, 291139588, 194729998, 981109767 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 369098752, 754974720, 444596224, 515899392, 119537664, 613416960, 566755328, 656146432, 54657024, 670892032, 947027968, 56934400, 604463104, 1021997056, 252774400, 596190208, 738049536, 108248320, 711264896, 344329024, 422248032, 1068612432, 56158856, 332708676, 48141934, 746581855 + ], + [ + 536870912, 268435456, 134217728, 738197504, 301989888, 788529152, 763363328, 289406976, 257949696, 579862528, 935854080, 562298880, 372113408, 629342208, 813268992, 809287680, 716382208, 369160192, 16869376, 411063296, 1069581824, 564158720, 330307456, 934921920, 630995040, 251905616, 817465832, 874353044, 71519754, 1020790031 + ], + [ + 536870912, 268435456, 402653184, 67108864, 369098752, 654311424, 125829120, 884998144, 471859200, 294649856, 344457216, 985399296, 210370560, 1042481152, 672104448, 445464576, 408051712, 582438912, 535308288, 97383424, 716325376, 34007808, 678544256, 700026304, 350521120, 241091312, 329557288, 952072692, 622153390, 673644597 + ], + [ + 536870912, 268435456, 134217728, 335544320, 637534208, 855638016, 612368384, 843055104, 216006656, 1051721728, 359137280, 450625536, 492175360, 995295232, 858882048, 313049088, 503111680, 516395008, 749447168, 261438464, 379221504, 951850240, 145130112, 257603264, 10346912, 364345936, 736279848, 22603156, 183871498, 32128001 + ], + [ + 536870912, 268435456, 939524096, 201326592, 369098752, 184549376, 528482304, 406847488, 362807296, 802160640, 115867648, 892600320, 431882240, 608239616, 731938816, 282181632, 57171968, 812953600, 413030400, 206699520, 547897856, 529886464, 871308928, 669615936, 531984800, 562033136, 740327432, 345096196, 952655886, 413446147 + ], + [ + 536870912, 805306368, 939524096, 872415232, 704643072, 822083584, 964689920, 104857600, 1042284544, 11534336, 133693440, 150208512, 86638592, 458424320, 635863040, 653082624, 152035328, 17838080, 503904256, 732746752, 934270464, 845176576, 1066520192, 113887040, 1028517856, 436138032, 801651176, 13479740, 230651750, 350824561 + ], + [ + 536870912, 805306368, 939524096, 201326592, 167772160, 218103808, 612368384, 943718400, 576716800, 1007681536, 172490752, 342097920, 851050496, 609550336, 696483840, 468238336, 534110208, 71536640, 390662144, 954528768, 1056598528, 3495680, 311685760, 941746496, 393316256, 752457104, 762092168, 658394444, 993985966, 960472723 + ], + [ + 536870912, 268435456, 939524096, 67108864, 637534208, 922746880, 612368384, 373293056, 618659840, 1055916032, 323485696, 254017536, 664403968, 664993792, 705658880, 177225728, 905535488, 864866304, 281978880, 338734080, 904441344, 188051712, 958546560, 961444544, 603008224, 180992944, 283454184, 616261300, 510805606, 647441781 + ], + [ + 536870912, 268435456, 671088640, 201326592, 436207616, 452984832, 830472192, 759169024, 903872512, 667942912, 336068608, 1036255232, 512098304, 362217472, 557809664, 717930496, 294952960, 751792128, 70395904, 958948352, 78982656, 834580736, 1024182144, 280286144, 532630496, 403325648, 741663720, 41936596, 707456482, 583329751 + ], + [ + 536870912, 805306368, 134217728, 738197504, 167772160, 318767104, 92274688, 96468992, 203423744, 420478976, 642252800, 369885184, 900071424, 803667968, 218529792, 968278016, 623878144, 4976640, 745629696, 272122880, 758508032, 957598464, 892691328, 756187584, 456419744, 403851408, 129296808, 190023836, 198560170, 463648919 + ], + [ + 536870912, 805306368, 402653184, 469762048, 637534208, 587202560, 1065353216, 868220928, 811597824, 334495744, 354942976, 639369216, 446562304, 80281600, 153976832, 1045872640, 1038475264, 796569600, 531814400, 882875392, 331935232, 346897152, 345404288, 923074368, 332064736, 918221168, 47386120, 1072597772, 815868806, 873571143 + ], + [ + 536870912, 268435456, 402653184, 872415232, 167772160, 620756992, 494927872, 507510784, 425721856, 487587840, 465043456, 249823232, 261750784, 1018494976, 180518912, 201441280, 771825664, 922783744, 209750016, 163625984, 572643840, 435169024, 417864320, 205264576, 477011872, 681025808, 949097096, 156854980, 515138982, 331486749 + ], + [ + 536870912, 268435456, 402653184, 335544320, 33554432, 251658240, 578813952, 784334848, 1063256064, 770703360, 352845824, 627834880, 512884736, 6225920, 526221312, 192561152, 327376896, 870789120, 270084096, 450202624, 131469824, 485573888, 646539392, 674045376, 884128288, 328150384, 461714088, 634339508, 19251342, 266260929 + ], + [ + 536870912, 805306368, 671088640, 603979776, 100663296, 654311424, 25165824, 381681664, 379584512, 510656512, 258473984, 557056000, 638451712, 130744320, 99385344, 695386112, 121724928, 408981504, 80758784, 857216000, 257722880, 565918464, 914705024, 38256320, 609191904, 1059809872, 830244200, 462143644, 369952898, 1046630853 + ], + [ + 536870912, 805306368, 939524096, 738197504, 704643072, 822083584, 478150656, 1019215872, 908066816, 680525824, 239599616, 620494848, 377356288, 890044416, 566722560, 38322176, 1056759808, 528388096, 93186048, 923153408, 90746368, 183350528, 771109504, 391129920, 166221664, 1043165104, 265730696, 968970060, 480276846, 928104123 + ], + [ + 536870912, 268435456, 939524096, 469762048, 436207616, 788529152, 847249408, 180355072, 698351616, 951058432, 326631424, 600571904, 14811136, 887422976, 973504512, 266518528, 375742464, 147296256, 977491968, 886318080, 884915712, 722436352, 1056421760, 704276672, 700046048, 577629008, 475246984, 563977668, 751463278, 310408855 + ], + [ + 536870912, 268435456, 134217728, 738197504, 637534208, 620756992, 343932928, 297795584, 786432000, 466616320, 1048051712, 710148096, 200146944, 485556224, 1061715968, 234635264, 818110464, 717893632, 135702528, 98919424, 646393344, 482109184, 501425792, 955912128, 373207200, 394916464, 161302536, 1003688964, 617801218, 726872843 + ], + [ + 536870912, 268435456, 402653184, 201326592, 436207616, 620756992, 578813952, 138412032, 559939584, 397410304, 394788864, 208928768, 819068928, 19333120, 775258112, 1018314752, 538419200, 670904320, 782743552, 16096256, 462644736, 633827584, 977562240, 983287744, 938680032, 351696816, 730690664, 613331060, 219277966, 228165575 + ], + [ + 536870912, 268435456, 134217728, 67108864, 33554432, 452984832, 780140544, 960495616, 1038090240, 298844160, 633864192, 184811520, 79560704, 605356032, 139886592, 417415168, 978362368, 654856192, 1009055744, 642737152, 556536320, 493492992, 669123712, 403136832, 820577952, 586494896, 654736520, 208160068, 146093218, 812071089 + ], + [ + 536870912, 805306368, 134217728, 67108864, 369098752, 218103808, 780140544, 507510784, 278921216, 642777088, 246939648, 431751168, 426901504, 558039040, 1045069824, 792641536, 274259968, 390942720, 1033549824, 608603136, 629530112, 881765120, 1066488192, 148381760, 873306016, 196771120, 408375208, 765223228, 107104682, 115070525 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 973078528, 50331648, 1065353216, 180355072, 782237696, 1028653056, 93847552, 636747776, 354287616, 335347712, 97746944, 860241920, 1009344512, 215814144, 121812992, 922668032, 785194496, 1035620608, 729538688, 266059712, 428587040, 529705648, 178767496, 840524492, 590620330, 700339327 + ], + [ + 536870912, 805306368, 939524096, 335544320, 33554432, 922746880, 8388608, 213909504, 1038090240, 219152384, 889716736, 971767808, 802553856, 766705664, 642285568, 340541440, 1038573568, 155955200, 305997824, 205519872, 936247808, 290961664, 141782912, 36281536, 874312992, 206565584, 991402152, 877843740, 291013126, 38074633 + ], + [ + 536870912, 268435456, 671088640, 469762048, 771751936, 989855744, 226492416, 1002438656, 631242752, 9437184, 739770368, 808189952, 275120128, 873398272, 726368256, 300466176, 277159936, 755159040, 352143360, 656294912, 1066543616, 1038483200, 162678656, 95760704, 965450016, 1019827344, 894720808, 251395988, 337764002, 89155027 + ], + [ + 536870912, 805306368, 939524096, 603979776, 436207616, 553648128, 1048576000, 926941184, 396361728, 200278016, 315097088, 20709376, 339607552, 291569664, 647069696, 978960384, 946151424, 400216064, 360318976, 839611392, 713226752, 1017044224, 789639040, 613953088, 17090016, 491395056, 690135048, 359534604, 953722894, 19227657 + ], + [ + 536870912, 805306368, 134217728, 201326592, 100663296, 922746880, 276824064, 633339904, 169869312, 1041235968, 284688384, 1059848192, 95551488, 395771904, 1069580288, 52543488, 495984640, 800608256, 567117824, 369310720, 205433344, 1073086208, 227434880, 559699776, 674934432, 666049776, 446123304, 373299388, 224428042, 619823119 + ], + [ + 536870912, 268435456, 939524096, 738197504, 33554432, 989855744, 25165824, 801112064, 1012924416, 116391936, 1033371648, 574357504, 158203904, 555286528, 830242816, 911196160, 550002688, 557092864, 104470528, 584215552, 62320128, 973372160, 348265344, 329196224, 914479840, 1010890992, 278982152, 387021572, 380148622, 415621835 + ], + [ + 536870912, 268435456, 671088640, 469762048, 570425344, 922746880, 8388608, 675282944, 807403520, 831520768, 688390144, 520880128, 487194624, 161021952, 126124032, 197607424, 91480064, 845975552, 993687552, 297837568, 903885312, 712009984, 1048105088, 183836224, 490701664, 1002955216, 1030900232, 107793668, 87745162, 79722311 + ], + [ + 536870912, 805306368, 671088640, 469762048, 771751936, 486539264, 8388608, 171966464, 106954752, 714080256, 390594560, 181141504, 65667072, 547291136, 392200192, 470859776, 873046016, 1043173376, 272340992, 741862400, 1039980032, 76718336, 850118528, 394198720, 825275424, 108561712, 1018535336, 392079100, 734109698, 312578059 + ], + [ + 536870912, 268435456, 671088640, 469762048, 301989888, 989855744, 645922816, 608174080, 1050673152, 758120448, 46661632, 952369152, 423231488, 275841024, 434667520, 590692352, 252895232, 304451584, 850089984, 193557504, 769999360, 734668032, 467227008, 427635264, 311852064, 876603600, 522967048, 826815492, 50700810, 911914247 + ], + [ + 536870912, 805306368, 134217728, 603979776, 301989888, 1023410176, 880803840, 1019215872, 966787072, 888143872, 376963072, 373555200, 315752448, 419627008, 172654592, 257343488, 670162944, 301494272, 486807552, 674495488, 856832512, 606267136, 175827072, 76472128, 390404960, 676505840, 650306408, 208282876, 484852074, 1030356981 + ], + [ + 536870912, 805306368, 939524096, 335544320, 234881024, 687865856, 260046848, 297795584, 715128832, 105906176, 754450432, 538181632, 1029832704, 255000576, 499810304, 752828416, 171827200, 449744896, 77944832, 564814848, 380570112, 114609920, 960734592, 992192064, 273886432, 121325808, 997618920, 122760444, 1064926950, 332784633 + ], + [ + 536870912, 805306368, 671088640, 469762048, 234881024, 117440512, 729808896, 918552576, 824180736, 47185920, 344457216, 915144704, 600440832, 176750592, 697139200, 1011564544, 776593408, 296611840, 303790080, 662748160, 549471744, 35713280, 995207808, 726229568, 724305248, 1012552912, 434128392, 753987852, 165259914, 113599047 + ], + [ + 536870912, 805306368, 939524096, 201326592, 905969664, 1023410176, 746586112, 482344960, 23068672, 1051721728, 742916096, 203685888, 603324416, 266141696, 689668096, 969850880, 617668608, 192540672, 606881792, 141734912, 419151360, 633210624, 16332672, 795717440, 1012109216, 459976816, 484884872, 574954572, 1053230638, 752097331 + ], + [ + 536870912, 268435456, 134217728, 603979776, 33554432, 922746880, 260046848, 222298112, 434110464, 363855872, 462946304, 94633984, 951975936, 209256448, 286556160, 296108032, 404496384, 814387200, 734984192, 289463296, 669039104, 212866816, 85582208, 845487808, 345974304, 48791152, 194812424, 63604484, 724507010, 443663049 + ], + [ + 536870912, 805306368, 134217728, 469762048, 973078528, 1056964608, 545259520, 658505728, 291504128, 347078656, 74973184, 742129664, 878051328, 482017280, 967081984, 463192064, 905289728, 26390528, 672229376, 568957952, 420851200, 165849344, 348781184, 910541888, 157977888, 292338896, 668975016, 194925724, 746583178, 311352651 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 973078528, 788529152, 394264576, 88080384, 601882624, 829423616, 285736960, 883163136, 672792576, 36110336, 308379648, 825311232, 845684736, 722743296, 632465408, 185779200, 226694656, 335246592, 525808768, 23688128, 378873184, 938660336, 57905128, 62006068, 236068870, 218312715 + ], + [ + 536870912, 805306368, 671088640, 872415232, 234881024, 385875968, 360710144, 104857600, 148897792, 1037041664, 46661632, 418119680, 920780800, 948895744, 598507520, 713211904, 497016832, 4542464, 404621312, 503706624, 218025472, 433388800, 389520768, 62478016, 840186912, 899106288, 612999592, 537727804, 590552450, 239572673 + ], + [ + 536870912, 805306368, 402653184, 738197504, 503316480, 184549376, 1031798784, 4194304, 1059061760, 391118848, 318242816, 585367552, 377356288, 630784000, 244678656, 970375168, 746872832, 311390208, 1022466048, 90770432, 234631680, 321569024, 472819328, 98586048, 1001407008, 701082480, 166580744, 796094732, 937123462, 893792715 + ], + [ + 536870912, 805306368, 671088640, 67108864, 301989888, 184549376, 310378496, 1002438656, 6291456, 32505856, 688390144, 108265472, 908460032, 653066240, 749436928, 95830016, 890544128, 961957888, 170145792, 935306240, 971068928, 414281472, 984126848, 65334592, 215890720, 43020528, 242834312, 784102988, 1060356266, 297424561 + ], + [ + 536870912, 805306368, 671088640, 603979776, 301989888, 218103808, 327155712, 440401920, 329252864, 384827392, 936902656, 61603840, 242876416, 816644096, 385581056, 241975296, 630890496, 285003776, 5425152, 844647424, 921442816, 727437568, 194784640, 985837504, 93343968, 424242192, 241446280, 148811724, 336744682, 49835033 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 771751936, 788529152, 696254464, 364904448, 819986432, 821035008, 940048384, 1024196608, 1018822656, 731316224, 247234560, 538132480, 659169280, 404623360, 1064323072, 382243840, 778940928, 613073152, 201213056, 268459456, 671157536, 604078896, 302115240, 16813820, 109087886, 1010862531 + ], + [ + 536870912, 805306368, 671088640, 67108864, 100663296, 1023410176, 964689920, 339738624, 102760448, 948961280, 400031744, 144441344, 582615040, 983629824, 156336128, 800669696, 153886720, 259141632, 891611136, 144067584, 491971072, 330600704, 240071808, 776943296, 508500192, 911192016, 843980808, 877604876, 156198922, 818809857 + ], + [ + 536870912, 268435456, 402653184, 738197504, 838860800, 587202560, 142606336, 767557632, 547356672, 380633088, 1054343168, 586416128, 779223040, 722141184, 735019008, 1017462784, 452665344, 863449088, 348153856, 790662144, 905024000, 246996736, 224679552, 5970496, 851869408, 1016625648, 823446760, 279156468, 373486190, 353566911 + ], + [ + 536870912, 268435456, 939524096, 738197504, 771751936, 721420288, 578813952, 884998144, 723517440, 317718528, 92798976, 157548544, 506068992, 356843520, 677019648, 453820416, 715120640, 639086592, 418625536, 60302336, 129818112, 217554176, 10713472, 379701568, 380663456, 661231120, 355768712, 823294276, 759811758, 608481819 + ], + [ + 536870912, 805306368, 402653184, 603979776, 503316480, 1023410176, 1031798784, 281018368, 492830720, 103809024, 87556096, 672923648, 709754880, 355139584, 274235392, 573390848, 225959936, 976670720, 613914624, 658916352, 755894784, 327941376, 931701376, 912559168, 250805024, 599042960, 901436328, 45193948, 108653070, 12397829 + ], + [ + 536870912, 805306368, 939524096, 469762048, 301989888, 754974720, 578813952, 423624704, 870318080, 967835648, 845676544, 827588608, 532545536, 112001024, 160661504, 192856064, 730619904, 469946368, 604456960, 501343232, 917598720, 99140352, 378823552, 656358976, 570205216, 550174000, 285456776, 914819404, 1017191854, 424735863 + ], + [ + 536870912, 805306368, 402653184, 469762048, 771751936, 285212672, 578813952, 322961408, 559939584, 797966336, 904396800, 469499904, 700841984, 482934784, 613253120, 629063680, 796778496, 126283776, 690571264, 358380544, 1031219712, 424698624, 407410816, 315456832, 211689696, 816634032, 244271624, 1032082188, 433205382, 670234951 + ], + [ + 536870912, 805306368, 134217728, 335544320, 301989888, 117440512, 931135488, 197132288, 861929472, 204472320, 801636352, 595329024, 24772608, 929366016, 532643840, 218841088, 369893376, 512970752, 185194496, 60558336, 478852608, 953007872, 359830400, 796508992, 116686176, 128424464, 768597384, 627187788, 564134114, 835824213 + ], + [ + 536870912, 268435456, 671088640, 335544320, 234881024, 520093696, 260046848, 977272832, 60817408, 412090368, 26738688, 309592064, 381550592, 810745856, 303661056, 573947904, 740286464, 742641664, 675350528, 379667456, 772820480, 1062805248, 705974656, 684608576, 628765024, 589588816, 616967912, 1522196, 422465026, 977936129 + ], + [ + 536870912, 805306368, 939524096, 738197504, 771751936, 721420288, 914358272, 20971520, 195035136, 1018167296, 134742016, 365690880, 584187904, 432734208, 851345408, 480854016, 771563520, 379310080, 908478464, 891100160, 747283968, 186532608, 488186496, 343249088, 446121888, 890590896, 759597480, 734910908, 30623014, 994776695 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 100663296, 385875968, 192937984, 373293056, 350224384, 554696704, 905445376, 735313920, 736231424, 212271104, 603750400, 602816512, 547430400, 686837760, 912869376, 686621696, 253156864, 334867712, 617771904, 695129408, 576796256, 634485040, 802688488, 971352188, 749430150, 1006320707 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 436207616, 855638016, 931135488, 12582912, 195035136, 483393536, 339214336, 456392704, 830603264, 504430592, 681082880, 1046822912, 813424640, 268816384, 25892864, 145619968, 342320640, 480955648, 1010638464, 247336384, 523167648, 594992400, 817076232, 890813444, 899974666, 408624399 + ], + [ + 536870912, 268435456, 402653184, 738197504, 704643072, 318767104, 260046848, 197132288, 794820608, 321912832, 503840768, 952369152, 85590016, 590807040, 370769920, 425476096, 730308608, 366030848, 804866048, 220996608, 112148992, 914715904, 582744704, 149411264, 1021413472, 988906992, 375951592, 578098484, 701639182, 672342287 + ], + [ + 536870912, 268435456, 134217728, 872415232, 369098752, 150994944, 8388608, 541065216, 811597824, 200278016, 242745344, 994836480, 642121728, 625016832, 182484992, 145768448, 362389504, 259829760, 832456704, 89981952, 957317632, 592757504, 133922688, 838828992, 380482144, 192366128, 974684168, 1052524548, 490708994, 1015918605 + ], + [ + 536870912, 268435456, 134217728, 872415232, 570425344, 184549376, 1031798784, 4194304, 891289600, 324009984, 365428736, 988545024, 798359552, 772734976, 850100224, 848412672, 648634368, 1033695232, 730785792, 518759424, 430978560, 687376128, 1020580224, 665005504, 966634400, 294597008, 703296936, 842011284, 28938794, 1064613977 + ], + [ + 536870912, 805306368, 671088640, 738197504, 436207616, 520093696, 310378496, 985661440, 996147200, 399507456, 846725120, 1033633792, 818020352, 575078400, 633896960, 213172224, 686170112, 905490432, 316516352, 669199360, 37167616, 1040211200, 419519872, 1065457984, 457185568, 153197040, 158353064, 206106044, 586459650, 71811335 + ], + [ + 536870912, 805306368, 939524096, 872415232, 838860800, 486539264, 1031798784, 499122176, 593494016, 529530880, 1006108672, 254541824, 182059008, 225378304, 520650752, 793001984, 873357312, 563687424, 389871616, 1038271488, 446931456, 948102400, 439504768, 469380928, 22952096, 494972080, 767669544, 459364092, 730937862, 167317761 + ], + [ + 536870912, 268435456, 402653184, 738197504, 234881024, 922746880, 260046848, 960495616, 878706688, 66060288, 824705024, 379322368, 458620928, 676790272, 232226816, 966213632, 393617408, 457592832, 533719040, 134452224, 749493760, 350158080, 639328896, 188263360, 872726304, 671348112, 1017954088, 216003988, 169525038, 87618975 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 301989888, 150994944, 746586112, 910163968, 236978176, 839909376, 657981440, 1007419392, 121503744, 948109312, 760578048, 201539584, 924131328, 673443840, 805574656, 832195584, 860390912, 335866624, 261870976, 273265472, 226876576, 123368208, 556347688, 490044500, 607384454, 876472395 + ], + [ + 536870912, 805306368, 402653184, 67108864, 234881024, 1056964608, 411041792, 859832320, 216006656, 657457152, 772276224, 824967168, 887488512, 609943552, 518291456, 996884480, 82698240, 474468352, 185223168, 782081024, 430861824, 26731776, 154356352, 1060641728, 337953312, 189454800, 419209384, 551538204, 251634830, 99598029 + ], + [ + 536870912, 805306368, 402653184, 201326592, 637534208, 50331648, 1048576000, 624951296, 392167424, 495976448, 1041760256, 214171648, 553517056, 805896192, 236814336, 312131584, 373776384, 293449728, 722163712, 442389504, 884537856, 276091648, 848797824, 906329792, 761224992, 272202864, 137732616, 343377676, 374659718, 577138115 + ], + [ + 536870912, 268435456, 671088640, 603979776, 704643072, 889192448, 511705088, 952107008, 1042284544, 567279616, 49807360, 477364224, 706871296, 1063714816, 122519552, 83345408, 894787584, 343076864, 434026496, 215612416, 94740992, 618397440, 756251520, 846178112, 269523296, 341405232, 375765736, 863634804, 998463874, 49780813 + ], + [ + 536870912, 805306368, 134217728, 201326592, 1040187392, 218103808, 260046848, 817889280, 673185792, 523239424, 648544256, 1065091072, 775028736, 321323008, 541622272, 896385024, 271196160, 909283328, 656873472, 440980480, 174873088, 749410048, 74662016, 809937088, 496606368, 466981232, 709756456, 865463996, 841939466, 12863247 + ], + [ + 536870912, 805306368, 939524096, 335544320, 33554432, 218103808, 159383552, 801112064, 736100352, 200278016, 447217664, 1026293760, 897712128, 663158784, 518553600, 67911680, 605249536, 220180480, 277673984, 173171712, 624906752, 647762176, 336279680, 104517312, 141704736, 36658288, 524571816, 63865788, 95801862, 1055346953 + ], + [ + 536870912, 268435456, 671088640, 738197504, 704643072, 620756992, 176160768, 130023424, 413138944, 770703360, 836239360, 758382592, 322306048, 1638400, 43286528, 356990976, 981491712, 1069666304, 480274432, 737227776, 1054436864, 45477120, 511130496, 528003264, 935668896, 158250544, 644738568, 29535492, 261053322, 696082635 + ], + [ + 536870912, 268435456, 671088640, 201326592, 369098752, 822083584, 494927872, 255852544, 455081984, 290455552, 112721920, 527171584, 169738240, 745996288, 1021542400, 733003776, 218734592, 40210432, 544954368, 840704, 720346624, 811470592, 551012736, 770840128, 380202016, 133522000, 732146216, 76593492, 777551266, 802971671 + ], + [ + 536870912, 268435456, 134217728, 201326592, 973078528, 922746880, 864026624, 29360128, 287309824, 462422016, 750256128, 860094464, 390987776, 263651328, 957579264, 611172352, 414359552, 599584768, 770344960, 684241920, 852281856, 753044224, 388268928, 935328832, 746509664, 442413200, 978296680, 456588180, 55721194, 948713431 + ], + [ + 536870912, 268435456, 134217728, 738197504, 771751936, 855638016, 696254464, 281018368, 606076928, 185597952, 184025088, 472121344, 853147648, 376635392, 38764544, 344047616, 440508416, 358633472, 334596096, 197764096, 785142272, 226945792, 676134784, 46640704, 195931744, 108445744, 126219368, 772493108, 455834090, 884710015 + ], + [ + 536870912, 268435456, 939524096, 201326592, 167772160, 855638016, 343932928, 398458880, 207618048, 336592896, 35127296, 299106304, 626917376, 787808256, 49184768, 10272768, 53665792, 252612608, 1053587456, 84653056, 166430208, 473659136, 323196544, 1023897536, 318784544, 75566896, 801240712, 6307780, 504388654, 823716659 + ], + [ + 536870912, 805306368, 402653184, 872415232, 771751936, 754974720, 260046848, 817889280, 350224384, 477102080, 833093632, 122945536, 980549632, 271777792, 1066565632, 834813952, 301719552, 452366336, 196737024, 1036813312, 78545408, 1065739520, 990520960, 169778112, 499984736, 883922672, 663071080, 252368636, 605997422, 818743025 + ], + [ + 536870912, 805306368, 671088640, 67108864, 973078528, 587202560, 729808896, 675282944, 199229440, 336592896, 498597888, 888930304, 899284992, 515047424, 255229952, 712097792, 149479424, 35958784, 313976832, 791712768, 428377600, 854917376, 1026530688, 259834432, 98267808, 961805040, 623320232, 784953340, 882149154, 880700605 + ], + [ + 536870912, 268435456, 671088640, 67108864, 167772160, 989855744, 746586112, 935329792, 962592768, 460324864, 268959744, 777256960, 1029308416, 378208256, 764641280, 859750400, 628678656, 526233600, 747563008, 881970176, 1069142528, 129861888, 834660992, 867794624, 431864416, 683599792, 540553832, 150756276, 488630370, 782872245 + ], + [ + 536870912, 805306368, 402653184, 335544320, 436207616, 654311424, 931135488, 331350016, 14680064, 105906176, 363331584, 884736000, 1042415616, 875233280, 73826304, 194789376, 110354432, 47427584, 569624576, 1061295104, 951777792, 61805824, 775005056, 330902720, 808816672, 1060017328, 879757864, 630813116, 839188910, 311867769 + ], + [ + 536870912, 268435456, 671088640, 469762048, 167772160, 50331648, 411041792, 784334848, 941621248, 1009778688, 175636480, 748945408, 51511296, 78577664, 726237184, 995999744, 955752448, 383627264, 397854720, 867998720, 971493888, 420783872, 405428352, 409691712, 395000032, 538634416, 1007850088, 103700980, 780737026, 133970691 + ], + [ + 536870912, 268435456, 939524096, 335544320, 167772160, 855638016, 109051904, 692060160, 736100352, 17825792, 79167488, 18612224, 975831040, 411631616, 596934656, 46120960, 817340416, 610521088, 876468224, 807130112, 1057061376, 142653184, 675296384, 174089152, 617642464, 890787024, 762151432, 381842180, 919451278, 431100101 + ], + [ + 536870912, 805306368, 671088640, 872415232, 167772160, 956301312, 662700032, 88080384, 257949696, 361758720, 361234432, 594804736, 438960128, 523304960, 783908864, 533544960, 552050688, 643256320, 1051674624, 813890560, 657738240, 516639488, 434164864, 860891200, 1034474912, 881185872, 934504456, 361622540, 1057432074, 168208141 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 637534208, 1056964608, 612368384, 473956352, 715128832, 275775488, 777519104, 1029439488, 736755712, 123535360, 585793536, 886849536, 640376832, 608006144, 603625472, 1049908224, 750680576, 42139904, 276429184, 158200768, 991089504, 812747920, 1046083976, 358478788, 401265514, 559778975 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 503316480, 922746880, 444596224, 507510784, 836763648, 691011584, 558366720, 287047680, 709230592, 7929856, 475299840, 224083968, 557768704, 414019584, 944666624, 117797888, 249782784, 810190592, 124142976, 48831552, 801926624, 20910256, 145562120, 273675012, 990193546, 283351887 + ], + [ + 536870912, 805306368, 671088640, 738197504, 301989888, 117440512, 897581056, 406847488, 106954752, 179306496, 274202624, 259784704, 362414080, 261816320, 345669632, 454803456, 677027840, 163196928, 474613760, 1072931840, 578774528, 568153344, 730464384, 986841664, 556710304, 141833584, 357480872, 902051196, 412531106, 251147639 + ], + [ + 536870912, 268435456, 671088640, 469762048, 33554432, 822083584, 1031798784, 440401920, 555745280, 745537536, 56098816, 208404480, 732299264, 270336000, 285114368, 678445056, 626548736, 191713280, 958883840, 81591296, 656398848, 48276736, 823251328, 151536576, 834955488, 810728432, 3586440, 30719940, 1021031146, 531767031 + ], + [ + 536870912, 268435456, 134217728, 67108864, 771751936, 889192448, 310378496, 213909504, 878706688, 112197632, 1035468800, 61079552, 834273280, 110559232, 57769984, 693682176, 517234688, 904089600, 113498112, 273857536, 16462336, 800466176, 383846016, 309452864, 98163936, 789945072, 386019432, 582214580, 747264010, 393116677 + ], + [ + 536870912, 268435456, 671088640, 67108864, 33554432, 16777216, 243269632, 1002438656, 757071872, 191889408, 163053568, 917241856, 619315200, 1045233664, 1035632640, 486817792, 820944896, 337793024, 945399808, 226337792, 979547648, 490220800, 812457344, 692721856, 167601376, 346246544, 345587080, 98306244, 22179050, 249608593 + ], + [ + 536870912, 268435456, 671088640, 469762048, 33554432, 922746880, 612368384, 322961408, 1046478848, 737148928, 694681600, 470548480, 310509568, 347275264, 66813952, 417775616, 851189760, 1015754752, 449775616, 617737216, 469358080, 303322368, 682091136, 643683776, 423304096, 38248112, 653104040, 976466612, 733734306, 671487923 + ], + [ + 536870912, 805306368, 402653184, 469762048, 905969664, 117440512, 1048576000, 943718400, 908066816, 862978048, 174587904, 28573696, 371064832, 68878336, 957120512, 57884672, 121184256, 212652032, 801327104, 1051732992, 612894208, 1067748096, 229064320, 905362112, 728717280, 628265680, 674865512, 908870684, 1032016014, 965856715 + ], + [ + 536870912, 805306368, 134217728, 603979776, 905969664, 822083584, 209715200, 834666496, 987758592, 76546048, 548929536, 367788032, 308412416, 369426432, 483885056, 295387136, 768188416, 38039552, 125233152, 69989376, 268514816, 939653888, 738242176, 302107840, 117531872, 1031822928, 1027666056, 186680268, 1047616610, 606607769 + ], + [ + 536870912, 268435456, 939524096, 603979776, 973078528, 956301312, 461373440, 666894336, 102760448, 466616320, 434634752, 671350784, 575537152, 105971712, 153649152, 245743616, 417275904, 534302720, 572344320, 863181824, 326311424, 57827584, 997414528, 527659840, 628280864, 477256560, 133384200, 540154884, 638819854, 1036230921 + ], + [ + 536870912, 805306368, 134217728, 335544320, 301989888, 318767104, 964689920, 675282944, 836763648, 542113792, 779616256, 210501632, 719978496, 700252160, 402882560, 912867328, 722804736, 439799808, 724514816, 1010031616, 771824128, 620831488, 813707392, 381703360, 840999648, 720384656, 105392264, 719608012, 973013218, 797609365 + ], + [ + 536870912, 805306368, 402653184, 335544320, 838860800, 419430400, 830472192, 88080384, 1046478848, 951058432, 410517504, 22806528, 420872192, 279117824, 448823296, 740376576, 273702912, 722022400, 948262912, 861619200, 601662976, 282482944, 805566080, 340862528, 822614304, 763652688, 618328488, 228335900, 104235022, 1014120457 + ], + [ + 536870912, 268435456, 402653184, 872415232, 167772160, 687865856, 662700032, 826277888, 551550976, 504365056, 688390144, 988020736, 392822784, 675872768, 302284800, 628801536, 1061199872, 199282688, 1016170496, 29924352, 138795520, 656035584, 160484480, 273171008, 906235936, 930868176, 574708232, 643862276, 617639046, 111710797 + ], + [ + 536870912, 805306368, 134217728, 469762048, 436207616, 419430400, 92274688, 675282944, 94371840, 898629632, 608698368, 94109696, 232128512, 878116864, 907444224, 582402048, 245768192, 414117888, 26359808, 1012143104, 67786240, 841022208, 684824448, 912889280, 491637024, 868179856, 891013416, 531128220, 246237482, 344891291 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 570425344, 889192448, 343932928, 264241152, 199229440, 95420416, 244842496, 1020002304, 264896512, 634322944, 518029312, 556875776, 425271296, 187494400, 679131136, 508955648, 917264896, 557539584, 930501248, 276572480, 131230368, 1002615856, 843840040, 747569276, 935403534, 132182019 + ], + [ + 536870912, 268435456, 402653184, 603979776, 503316480, 352321536, 159383552, 884998144, 761266176, 510656512, 452460544, 328466432, 862322688, 595263488, 938573824, 1043873792, 653647872, 152555520, 662919168, 828728320, 81766912, 827206912, 327665792, 130759744, 224972640, 509443472, 632026600, 26806484, 887445518, 35546125 + ], + [ + 536870912, 805306368, 939524096, 67108864, 704643072, 352321536, 444596224, 868220928, 962592768, 739246080, 820510720, 679215104, 928382976, 291831808, 51609600, 507953152, 856465408, 615452672, 1047545856, 829957120, 416654848, 554407680, 1065515648, 946862656, 9469024, 136881008, 211629192, 587618636, 464283886, 417212977 + ], + [ + 536870912, 268435456, 671088640, 872415232, 704643072, 520093696, 662700032, 71303168, 572522496, 99614720, 813170688, 615776256, 396754944, 198901760, 470908928, 535412736, 85778432, 127594496, 439396352, 404308992, 509894144, 783192832, 383217280, 375575616, 63265376, 589290128, 848249576, 908532180, 916178946, 816935945 + ], + [ + 536870912, 268435456, 134217728, 469762048, 436207616, 218103808, 847249408, 348127232, 232783872, 59768832, 775421952, 349437952, 457834496, 920322048, 65241088, 985120768, 381493248, 298250240, 93657088, 770395136, 384485888, 728388864, 338317696, 965405760, 876331232, 737292208, 885971176, 206136244, 997987050, 950482611 + ], + [ + 536870912, 268435456, 134217728, 469762048, 234881024, 687865856, 260046848, 415236096, 245366784, 573571072, 375914496, 80478208, 155582464, 244645888, 719486976, 413089792, 670130176, 357085184, 289269760, 722398208, 824770048, 179159296, 836234112, 684580928, 524792544, 865460464, 929234312, 660524356, 265332578, 540656055 + ], + [ + 536870912, 805306368, 134217728, 335544320, 167772160, 117440512, 746586112, 633339904, 1063256064, 191889408, 970457088, 62128128, 491126784, 680853504, 521633792, 807223296, 715857920, 774311936, 98834432, 936309760, 103347712, 867036928, 932404608, 664979904, 802872352, 587139568, 835845512, 1036622284, 958161954, 858435061 + ], + [ + 536870912, 268435456, 402653184, 469762048, 771751936, 587202560, 696254464, 281018368, 6291456, 774897664, 851968000, 25952256, 360316928, 426442752, 817070080, 191315968, 1007263744, 720228352, 382355456, 157467648, 1012802048, 984453376, 787093632, 192033472, 646439072, 821568624, 356878504, 871854196, 395428526, 874100083 + ], + [ + 536870912, 805306368, 671088640, 67108864, 905969664, 419430400, 360710144, 20971520, 1000341504, 875560960, 1062731776, 200540160, 192806912, 272695296, 438403072, 728842240, 435691520, 474329088, 744933376, 899001344, 607095296, 1070177536, 1008468352, 51579584, 774616992, 948946928, 863600648, 159727628, 788930570, 155496449 + ], + [ + 536870912, 805306368, 402653184, 872415232, 167772160, 50331648, 998244352, 834666496, 639631360, 36700160, 956825600, 702808064, 329121792, 340066304, 275742720, 325959680, 263856128, 872124416, 823867392, 193711104, 133330432, 847207680, 626276224, 903318848, 885073056, 278945712, 426776456, 577314124, 230005926, 1011241917 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 301989888, 419430400, 394264576, 968884224, 543162368, 359661568, 72876032, 348389376, 420610048, 669057024, 347176960, 272121856, 800448512, 373985280, 1034274816, 602094592, 779652608, 236282624, 391805824, 42732224, 947849760, 758025872, 514318344, 1034653708, 856967170, 383482895 + ], + [ + 536870912, 805306368, 939524096, 469762048, 234881024, 1056964608, 897581056, 1019215872, 367001600, 292552704, 1051197440, 874250240, 912392192, 363003904, 96632832, 275988480, 658219008, 207081472, 1000089600, 799179776, 549708288, 821234944, 58369664, 569885632, 156101408, 484117552, 304573224, 146033724, 998165286, 222338107 + ], + [ + 536870912, 805306368, 671088640, 603979776, 369098752, 318767104, 209715200, 213909504, 622854144, 567279616, 913833984, 721158144, 1027735552, 6356992, 665944064, 449396736, 817176576, 859222016, 326604800, 177660928, 644326912, 365938944, 525033088, 469072832, 710343648, 21405712, 421437448, 313716748, 659109898, 770970633 + ], + [ + 536870912, 268435456, 134217728, 738197504, 570425344, 889192448, 461373440, 230686720, 224395264, 550502400, 594018304, 972292096, 296353792, 787546112, 144211968, 854343680, 176644096, 655757312, 408823808, 660282368, 40422912, 880073472, 795516544, 51453760, 688473504, 1067826256, 142854152, 899959812, 25363970, 69506827 + ], + [ + 536870912, 805306368, 134217728, 201326592, 637534208, 956301312, 679477248, 364904448, 1063256064, 655360000, 739770368, 130809856, 579469312, 708640768, 247693312, 1011433472, 779476992, 616001536, 855549952, 59438080, 918398464, 956505856, 271156864, 1055228864, 216988384, 924006032, 749784712, 686360524, 990147810, 624860563 + ], + [ + 536870912, 268435456, 402653184, 335544320, 1040187392, 889192448, 427819008, 71303168, 652214272, 15728640, 231211008, 656670720, 924975104, 994902016, 513179648, 983023616, 211230720, 899067904, 102123520, 156687360, 53975552, 503726848, 829378944, 811208512, 172056480, 467710416, 359754632, 596196420, 180708902, 458478229 + ], + [ + 536870912, 805306368, 939524096, 201326592, 570425344, 989855744, 897581056, 46137344, 887095296, 808452096, 417857536, 491520000, 97386496, 764346368, 137265152, 591347712, 528949248, 72495104, 1016719360, 973423616, 76730880, 58307840, 129291392, 314262464, 148165024, 155886544, 308040104, 527885276, 459010470, 275026911 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 100663296, 956301312, 243269632, 683671552, 1067450368, 103809024, 359137280, 635699200, 172097536, 858718208, 634945536, 340606976, 235347968, 979161088, 186546176, 95452160, 556356096, 696535808, 1045685376, 959962816, 901089888, 607892528, 861052136, 632730108, 108341774, 370882307 + ], + [ + 536870912, 805306368, 671088640, 67108864, 905969664, 83886080, 796917760, 322961408, 660602880, 51380224, 129499136, 1069285376, 185466880, 94830592, 312639488, 378650624, 335077376, 744280064, 903854080, 801104896, 523193856, 299310336, 1040865664, 714427968, 290103456, 670374992, 224024232, 953017692, 1025982754, 761509405 + ], + [ + 536870912, 805306368, 671088640, 603979776, 838860800, 553648128, 713031680, 222298112, 186646528, 456130560, 235405312, 623640576, 931790848, 27197440, 372277248, 42516480, 325869568, 321564672, 258971648, 1062788096, 490077696, 1017008896, 850473088, 281653696, 97273120, 1020955440, 210178984, 765834748, 971479042, 104127493 + ], + [ + 536870912, 268435456, 671088640, 469762048, 771751936, 419430400, 662700032, 54525952, 165675008, 756023296, 582483968, 580124672, 80347136, 264175616, 912621568, 862175232, 999464960, 574230528, 253196288, 1019859968, 66942464, 222711040, 26231680, 561537856, 1052041312, 419156848, 615908328, 196714548, 1024826242, 864790339 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 436207616, 285212672, 209715200, 423624704, 450887680, 292552704, 702021632, 600047616, 1014366208, 419495936, 411140096, 658554880, 769777664, 384880640, 756582400, 753165312, 782682624, 994694912, 65866624, 288067264, 726924832, 721925040, 198705160, 1053032460, 854982662, 759234575 + ], + [ + 536870912, 805306368, 939524096, 603979776, 838860800, 452984832, 662700032, 113246208, 874512384, 512753664, 237502464, 166461440, 921829376, 297467904, 304513024, 290275328, 19095552, 829583360, 662366208, 503788544, 735949312, 1024088832, 597674880, 906555584, 159172768, 232463024, 852925096, 747991484, 244734246, 418743669 + ], + [ + 536870912, 805306368, 671088640, 738197504, 1040187392, 620756992, 310378496, 482344960, 425721856, 691011584, 196608000, 704905216, 942800896, 922550272, 588742656, 56508416, 780394496, 788803584, 447907840, 37504000, 376888832, 342804224, 3928960, 394319040, 1044429984, 765549264, 475049352, 478761932, 79507242, 11992603 + ], + [ + 536870912, 805306368, 939524096, 872415232, 369098752, 50331648, 864026624, 599785472, 681574400, 252706816, 370671616, 128712704, 192544768, 212926464, 378109952, 678805504, 91725824, 777760768, 526424064, 28433408, 571047424, 372528384, 957796480, 745157824, 648560480, 186925264, 34551816, 793144332, 731112974, 267684109 + ], + [ + 536870912, 268435456, 134217728, 469762048, 570425344, 318767104, 562036736, 633339904, 228589568, 5242880, 529006592, 350486528, 56754176, 187105280, 714440704, 846905344, 946577408, 646082560, 420890624, 1072477184, 650580480, 614820608, 84052864, 1070994624, 466480224, 525803952, 344770536, 45565300, 45966218, 567267523 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 637534208, 452984832, 411041792, 977272832, 811597824, 533725184, 228065280, 462684160, 882245632, 1069350912, 910852096, 229064704, 548691968, 648540160, 540309504, 686199808, 173373952, 171376384, 72194176, 862160320, 989533472, 594435312, 519633544, 952377028, 290426786, 357151295 + ], + [ + 536870912, 268435456, 134217728, 603979776, 301989888, 218103808, 645922816, 591396864, 819986432, 508559360, 580386816, 240386048, 814088192, 223412224, 790134784, 479477760, 749150208, 874614784, 225503232, 946435072, 234633728, 366679808, 263953024, 346792128, 299018400, 240575280, 193521672, 372077572, 25311746, 265164553 + ], + [ + 536870912, 268435456, 134217728, 603979776, 570425344, 956301312, 914358272, 230686720, 929038336, 244318208, 694681600, 803471360, 499515392, 272695296, 757104640, 783302656, 458825728, 612175872, 442222592, 810202112, 904130048, 937851648, 795907200, 976862016, 971818784, 414360112, 116293640, 730152964, 685219842, 677924873 + ], + [ + 536870912, 805306368, 134217728, 872415232, 369098752, 855638016, 679477248, 591396864, 425721856, 330301440, 669515776, 706478080, 533069824, 1054277632, 11436032, 260751360, 973692928, 15519744, 944687104, 1056623616, 373421568, 987811072, 611444864, 1070162880, 97325344, 807325712, 954349864, 257231900, 608888618, 808000785 + ], + [ + 536870912, 805306368, 939524096, 872415232, 369098752, 922746880, 444596224, 658505728, 589299712, 657457152, 770179072, 482607104, 173670400, 421724160, 410943488, 942227456, 614850560, 340447232, 117155840, 315841536, 611784192, 691803904, 910576256, 257238976, 407063776, 804257200, 875565800, 694773436, 8676966, 301615729 + ], + [ + 536870912, 268435456, 402653184, 335544320, 100663296, 50331648, 478150656, 490733568, 912261120, 95420416, 641204224, 947126272, 725221376, 1010892800, 669024256, 191938560, 60334080, 333721600, 559028224, 645784576, 968256000, 397308672, 277548416, 494420416, 487930784, 705424848, 322469896, 804569092, 653959174, 90255365 + ], + [ + 536870912, 268435456, 939524096, 335544320, 637534208, 184549376, 998244352, 901775360, 85983232, 300941312, 785907712, 603717632, 733085696, 992018432, 519077888, 190431232, 154968064, 856895488, 336680960, 243883008, 211054080, 158763264, 977190784, 260746944, 487359456, 820712336, 169648136, 971190276, 961107982, 213212165 + ], + [ + 536870912, 805306368, 134217728, 603979776, 369098752, 318767104, 360710144, 331350016, 354418688, 953155584, 645398528, 380895232, 339345408, 493158400, 398688256, 269565952, 853057536, 598011904, 274970624, 813767680, 625051136, 459293952, 439384192, 495528640, 454945568, 829898256, 204193928, 196884172, 577137954, 326269721 + ], + [ + 536870912, 805306368, 939524096, 67108864, 570425344, 352321536, 981467136, 717225984, 320864256, 646971392, 6815744, 128188416, 813563904, 492240896, 361922560, 614285312, 1058168832, 106819584, 271718400, 114076672, 660310528, 787073792, 124121984, 173976256, 659018976, 138109072, 530112232, 968682396, 579063142, 934670685 + ], + [ + 536870912, 805306368, 402653184, 201326592, 704643072, 889192448, 142606336, 918552576, 719323136, 705691648, 497549312, 557580288, 295043072, 940244992, 497844224, 436158464, 1012375552, 560705536, 50116608, 66505728, 1020985856, 652540160, 953416576, 90720192, 819851680, 939920592, 149105192, 926006044, 64570254, 658869199 + ], + [ + 536870912, 805306368, 671088640, 201326592, 905969664, 150994944, 243269632, 12582912, 983564288, 923795456, 1019740160, 528744448, 236322816, 828440576, 674332672, 513359872, 615276544, 761507840, 156190720, 971830272, 377669120, 734000384, 181725312, 247389760, 39116832, 796807856, 980803592, 783216652, 891103242, 146424835 + ], + [ + 536870912, 268435456, 134217728, 738197504, 100663296, 117440512, 360710144, 264241152, 555745280, 177209344, 752353280, 921436160, 536215552, 485687296, 434208768, 640729088, 227090432, 286609408, 579471360, 1029542912, 700338688, 247871232, 486260096, 590660160, 261835168, 994440400, 116624936, 14730644, 280010762, 1036619791 + ], + [ + 536870912, 805306368, 402653184, 469762048, 369098752, 16777216, 494927872, 457179136, 144703488, 91226112, 838336512, 345767936, 572391424, 1060700160, 863862784, 1036959744, 11657216, 479801344, 210552832, 334892032, 105736704, 1041747200, 245172096, 488519104, 666472928, 1069306736, 959375880, 299896076, 785475462, 973718983 + ], + [ + 536870912, 268435456, 939524096, 469762048, 234881024, 620756992, 411041792, 373293056, 463470592, 288358400, 820510720, 156499968, 36044800, 968032256, 678789120, 106381312, 192552960, 751898624, 309860352, 210553856, 698017280, 432027392, 778123392, 424720576, 683229920, 728530704, 336329320, 194545620, 1008539782, 121809091 + ], + [ + 536870912, 268435456, 402653184, 67108864, 100663296, 687865856, 645922816, 448790528, 123731968, 911212544, 143130624, 304873472, 694550528, 434044928, 61571072, 849952768, 324820992, 270454784, 424302592, 263834624, 234154496, 155400448, 978603904, 460469696, 286055328, 378985488, 1046874536, 39778580, 569046062, 34159061 + ], + [ + 536870912, 805306368, 671088640, 738197504, 570425344, 1056964608, 343932928, 264241152, 165675008, 886046720, 580386816, 640942080, 152698880, 685834240, 626098176, 47792128, 982867968, 652939264, 482932736, 242033664, 156188160, 6958848, 872953472, 386673856, 1012905376, 907232976, 225271816, 667881484, 883619850, 661136395 + ], + [ + 536870912, 805306368, 402653184, 603979776, 100663296, 184549376, 864026624, 775946240, 371195904, 112197632, 174587904, 828637184, 572653568, 228261888, 1032224768, 811089920, 281829376, 942133248, 682117120, 344224768, 737310208, 115506944, 595281536, 131518400, 358683104, 403827568, 152686568, 661418108, 97965934, 677405877 + ], + [ + 536870912, 805306368, 134217728, 335544320, 33554432, 788529152, 1065353216, 381681664, 295698432, 569376768, 1022885888, 585891840, 538836992, 658440192, 982417408, 227983360, 543842304, 924610560, 786827264, 584283136, 823132672, 1047097088, 608522368, 620470080, 615885856, 646149840, 505007144, 125568732, 221725738, 924496601 + ], + [ + 536870912, 805306368, 939524096, 67108864, 771751936, 1023410176, 8388608, 784334848, 857735168, 556793856, 953679872, 129236992, 1054736384, 204800000, 429883392, 122994688, 474980352, 52277248, 298993664, 823112704, 729562624, 293776640, 520583040, 352422848, 209754656, 1019323696, 606173064, 850430924, 731453998, 450127153 + ], + [ + 536870912, 268435456, 402653184, 872415232, 369098752, 922746880, 595591168, 205520896, 81788928, 900726784, 43515904, 50069504, 548798464, 132972544, 931037184, 1010417664, 346890240, 740192256, 1070143488, 131410944, 433265152, 86481664, 702873472, 856411072, 221955680, 1071899504, 66996104, 66672580, 68019302, 693052541 + ], + [ + 536870912, 268435456, 671088640, 67108864, 1040187392, 419430400, 511705088, 62914560, 404750336, 414187520, 534249472, 259784704, 1061027840, 909443072, 304775168, 355352576, 882745344, 799944704, 425502720, 110076928, 460154368, 613833984, 355573632, 496519616, 1058814816, 418329776, 230551944, 94339268, 1061448426, 919766129 + ], + [ + 536870912, 805306368, 402653184, 603979776, 100663296, 855638016, 377487360, 507510784, 467664896, 537919488, 890765312, 831258624, 1001521152, 53411840, 973373440, 761741312, 686874624, 864587776, 47540224, 903744512, 512587264, 1060254976, 812559232, 543554112, 62360480, 726149488, 796149800, 841998140, 696563086, 245809989 + ], + [ + 536870912, 268435456, 134217728, 335544320, 33554432, 620756992, 696254464, 146800640, 115343360, 376438784, 953679872, 56885248, 540672000, 759496704, 548044800, 200097792, 253108224, 716394496, 661129216, 249404416, 82808320, 214354688, 926567808, 969168320, 501990048, 332219920, 948366728, 144328132, 1033235106, 597920277 + ], + [ + 536870912, 268435456, 134217728, 335544320, 570425344, 620756992, 696254464, 356515840, 1059061760, 407896064, 209190912, 959184896, 222429184, 612433920, 952139776, 6307840, 376479744, 531173376, 85272576, 584010752, 617851392, 790132992, 433848960, 388662208, 343243104, 792646160, 54132744, 682426372, 335708162, 631324677 + ], + [ + 536870912, 805306368, 134217728, 872415232, 905969664, 654311424, 897581056, 901775360, 685768704, 225443840, 261619712, 938737664, 870973440, 891748352, 912818176, 657309696, 281010176, 345837568, 944179200, 920245248, 1012146688, 674961664, 971945088, 672435008, 857380192, 863906800, 729637864, 146172348, 947989002, 356633857 + ], + [ + 536870912, 268435456, 134217728, 335544320, 570425344, 218103808, 998244352, 272629760, 727711744, 489684992, 709361664, 662437888, 600965120, 401670144, 82345984, 845955072, 1061855232, 53743616, 665774080, 1017289728, 64594432, 421825280, 498491776, 195444288, 264192480, 62534032, 459040776, 654564356, 558465538, 738056965 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 234881024, 486539264, 964689920, 331350016, 371195904, 783286272, 556269568, 652476416, 354811904, 981663744, 650477568, 177684480, 338370560, 853544960, 1041356800, 249103360, 447529472, 789755648, 954065024, 446410432, 63492448, 552942224, 671003112, 774820948, 349618310, 197902027 + ], + [ + 536870912, 805306368, 402653184, 67108864, 234881024, 989855744, 92274688, 230686720, 673185792, 277872640, 542638080, 188481536, 252051456, 938934272, 249462784, 252329984, 184049664, 703401984, 666847232, 1056613376, 928082432, 226073344, 1026385792, 589232448, 388642464, 40424336, 230006440, 578955164, 184376494, 86395037 + ], + [ + 536870912, 268435456, 671088640, 67108864, 503316480, 788529152, 880803840, 205520896, 362807296, 286261248, 837287936, 14942208, 629538816, 233897984, 148406272, 467484672, 602546176, 291762176, 242677760, 103375872, 1032159744, 91700480, 1017651328, 918889280, 542636320, 1073309488, 1032607752, 86234116, 668424714, 624470273 + ], + [ + 536870912, 805306368, 939524096, 469762048, 234881024, 285212672, 1031798784, 4194304, 178257920, 273678336, 272105472, 613154816, 931790848, 1069744128, 132546560, 196689920, 567058432, 715870208, 752031744, 1073714176, 329524736, 824122112, 726959488, 376950336, 794882848, 917512176, 1019833640, 702857468, 817780390, 1032176059 + ], + [ + 536870912, 268435456, 939524096, 335544320, 771751936, 754974720, 176160768, 54525952, 1063256064, 955252736, 370671616, 903610368, 633470976, 844824576, 524779520, 237256704, 800055296, 685838336, 422590464, 104434688, 139298304, 137020672, 907955840, 110712896, 631079840, 86158128, 392824232, 461336116, 292145958, 772109937 + ], + [ + 536870912, 268435456, 939524096, 738197504, 1040187392, 989855744, 528482304, 322961408, 610271232, 869269504, 730333184, 1046740992, 286392320, 931594240, 212697088, 840384512, 935698432, 190976000, 377415680, 724681728, 681104896, 617398528, 801558912, 525168832, 109455456, 707543856, 64369128, 140879860, 773031814, 34009551 + ], + [ + 536870912, 805306368, 134217728, 469762048, 1040187392, 419430400, 662700032, 968884224, 174063616, 856686592, 624427008, 1003749376, 460718080, 129040384, 315195392, 1002192896, 708501504, 543354880, 19286016, 397016064, 439152128, 658703104, 756498560, 983674304, 653272224, 1005116080, 915220488, 884165644, 125715970, 820842247 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 637534208, 889192448, 746586112, 222298112, 715128832, 896532480, 292028416, 846462976, 457048064, 5308416, 551059456, 545013760, 131850240, 869675008, 65284096, 336045056, 66898432, 622527744, 95843200, 32778048, 838823328, 170979056, 80332808, 813995012, 580280834, 524673295 + ], + [ + 536870912, 268435456, 134217728, 67108864, 33554432, 587202560, 880803840, 624951296, 845152256, 217055232, 209190912, 481034240, 283508736, 514785280, 870023168, 155303936, 610328576, 636514304, 536422400, 258780160, 617059840, 348003584, 370368128, 737433408, 618266912, 666988944, 773930792, 621871252, 390633386, 653654741 + ], + [ + 536870912, 268435456, 134217728, 603979776, 167772160, 788529152, 662700032, 297795584, 1067450368, 193986560, 698875904, 770965504, 129105920, 336527360, 649691136, 203210752, 690446336, 185364480, 751806464, 798557184, 483136000, 40854272, 780728704, 136641984, 746296544, 600552240, 640917352, 349150708, 328841738, 986539789 + ], + [ + 536870912, 805306368, 402653184, 469762048, 503316480, 83886080, 981467136, 641728512, 828375040, 244318208, 188219392, 447479808, 220332032, 676659200, 170885120, 617070592, 179462144, 804040704, 935561216, 537134080, 288786944, 538658560, 469293696, 999064768, 869404896, 360516432, 654037128, 1034486732, 1033185894, 294649751 + ], + [ + 536870912, 268435456, 671088640, 335544320, 436207616, 520093696, 109051904, 322961408, 232783872, 506462208, 537395200, 661389312, 847380480, 69271552, 512786432, 517554176, 349478912, 975622144, 275773440, 1029944320, 688937472, 504958720, 1005961600, 674728000, 720775008, 920011280, 71704584, 1017024516, 961271818, 15475717 + ], + [ + 536870912, 268435456, 939524096, 603979776, 637534208, 117440512, 394264576, 650117120, 278921216, 898629632, 651689984, 245104640, 695074816, 966721536, 603422720, 65159168, 132734976, 735399936, 1043064832, 770544640, 868614656, 237762304, 99353472, 801593664, 204190624, 619481552, 1061600168, 1030360532, 311177638, 443956957 + ], + [ + 536870912, 268435456, 939524096, 67108864, 167772160, 385875968, 159383552, 1027604480, 970981376, 240123904, 746061824, 333185024, 791019520, 507445248, 141787136, 973881344, 857694208, 310554624, 432359424, 116122624, 134348288, 738236672, 906067840, 419433024, 343964064, 599791888, 220260264, 183578644, 466178086, 838180437 + ], + [ + 536870912, 805306368, 671088640, 603979776, 771751936, 520093696, 478150656, 599785472, 979369984, 770703360, 778567680, 419692544, 953548800, 11206656, 522223616, 491831296, 913858560, 802967552, 656115712, 896080896, 461666816, 739740928, 38444160, 1058139328, 374965088, 504203920, 446860776, 81110876, 1064230914, 672632837 + ], + [ + 536870912, 805306368, 134217728, 872415232, 1040187392, 352321536, 58720256, 146800640, 765460480, 722468864, 1013448704, 752091136, 138805248, 866713600, 636846080, 1058422784, 908107776, 802189312, 331933696, 415611904, 481277440, 20759808, 189973632, 47113536, 688728992, 728443568, 1024603656, 539919628, 293364866, 817075533 + ], + [ + 536870912, 805306368, 939524096, 335544320, 436207616, 251658240, 394264576, 918552576, 337641472, 976224256, 465043456, 372506624, 936247296, 831062016, 93159424, 234602496, 138911744, 553930752, 284571648, 620551168, 195184128, 534956288, 360920448, 584206272, 901398176, 203899632, 55868936, 522065164, 1008825230, 640716485 + ], + [ + 536870912, 268435456, 134217728, 603979776, 838860800, 251658240, 947912704, 616562688, 341835776, 93323264, 700973056, 90963968, 940965888, 236388352, 588742656, 479707136, 618061824, 645361664, 948373504, 744410112, 607906304, 220285184, 1051747712, 981052352, 9814176, 12787728, 209043624, 831725588, 970834090, 359604253 + ], + [ + 536870912, 268435456, 939524096, 872415232, 704643072, 620756992, 461373440, 440401920, 325058560, 560988160, 623378432, 884736000, 486670336, 889782272, 724336640, 1818624, 394043392, 757321728, 983164928, 238418944, 376324608, 997397248, 849414016, 944870208, 792298208, 82166160, 647389704, 968295172, 413552526, 75415373 + ], + [ + 536870912, 268435456, 671088640, 469762048, 503316480, 251658240, 964689920, 88080384, 249561088, 737148928, 102236160, 190578688, 728629248, 575340544, 457801728, 953532416, 169582592, 876679168, 677382144, 1060172800, 297338368, 810331392, 159862912, 378512192, 1044103200, 1058125456, 417871528, 298100948, 301149698, 704940291 + ], + [ + 536870912, 805306368, 671088640, 603979776, 167772160, 285212672, 645922816, 314572800, 387973120, 661651456, 274202624, 293339136, 589168640, 269287424, 1011318784, 351289344, 504930304, 765267968, 298821632, 1071932416, 994287104, 660851968, 798100864, 126593984, 1024972896, 894967344, 637379976, 752865228, 262948458, 318231353 + ], + [ + 536870912, 805306368, 402653184, 872415232, 570425344, 318767104, 243269632, 541065216, 211812352, 435159040, 788004864, 564396032, 414056448, 212664320, 15958016, 19382272, 330375168, 760762368, 953546752, 320259072, 506038784, 1013778688, 18053504, 133607616, 259536800, 828679472, 693046152, 310214092, 674939942, 1058741501 + ], + [ + 536870912, 268435456, 939524096, 872415232, 1040187392, 419430400, 310378496, 121634816, 350224384, 760217600, 23592960, 300679168, 321781760, 75038720, 333742080, 139706368, 379494400, 171995136, 677480448, 185660416, 856189440, 100507392, 531052160, 709207360, 115511904, 153588976, 990208520, 117615364, 1022885006, 439175757 + ], + [ + 536870912, 805306368, 671088640, 872415232, 1040187392, 117440512, 209715200, 1035993088, 304087040, 953155584, 1000865792, 921436160, 771358720, 392626176, 220495872, 648462336, 218488832, 997707776, 925730816, 98204672, 1052129792, 151807744, 520749952, 136195520, 174083872, 78772272, 1008215208, 276134396, 860838274, 76044993 + ], + [ + 536870912, 268435456, 671088640, 738197504, 1040187392, 452984832, 25165824, 440401920, 601882624, 168820736, 401080320, 560726016, 605683712, 225902592, 359497728, 236699648, 746004480, 502075392, 819652608, 257422336, 803065344, 344139008, 270711680, 928195008, 191598880, 223219760, 88681128, 823996916, 664976258, 169025999 + ], + [ + 536870912, 805306368, 671088640, 469762048, 436207616, 251658240, 914358272, 381681664, 828375040, 479199232, 158859264, 488374272, 634781696, 622657536, 567771136, 186400768, 685203456, 681349120, 127342592, 968696832, 1017622016, 489991936, 877873792, 747037888, 696558176, 228280944, 642992776, 260498636, 755278442, 140200567 + ], + [ + 536870912, 805306368, 402653184, 603979776, 369098752, 117440512, 327155712, 541065216, 924844032, 464519168, 907542528, 349962240, 305004544, 961740800, 17596416, 271007744, 434561024, 327618560, 26658816, 721404928, 500846080, 58282752, 21827712, 386374464, 441948448, 27182352, 55208360, 1070681692, 923383950, 573837125 + ], + [ + 536870912, 805306368, 402653184, 469762048, 234881024, 385875968, 796917760, 230686720, 228589568, 764411904, 864550912, 31195136, 1051328512, 758448128, 80183296, 172474368, 319184896, 719728640, 202774528, 1043311616, 992609792, 368408832, 669456000, 244779840, 24032608, 298513040, 243593352, 18842188, 1051974630, 543253975 + ], + [ + 536870912, 268435456, 134217728, 872415232, 301989888, 184549376, 1048576000, 859832320, 635437056, 1032847360, 315097088, 554958848, 309723136, 978649088, 328630272, 499466240, 1046421504, 273797120, 342456320, 828711936, 154034688, 461982464, 737455744, 191237440, 618520096, 1004747504, 174206600, 228805956, 738393634, 754117373 + ], + [ + 536870912, 268435456, 134217728, 335544320, 973078528, 486539264, 343932928, 767557632, 534773760, 609222656, 465043456, 44826624, 467271680, 1043136512, 840597504, 332218368, 524951552, 653561856, 757516288, 911094784, 446342656, 805632, 799720576, 522499776, 903823840, 465707024, 779142280, 738834116, 457556450, 835674133 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 1040187392, 687865856, 461373440, 1027604480, 643825664, 204472320, 783810560, 605290496, 3801088, 227344384, 8355840, 239026176, 551510016, 690958336, 741763072, 330435584, 413168128, 319911680, 250105728, 765208768, 102235168, 644044944, 224976264, 350040012, 712424354, 22170719 + ], + [ + 536870912, 268435456, 671088640, 603979776, 838860800, 654311424, 360710144, 775946240, 945815552, 122683392, 141033472, 383516672, 298975232, 384368640, 723288064, 989020160, 1062739968, 769986560, 359036928, 317099008, 195518976, 239483648, 56063616, 23019840, 936525280, 1005146128, 362635784, 389233412, 1014625930, 542441801 + ], + [ + 536870912, 268435456, 134217728, 603979776, 1040187392, 318767104, 1048576000, 977272832, 522190848, 485490688, 139984896, 107741184, 20054016, 84606976, 53968896, 158187520, 1035198464, 1045139456, 731367424, 1012751360, 1024155136, 1060589312, 460063872, 884080704, 768231456, 1012397872, 666727976, 77260852, 884955818, 162079869 + ], + [ + 536870912, 268435456, 939524096, 469762048, 369098752, 352321536, 595591168, 826277888, 627048448, 611319808, 860356608, 471072768, 162922496, 685309952, 669810688, 63684608, 367779840, 603664384, 809691136, 316652544, 870160896, 342004480, 1003358080, 14971968, 826148256, 762075952, 386568712, 751509252, 493614478, 3906375 + ], + [ + 536870912, 805306368, 134217728, 738197504, 838860800, 50331648, 1015021568, 608174080, 274726912, 30408704, 567803904, 532938752, 880410624, 290783232, 625180672, 285294592, 260104192, 281137152, 404846592, 598766592, 587807232, 43869952, 268381312, 894340544, 902197408, 362442000, 21353608, 725334476, 431336098, 517200411 + ], + [ + 536870912, 805306368, 671088640, 738197504, 973078528, 50331648, 327155712, 171966464, 908066816, 902823936, 486014976, 871628800, 716046336, 609550336, 171933696, 252461056, 693821440, 654020608, 40630272, 1060277248, 626452992, 471883008, 785486976, 192422592, 800347936, 630130096, 17134728, 252097228, 9973546, 379323 + ], + [ + 536870912, 805306368, 671088640, 738197504, 301989888, 855638016, 713031680, 683671552, 115343360, 858783744, 1023934464, 975962112, 616169472, 694878208, 324173824, 41402368, 299933696, 397488128, 482945024, 156056576, 130750976, 155368704, 909065344, 3457216, 961427360, 692401520, 778551208, 414792060, 635800994, 796309623 + ], + [ + 536870912, 268435456, 402653184, 872415232, 1040187392, 620756992, 58720256, 239075328, 660602880, 49283072, 532152320, 1057226752, 247595008, 449249280, 981827584, 25313280, 405168128, 657838080, 81434624, 244536320, 313507328, 766038272, 34470016, 874386496, 510670048, 24700592, 480627816, 747827956, 900724878, 422122569 + ], + [ + 536870912, 805306368, 134217728, 67108864, 637534208, 587202560, 209715200, 918552576, 283115520, 152043520, 993525760, 349437952, 326500352, 280952832, 264404992, 572047360, 463855616, 513757184, 573769728, 1043385344, 323553792, 868037888, 876243328, 1026309696, 21220320, 567899856, 751053288, 701489116, 422199914, 269818013 + ], + [ + 536870912, 805306368, 402653184, 335544320, 436207616, 452984832, 360710144, 633339904, 517996544, 818937856, 401080320, 8650752, 154796032, 1020854272, 457015296, 957792256, 365404160, 607014912, 699045888, 537938944, 763895296, 51683072, 611549824, 766260544, 819865888, 938703440, 896345608, 918455052, 576914566, 220587589 + ], + [ + 536870912, 268435456, 939524096, 67108864, 301989888, 486539264, 125829120, 910163968, 354418688, 97517568, 730333184, 707526656, 700317696, 1021902848, 14450688, 652722176, 751640576, 974000128, 1007691776, 619224064, 350020096, 216424704, 902660736, 797869632, 391185504, 910717296, 659374600, 844083460, 439388814, 767035969 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 369098752, 721420288, 746586112, 926941184, 429916160, 282066944, 581435392, 475267072, 832176128, 145948672, 690388992, 626868224, 874487808, 234983424, 654411776, 42028032, 541091328, 589341440, 210807168, 394803904, 1002752864, 177387056, 70692200, 974460220, 834307302, 748908531 + ], + [ + 536870912, 805306368, 939524096, 201326592, 771751936, 553648128, 427819008, 138412032, 715128832, 32505856, 14155776, 802947072, 973471744, 264962048, 1002733568, 79314944, 769433600, 84316160, 256555008, 637871104, 140230144, 663535360, 498009728, 672068416, 427755808, 1013325648, 324704168, 218961948, 997079174, 1047465039 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 100663296, 50331648, 58720256, 88080384, 337641472, 535822336, 409468928, 238288896, 4063232, 76873728, 504266752, 471613440, 665542656, 152727552, 793933824, 328657920, 927011328, 1025551616, 829447552, 564770368, 450138144, 229526960, 346897800, 316851780, 509503530, 851829183 + ], + [ + 536870912, 805306368, 671088640, 469762048, 704643072, 1056964608, 897581056, 952107008, 908066816, 537919488, 290979840, 673447936, 237109248, 993722368, 226394112, 254656512, 574496768, 315486208, 59754496, 944063488, 324203008, 965921536, 884141952, 1059260224, 532403552, 557832176, 1028499304, 743431420, 669378786, 562293691 + ], + [ + 536870912, 805306368, 402653184, 67108864, 167772160, 218103808, 578813952, 952107008, 85983232, 688914432, 479723520, 211025920, 345374720, 1055457280, 654147584, 967491584, 1071849472, 592367616, 320612352, 966423552, 476739072, 809677056, 782115968, 77872832, 455061408, 1004919600, 410975752, 555078924, 802609798, 931720129 + ], + [ + 536870912, 805306368, 134217728, 469762048, 704643072, 956301312, 226492416, 205520896, 765460480, 999292928, 1054343168, 637272064, 527826944, 514523136, 940343296, 853524480, 373268480, 395259904, 797333504, 142836736, 802782720, 75282176, 825681280, 369843264, 605921824, 960979920, 333637544, 1059590044, 576036234, 786638923 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 301989888, 419430400, 796917760, 868220928, 698351616, 110100480, 67633152, 12845056, 448397312, 213319680, 887652352, 297058304, 860004352, 885682176, 231659520, 869561344, 947110400, 810803968, 1040335232, 220917952, 725494880, 1038994672, 128921576, 82059068, 787210754, 446583555 + ], + [ + 536870912, 805306368, 671088640, 469762048, 369098752, 788529152, 494927872, 121634816, 115343360, 930086912, 30932992, 539230208, 812253184, 951910400, 363823104, 472268800, 411721728, 617443328, 737630208, 507706368, 176263680, 516018944, 597800320, 345030592, 304709536, 339580176, 208643976, 1040657612, 492481066, 520379095 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 838860800, 654311424, 1048576000, 499122176, 782237696, 640679936, 620232704, 688652288, 393871360, 96272384, 272859136, 1058029568, 76046336, 253022208, 698800128, 292512768, 932926976, 762134784, 963313536, 246702784, 1024897504, 844529680, 724969352, 279316172, 586049514, 668696863 + ], + [ + 536870912, 268435456, 671088640, 469762048, 369098752, 452984832, 981467136, 884998144, 241172480, 202375168, 261619712, 797179904, 794689536, 355139584, 1019052032, 564903936, 930914304, 927649792, 514598912, 20147200, 678986240, 567635200, 610678656, 1071546944, 1022072800, 996005968, 1073424488, 340125204, 29332866, 150667075 + ], + [ + 536870912, 805306368, 939524096, 603979776, 704643072, 721420288, 461373440, 356515840, 283115520, 248512512, 197656576, 689700864, 628752384, 577830912, 158957568, 348504064, 655302656, 715542528, 783013888, 54107136, 1034275328, 194983680, 604921472, 489032256, 233514720, 920238800, 703952904, 630590476, 322122254, 858651401 + ], + [ + 536870912, 268435456, 939524096, 738197504, 503316480, 989855744, 109051904, 314572800, 849346560, 697303040, 397934592, 453771264, 269615104, 134021120, 152731648, 580435968, 131981312, 273362944, 444708864, 616580096, 497061376, 487637248, 544811648, 338489536, 767795424, 807775056, 153612936, 212026564, 211121902, 307175003 + ], + [ + 536870912, 805306368, 671088640, 67108864, 369098752, 50331648, 8388608, 666894336, 505413632, 40894464, 98041856, 647757824, 674365440, 702742528, 1040875520, 439336960, 672260096, 650661888, 886425600, 86412288, 904172032, 522081024, 606705792, 872698432, 525207712, 427913264, 104865960, 73444412, 1007811234, 684241725 + ], + [ + 536870912, 805306368, 939524096, 603979776, 570425344, 989855744, 830472192, 943718400, 471859200, 766509056, 1010302976, 619970560, 22151168, 267714560, 953384960, 733265920, 586326016, 520474624, 340490240, 842030080, 829995520, 206945536, 404903808, 1059888320, 527945760, 781076048, 1008359304, 265854156, 69586990, 1048266329 + ], + [ + 536870912, 805306368, 134217728, 67108864, 100663296, 16777216, 343932928, 901775360, 211812352, 550502400, 611844096, 4980736, 574488576, 111083520, 307134464, 943112192, 1031462912, 231002112, 1067177984, 905313280, 416453120, 225449728, 539607424, 435501632, 718521376, 40945616, 833168424, 1051989980, 313719850, 981593053 + ], + [ + 536870912, 268435456, 134217728, 872415232, 436207616, 788529152, 998244352, 742391808, 421527552, 540016640, 680001536, 46399488, 1058406400, 360120320, 266829824, 387956736, 175267840, 579907584, 888719360, 997037056, 702723584, 417914624, 928288384, 477000384, 609966304, 1042559568, 558282984, 762266196, 853151978, 988112473 + ], + [ + 536870912, 268435456, 402653184, 738197504, 503316480, 922746880, 8388608, 247463936, 702545920, 116391936, 276299776, 546045952, 47841280, 750452736, 738951168, 793985024, 315498496, 798806016, 72509440, 72346624, 576576000, 523384064, 629019264, 742758720, 923762976, 285079024, 258187560, 257304052, 601901358, 334596607 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 234881024, 16777216, 1015021568, 12582912, 429916160, 630194176, 918028288, 583270400, 114688000, 696320000, 104955904, 308396032, 867295232, 543715328, 815532032, 610526208, 622790144, 126635264, 588999808, 452629952, 403310112, 730009264, 451805192, 109379596, 330792974, 598786063 + ], + [ + 536870912, 268435456, 134217728, 603979776, 905969664, 654311424, 478150656, 960495616, 132120576, 344981504, 167247872, 142344192, 656539648, 939982848, 338264064, 509919232, 399466496, 81629184, 894568448, 384736256, 342724096, 966427904, 1016841088, 689643328, 131763744, 939162096, 214573992, 767734708, 487982602, 84990221 + ], + [ + 536870912, 268435456, 134217728, 67108864, 905969664, 687865856, 562036736, 37748736, 245366784, 118489088, 139984896, 170655744, 634781696, 204668928, 777093120, 544784384, 201089024, 854560768, 317716480, 49267712, 183426560, 250578688, 955129216, 300900928, 812517280, 841972176, 1016020008, 1000298644, 868644874, 971703301 + ], + [ + 536870912, 805306368, 939524096, 469762048, 100663296, 822083584, 159383552, 725614592, 480247808, 53477376, 150470656, 772538368, 802029568, 219742208, 312311808, 1049083904, 573431808, 440381440, 268519424, 134294528, 604023296, 436309248, 922772864, 947951040, 583129440, 937442800, 529582600, 197786892, 653577614, 29493703 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 100663296, 50331648, 192937984, 918552576, 715128832, 164626432, 915931136, 993787904, 223739904, 710737920, 849772544, 710197248, 442720256, 835645440, 1012955136, 863054848, 122260992, 832887040, 812372096, 604743104, 326892896, 775126384, 446050440, 578655684, 993453422, 875405695 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 33554432, 117440512, 780140544, 1010827264, 228589568, 258998272, 984088576, 672399360, 710541312, 555679744, 542932992, 136232960, 333291520, 165572608, 851208192, 844049408, 591709696, 1027856128, 709046912, 482546880, 880958688, 119772144, 223520360, 511367996, 615437442, 1058304963 + ], + [ + 536870912, 268435456, 402653184, 335544320, 33554432, 184549376, 729808896, 859832320, 132120576, 470810624, 33030144, 297533440, 802029568, 283574272, 990085120, 788611072, 562094080, 876638208, 979429376, 642847744, 647536128, 359463168, 446121344, 447467584, 153477792, 799259728, 619713704, 610799956, 805613358, 101845009 + ], + [ + 536870912, 268435456, 939524096, 872415232, 637534208, 1056964608, 864026624, 432013312, 127926272, 693108736, 721944576, 998506496, 347996160, 445972480, 282492928, 257998848, 1047601152, 35188736, 602691584, 726313984, 422721024, 925769984, 129877120, 985892160, 267830944, 980489648, 202972296, 283961668, 181096622, 435356861 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 33554432, 822083584, 310378496, 608174080, 199229440, 800063488, 382205952, 503054336, 305004544, 872873984, 835354624, 636239872, 750166016, 176304128, 634451968, 246959104, 773135872, 868358400, 380672128, 273221824, 532435488, 382621136, 976743464, 549616860, 87133358, 1049114643 + ], + [ + 536870912, 805306368, 134217728, 603979776, 704643072, 150994944, 159383552, 415236096, 492830720, 714080256, 715653120, 948174848, 956956672, 192872448, 701267968, 224378880, 1073504256, 294121472, 998266880, 230728704, 316774912, 894518528, 491299712, 173313984, 528627296, 483041008, 228503016, 1050494268, 1024940426, 371800773 + ], + [ + 536870912, 805306368, 939524096, 201326592, 838860800, 520093696, 75497472, 717225984, 874512384, 210763776, 98041856, 786169856, 982646784, 561184768, 105021440, 659243008, 867115008, 919646208, 356075520, 57469952, 609909248, 372685568, 334286720, 10148160, 924281760, 150747440, 419613608, 405522748, 241083302, 469275967 + ], + [ + 536870912, 805306368, 671088640, 201326592, 905969664, 184549376, 243269632, 490733568, 576716800, 697303040, 959971328, 218365952, 756154368, 1046937600, 136085504, 426164224, 10231808, 656822272, 545105920, 636996608, 807759360, 266486016, 961534848, 518051648, 902936288, 14278192, 810935656, 327914876, 785520002, 424019535 + ], + [ + 536870912, 805306368, 134217728, 201326592, 905969664, 620756992, 276824064, 348127232, 48234496, 707788800, 648544256, 561250304, 467533824, 713621504, 715489280, 717635584, 622157824, 808333312, 373319680, 958489600, 592532992, 567893760, 930899328, 599440192, 799971488, 956410224, 511817224, 901852940, 677473666, 770830147 + ], + [ + 536870912, 268435456, 671088640, 335544320, 771751936, 721420288, 864026624, 507510784, 65011712, 533725184, 1018691584, 55836672, 436338688, 266928128, 741113856, 133644288, 777756672, 820834304, 1020696576, 481000448, 698655232, 793507584, 242539136, 804510656, 924884896, 821089680, 541604360, 824019716, 975108234, 58092741 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 838860800, 855638016, 578813952, 448790528, 278921216, 644874240, 135790592, 243007488, 549584896, 671416320, 778993664, 867057664, 529424384, 171921408, 1057404928, 491496448, 217185792, 1054456064, 81549696, 162721728, 815599456, 164768336, 558712712, 188368580, 1021939434, 614740383 + ], + [ + 536870912, 805306368, 402653184, 201326592, 838860800, 654311424, 461373440, 616562688, 811597824, 296747008, 848822272, 856424448, 414056448, 297467904, 190349312, 468533248, 274636800, 780333056, 386148352, 942318592, 256924160, 191419648, 380987008, 582131008, 677209760, 768032784, 302930472, 359270492, 217111054, 691639567 + ], + [ + 536870912, 268435456, 671088640, 603979776, 637534208, 16777216, 696254464, 205520896, 1029701632, 909115392, 217579520, 817102848, 589955072, 121700352, 132153344, 485572608, 827924480, 941961216, 700581888, 433867776, 586605056, 968338176, 341250432, 195532736, 880700832, 681215312, 435716104, 120930308, 577445898, 295710729 + ], + [ + 536870912, 805306368, 671088640, 67108864, 33554432, 1056964608, 578813952, 817889280, 174063616, 267386880, 915931136, 1046740992, 660209664, 267190272, 546799616, 36323328, 1035247616, 1049808896, 293705728, 608216064, 799092224, 470851328, 690552192, 224238016, 1043254176, 555644816, 770108296, 879915724, 565248042, 305763665 + ], + [ + 536870912, 268435456, 939524096, 738197504, 234881024, 956301312, 880803840, 784334848, 350224384, 122683392, 1070071808, 714342400, 875167744, 223805440, 89751552, 104677376, 548315136, 320081920, 476788736, 947301376, 929575424, 719642880, 919860608, 714764480, 860873952, 834961136, 769852264, 180600628, 670206470, 313199887 + ], + [ + 536870912, 268435456, 671088640, 872415232, 838860800, 620756992, 327155712, 247463936, 379584512, 124780544, 216530944, 476839936, 490864640, 27066368, 854228992, 244334592, 251207680, 248827904, 41322496, 234490880, 61398528, 822995200, 923970944, 818274880, 114221280, 768571728, 223225224, 789507652, 904838890, 192925789 + ], + [ + 536870912, 268435456, 939524096, 67108864, 369098752, 251658240, 176160768, 130023424, 773849088, 594542592, 260571136, 201064448, 735707136, 574685184, 861962240, 848412672, 114827264, 822390784, 548304896, 149378048, 1027325440, 227619072, 609778560, 180694080, 479115232, 848741072, 926056456, 187482116, 643997710, 634679297 + ], + [ + 536870912, 268435456, 939524096, 469762048, 637534208, 117440512, 562036736, 4194304, 1012924416, 1016070144, 469237760, 9175040, 948830208, 1033961472, 280002560, 587841536, 1004855296, 100347904, 44251136, 874417152, 240665088, 876364544, 562558080, 658782144, 868909152, 6959728, 869949448, 190050308, 301422606, 250379271 + ], + [ + 536870912, 805306368, 671088640, 469762048, 436207616, 385875968, 578813952, 968884224, 463470592, 607125504, 734527488, 270270464, 774504448, 720306176, 836796416, 433111040, 806985728, 50606080, 162424832, 394308608, 138500608, 786453248, 391191680, 1004056512, 329606816, 354346416, 310962216, 561874300, 490414082, 232255499 + ], + [ + 536870912, 268435456, 134217728, 872415232, 234881024, 553648128, 142606336, 910163968, 740294656, 1001390080, 838336512, 534511616, 347471872, 630915072, 662011904, 188923904, 10018816, 936202240, 1027553280, 593488896, 583927296, 897981184, 690133120, 990507072, 260311072, 136010448, 263465128, 203654804, 629720714, 616863561 + ], + [ + 536870912, 268435456, 671088640, 872415232, 436207616, 16777216, 427819008, 356515840, 627048448, 330301440, 410517504, 583270400, 853671936, 865271808, 952860672, 677298176, 867524608, 297447424, 386349056, 958411776, 189890048, 747218176, 719102080, 1509184, 222930784, 360462704, 612835176, 358731124, 732987746, 74979449 + ], + [ + 536870912, 268435456, 134217728, 335544320, 905969664, 587202560, 595591168, 322961408, 631242752, 760217600, 1027080192, 572784640, 137756672, 782172160, 1013153792, 553762816, 645947392, 465653760, 23070720, 766620672, 382246400, 298625792, 74112384, 556576320, 932909664, 247855440, 432407656, 343287380, 314550250, 192066321 + ], + [ + 536870912, 268435456, 939524096, 201326592, 234881024, 520093696, 1015021568, 624951296, 467664896, 781189120, 794296320, 56885248, 843448320, 567738368, 856653824, 246038528, 852238336, 220942336, 990652416, 193694720, 41715200, 71436544, 826398080, 165798720, 126918240, 14169424, 346338920, 333953364, 673591398, 394702935 + ], + [ + 536870912, 805306368, 939524096, 201326592, 503316480, 150994944, 880803840, 784334848, 119537664, 267386880, 310902784, 298057728, 789708800, 341377024, 230522880, 752861184, 374300672, 651587584, 122357760, 1071940608, 610510336, 269492480, 391676800, 306003520, 429804832, 237902864, 709348872, 986895628, 16264590, 688757571 + ], + [ + 536870912, 805306368, 939524096, 469762048, 570425344, 721420288, 360710144, 826277888, 35651584, 963641344, 876085248, 472645632, 724959232, 243859456, 620068864, 839630848, 22536192, 56201216, 696064000, 394234880, 69040640, 355457280, 265617280, 100394944, 699312736, 806730544, 454812168, 1069454604, 494790030, 561999559 + ], + [ + 536870912, 805306368, 402653184, 201326592, 973078528, 654311424, 511705088, 138412032, 442499072, 110100480, 1009254400, 794034176, 2228224, 648740864, 810450944, 825507840, 414392320, 327315456, 278530048, 987126784, 364490240, 704419072, 154594688, 770210496, 334852448, 210962416, 175341416, 530752252, 90847982, 267301951 + ], + [ + 536870912, 268435456, 671088640, 872415232, 167772160, 486539264, 796917760, 373293056, 115343360, 630194176, 626524160, 434372608, 788135936, 134021120, 645824512, 114704384, 1010442240, 199004160, 63866880, 272550912, 271985152, 833303296, 444951168, 271246272, 600063648, 944480912, 26591368, 447975620, 159478826, 222351709 + ], + [ + 536870912, 805306368, 402653184, 738197504, 369098752, 50331648, 998244352, 968884224, 1029701632, 516947968, 106430464, 149159936, 789708800, 1039335424, 283279360, 651837440, 611262464, 426086400, 735217664, 202626048, 913529344, 824381696, 934950784, 750693696, 473771616, 414663920, 448794216, 920769788, 1058014830, 389562615 + ], + [ + 536870912, 805306368, 402653184, 738197504, 771751936, 50331648, 260046848, 297795584, 287309824, 802160640, 83361792, 532414464, 122028032, 32571392, 581533696, 1032110080, 73097216, 363229184, 973117440, 822164480, 981544448, 826317056, 559945344, 741360576, 898109408, 626277680, 220461064, 920341516, 552056326, 23110923 + ], + [ + 536870912, 268435456, 671088640, 603979776, 905969664, 956301312, 947912704, 759169024, 966787072, 1064304640, 565706752, 637272064, 501350400, 721092608, 569868288, 543997952, 529195008, 323932160, 1041291264, 1017674752, 450168320, 905442048, 778839168, 713799488, 969881504, 475056688, 76075432, 811985204, 11414818, 222372477 + ], + [ + 536870912, 268435456, 939524096, 872415232, 33554432, 855638016, 847249408, 926941184, 241172480, 242221056, 1018691584, 105119744, 128581632, 290914304, 918126592, 692404224, 992632832, 588689408, 995624960, 301288448, 204623360, 302217472, 5900416, 875551296, 131865056, 738145904, 456417128, 429102388, 408047110, 192117001 + ], + [ + 536870912, 268435456, 939524096, 335544320, 973078528, 16777216, 562036736, 12582912, 689963008, 684720128, 120061952, 60030976, 295567360, 415039488, 336232448, 505593856, 37167104, 275353600, 360048640, 854572032, 50626048, 584523008, 202933376, 743201344, 812778784, 593433136, 211614344, 190531396, 919241134, 839075957 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 838860800, 520093696, 377487360, 633339904, 950009856, 59768832, 190316544, 1035730944, 241041408, 14352384, 361267200, 914702336, 424878080, 151875584, 215410688, 887065600, 1058732544, 371800832, 764772736, 449462848, 93393184, 844629520, 574474920, 740249436, 641372686, 49870595 + ], + [ + 536870912, 268435456, 134217728, 872415232, 369098752, 822083584, 545259520, 994050048, 148897792, 919601152, 211288064, 6553600, 983433216, 424345600, 945651712, 88784896, 173858816, 709595136, 802977792, 663464960, 763178496, 960181504, 745866624, 1025941568, 543085792, 308941648, 19745128, 367234836, 393300874, 229164361 + ], + [ + 536870912, 805306368, 134217728, 67108864, 33554432, 285212672, 1048576000, 683671552, 316669952, 277872640, 470286336, 2359296, 507904000, 297992192, 917798912, 558874624, 912744448, 984788992, 145512448, 329423872, 702923264, 170322176, 630341504, 1046281920, 586880096, 464014992, 1024773096, 444514396, 559835018, 632185549 + ], + [ + 536870912, 805306368, 134217728, 469762048, 369098752, 788529152, 310378496, 289406976, 165675008, 600834048, 145227776, 549191680, 155582464, 923467776, 991199232, 494649344, 135110656, 192925696, 50235392, 994020352, 312372736, 422550784, 664229248, 941767104, 694711200, 756852560, 16158248, 749863580, 253836170, 552707275 + ], + [ + 536870912, 805306368, 939524096, 738197504, 167772160, 1023410176, 461373440, 616562688, 975175680, 355467264, 647495680, 175898624, 413532160, 815464448, 492601344, 504774656, 650354688, 184659968, 612497408, 373396480, 593545728, 1020350208, 789073024, 110389056, 715362336, 223407696, 113859752, 523618588, 928246918, 468309831 + ], + [ + 536870912, 805306368, 402653184, 67108864, 838860800, 822083584, 562036736, 926941184, 207618048, 835715072, 873988096, 307494912, 158728192, 312541184, 653361152, 665370624, 278667264, 230395904, 776112128, 663194624, 420084224, 409797376, 756219520, 475961536, 234686112, 770323888, 891002888, 1035096076, 330246150, 265608193 + ], + [ + 536870912, 805306368, 939524096, 67108864, 234881024, 385875968, 578813952, 717225984, 601882624, 149946368, 871890944, 563347456, 17432576, 520028160, 323256320, 90324992, 27451392, 88264704, 389253120, 168479744, 109007360, 411427072, 386065536, 252949056, 681289312, 1060607600, 449422056, 688780348, 598674566, 1047391821 + ], + [ + 536870912, 805306368, 939524096, 201326592, 503316480, 385875968, 92274688, 717225984, 157286400, 19922944, 296222720, 531890176, 857866240, 808910848, 180649984, 715800576, 571645952, 698224640, 561055744, 193508352, 455354880, 836449536, 614147712, 171689664, 988414432, 3362864, 554633064, 1032374012, 136621702, 509227727 + ], + [ + 536870912, 268435456, 402653184, 603979776, 973078528, 83886080, 327155712, 213909504, 1012924416, 665845760, 416808960, 105119744, 609615872, 1052966912, 125665280, 442646528, 783081472, 470446080, 1034958848, 232330240, 231074304, 211193088, 950178432, 634139968, 289131488, 606645008, 71139688, 616823380, 310220942, 300140621 + ], + [ + 536870912, 805306368, 402653184, 872415232, 301989888, 50331648, 931135488, 381681664, 723517440, 68157440, 68681728, 1044119552, 719716352, 135069696, 40861696, 761905152, 240394240, 103960576, 645838848, 426880000, 678030848, 416646400, 1014212224, 404681152, 847312224, 4275696, 291585672, 980487628, 803840870, 370414845 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 436207616, 150994944, 377487360, 658505728, 136314880, 261095424, 258473984, 1011613696, 663355392, 242024448, 823820288, 260423680, 370630656, 976162816, 518662144, 316482560, 174248448, 727713024, 833666688, 200857152, 279296224, 805722128, 260562568, 776455748, 422023398, 580353055 + ], + [ + 536870912, 805306368, 671088640, 872415232, 167772160, 251658240, 511705088, 205520896, 652214272, 495976448, 827850752, 515112960, 598081536, 445710336, 735674368, 821379072, 1044881408, 327241728, 432142336, 371307520, 204587520, 514418432, 826053760, 875265728, 911447968, 89565744, 43644936, 932557836, 420987402, 1014523661 + ], + [ + 536870912, 805306368, 402653184, 872415232, 771751936, 318767104, 1048576000, 364904448, 14680064, 32505856, 119013376, 595329024, 257556480, 361299968, 903184384, 748601344, 931045376, 336588800, 81188864, 776606720, 593509888, 162598656, 884568960, 61680320, 659795680, 589082704, 543835656, 15854348, 412620166, 423489997 + ], + [ + 536870912, 805306368, 671088640, 872415232, 1040187392, 452984832, 494927872, 432013312, 803209216, 477102080, 173539328, 40632320, 453115904, 5439488, 823820288, 304070656, 512253952, 333746176, 459786240, 838165504, 110004736, 790742272, 252812928, 527020096, 211068192, 280978992, 542739752, 393040444, 897756962, 806511409 + ], + [ + 536870912, 805306368, 671088640, 469762048, 369098752, 16777216, 25165824, 339738624, 195035136, 726663168, 346554368, 424411136, 317849600, 756482048, 900235264, 684507136, 783523840, 985092096, 150484992, 1030013952, 914296320, 1007005440, 776880000, 597539776, 169582880, 200954608, 101355688, 108152380, 47648258, 357150475 + ], + [ + 536870912, 805306368, 939524096, 872415232, 301989888, 218103808, 662700032, 968884224, 908066816, 588251136, 866648064, 325844992, 256245760, 278069248, 286294016, 245907456, 216817664, 42414080, 884209664, 1057084416, 444641792, 641736448, 1004640640, 120618432, 498618912, 121901904, 636125608, 703964572, 580122630, 739365889 + ], + [ + 536870912, 268435456, 939524096, 335544320, 100663296, 184549376, 276824064, 29360128, 899678208, 326107136, 299368448, 559153152, 516292608, 158793728, 177176576, 65683456, 563404800, 854052864, 1044776960, 548916224, 321823232, 43753216, 1028484224, 137510464, 834682592, 497101776, 1064417000, 64530388, 743830758, 88598737 + ], + [ + 536870912, 805306368, 402653184, 603979776, 234881024, 754974720, 612368384, 331350016, 807403520, 212860928, 746061824, 647757824, 920256512, 374800384, 377782272, 580337664, 287629312, 744935424, 507303936, 732621824, 353241600, 522835712, 745926784, 193925184, 132686368, 701817264, 444557992, 728813052, 978950798, 992761669 + ], + [ + 536870912, 268435456, 671088640, 603979776, 905969664, 520093696, 645922816, 348127232, 685768704, 737148928, 296222720, 143917056, 1063124992, 911015936, 597852160, 484851712, 553689088, 226521088, 742430720, 119645184, 328330752, 832080640, 391957888, 150694976, 811293728, 915122224, 296991624, 54477636, 813498282, 191500153 + ], + [ + 536870912, 268435456, 134217728, 335544320, 436207616, 419430400, 645922816, 1019215872, 455081984, 655360000, 704118784, 64749568, 41549824, 374538240, 542605312, 727826432, 32530432, 793260032, 1073002496, 813640704, 258284032, 130452224, 962152320, 881626688, 493025696, 457059056, 168090536, 355880436, 563144234, 87586993 + ], + [ + 536870912, 805306368, 134217728, 67108864, 167772160, 318767104, 645922816, 314572800, 379584512, 13631488, 580386816, 100925440, 666501120, 760938496, 501907456, 721600512, 407822336, 937996288, 986523648, 501718016, 340019712, 249192192, 212519296, 484615488, 662671712, 776000176, 794947944, 1022468796, 1049147754, 725372605 + ], + [ + 536870912, 268435456, 939524096, 201326592, 771751936, 83886080, 746586112, 322961408, 81788928, 577765376, 320339968, 300154880, 6946816, 455409664, 323649536, 452247552, 79880192, 293187584, 802473984, 605279232, 812765696, 270054144, 207905152, 497793984, 663058080, 475665552, 341631368, 295599044, 644290222, 99771539 + ], + [ + 536870912, 268435456, 939524096, 67108864, 33554432, 218103808, 92274688, 62914560, 878706688, 17825792, 199753728, 262930432, 893517824, 371392512, 196313088, 1008353280, 219570176, 178548736, 415176704, 648590336, 579660288, 863119616, 721080704, 994465472, 896384928, 782462896, 636739496, 935010228, 1046923174, 257731509 + ], + [ + 536870912, 805306368, 134217728, 67108864, 1040187392, 352321536, 713031680, 1035993088, 929038336, 189792256, 709361664, 443809792, 834273280, 591724544, 35880960, 582565888, 613261312, 269987840, 270764032, 1035478016, 755795456, 374771456, 235103360, 692662592, 301249824, 284820880, 954551432, 714253644, 727825186, 156348049 + ], + [ + 536870912, 268435456, 671088640, 335544320, 436207616, 721420288, 998244352, 608174080, 887095296, 542113792, 623378432, 190578688, 358481920, 1033043968, 54886400, 943439872, 802742272, 29683712, 150652928, 922297344, 238333440, 417504512, 933026176, 981424576, 1063505056, 232590992, 396254504, 464761684, 758407042, 660803777 + ], + [ + 536870912, 805306368, 671088640, 603979776, 436207616, 184549376, 1031798784, 331350016, 593494016, 609222656, 463994880, 751566848, 1020657664, 992280576, 398163968, 725762048, 900177920, 75304960, 267368448, 547380224, 523286016, 871972608, 157624448, 18506816, 829594080, 48131696, 207101576, 433331020, 237212010, 1022843449 + ], + [ + 536870912, 268435456, 939524096, 335544320, 436207616, 385875968, 159383552, 918552576, 228589568, 823132160, 213385216, 327417856, 251002880, 445579264, 430669824, 13385728, 1035722752, 385134592, 863913984, 543351808, 113271296, 631244544, 487689088, 45726784, 512012128, 276174672, 634342760, 583684180, 1014834918, 1268753 + ], + [ + 536870912, 268435456, 134217728, 469762048, 503316480, 587202560, 696254464, 1010827264, 333447168, 611319808, 73924608, 192675840, 276168704, 630784000, 894730240, 1072316416, 975167488, 367357952, 413390848, 607316992, 564818432, 83801856, 856971136, 353000768, 519007968, 625802032, 687843848, 890592004, 571123074, 896444999 + ], + [ + 536870912, 268435456, 134217728, 335544320, 973078528, 452984832, 176160768, 96468992, 656408576, 15728640, 620232704, 942407680, 669122560, 1054539776, 769097728, 751157248, 65429504, 1033646080, 586885120, 933633024, 100499968, 149574400, 546187392, 601406784, 685573920, 186289328, 318178600, 808787892, 153046442, 615617265 + ], + [ + 536870912, 268435456, 402653184, 335544320, 704643072, 385875968, 914358272, 994050048, 346030080, 653262848, 699924480, 867434496, 506855424, 1057161216, 947224576, 148258816, 517169152, 972845056, 565946368, 759196672, 899751424, 561010432, 225984128, 399852608, 916920160, 690637456, 728312296, 1052511956, 52149902, 984613953 + ], + [ + 536870912, 268435456, 402653184, 469762048, 503316480, 16777216, 847249408, 1035993088, 98566144, 818937856, 1023934464, 364118016, 648151040, 977076224, 517373952, 25149440, 138108928, 1017229312, 502310912, 549012480, 648934912, 645874432, 934999168, 903888192, 953199136, 956912848, 397738632, 966950468, 163372710, 295086487 + ], + [ + 536870912, 268435456, 402653184, 67108864, 369098752, 150994944, 394264576, 113246208, 987758592, 433061888, 434634752, 743178240, 796000256, 985726976, 954236928, 516997120, 57155584, 722251776, 441600000, 242334720, 1041806848, 294983424, 428273280, 660045632, 876522080, 120752016, 425754632, 17874948, 906502150, 807186433 + ], + [ + 536870912, 268435456, 402653184, 603979776, 637534208, 520093696, 880803840, 633339904, 652214272, 730857472, 198705152, 924581888, 262275072, 146341888, 1053589504, 702201856, 169091072, 977776640, 947337216, 807339008, 187391488, 220049152, 44214400, 490232000, 344802272, 947561360, 1034255880, 141500164, 182653062, 630758601 + ], + [ + 536870912, 268435456, 402653184, 469762048, 33554432, 956301312, 662700032, 264241152, 1004535808, 995098624, 425197568, 830734336, 1043464192, 96927744, 396197888, 789987328, 772087808, 1039298560, 606476288, 164467712, 332337664, 692144384, 530663808, 359691840, 1021873632, 906818864, 539982952, 370222964, 419027854, 536117059 + ], + [ + 536870912, 805306368, 939524096, 201326592, 369098752, 553648128, 729808896, 683671552, 1004535808, 716177408, 847773696, 684982272, 951975936, 655425536, 177831936, 751681536, 892493824, 973320192, 1028360192, 738073600, 1009804800, 801722112, 787828096, 409931840, 552199328, 564431088, 357984264, 188050444, 772673038, 999826179 + ], + [ + 536870912, 268435456, 134217728, 738197504, 234881024, 83886080, 780140544, 1052770304, 534773760, 749731840, 720896000, 111935488, 858390528, 150274048, 60194816, 976699392, 111599616, 462401536, 44730368, 666215424, 590745088, 1042805504, 72310656, 298496704, 1053140448, 1034814992, 75182472, 1018999236, 750916194, 137421019 + ], + [ + 536870912, 805306368, 402653184, 469762048, 100663296, 419430400, 864026624, 574619648, 39845888, 160432128, 854065152, 844365824, 616693760, 227082240, 574980096, 862633984, 188604416, 416788480, 892012544, 593361920, 373711360, 826538752, 113868928, 195378496, 79361440, 1035220112, 974357000, 276843276, 1052805254, 312590663 + ], + [ + 536870912, 268435456, 939524096, 469762048, 905969664, 654311424, 897581056, 222298112, 186646528, 252706816, 1069023232, 69468160, 705560576, 733806592, 851083264, 743096320, 1065574400, 11530240, 736991232, 857979904, 536789504, 66329856, 1003910784, 262765248, 35395232, 762031664, 831771784, 362190788, 185202734, 692873463 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 905969664, 620756992, 813694976, 1069547520, 98566144, 808452096, 599261184, 394526720, 442892288, 726597632, 962822144, 485081088, 818749440, 171577344, 333215744, 47422464, 957354496, 334050560, 55419008, 679115584, 628954208, 1052976336, 175758952, 660954580, 316060906, 188112795 + ], + [ + 536870912, 805306368, 671088640, 738197504, 369098752, 83886080, 947912704, 1052770304, 153092096, 275775488, 392691712, 274464768, 683278336, 958201856, 752582656, 655114240, 513990656, 346615808, 368887808, 336212992, 408272384, 125222144, 463412608, 948098624, 928548704, 97795984, 825662856, 75470412, 231991146, 641830811 + ], + [ + 536870912, 268435456, 939524096, 738197504, 838860800, 1056964608, 92274688, 79691776, 450887680, 814743552, 918028288, 877920256, 374996992, 671547392, 968982528, 140591104, 634429440, 915992576, 321153024, 720622592, 732629504, 99578112, 474813312, 842928448, 97789792, 479893616, 132609768, 533830708, 228163590, 816136207 + ], + [ + 536870912, 268435456, 402653184, 738197504, 503316480, 385875968, 427819008, 171966464, 547356672, 519045120, 227016704, 871628800, 530186240, 175177728, 860389376, 1033158656, 386621440, 594145280, 933509120, 836897792, 143405568, 99054848, 203394944, 60964928, 338460064, 488006096, 982923272, 936840196, 385266182, 776385803 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 1040187392, 721420288, 1065353216, 306184192, 257949696, 938475520, 827850752, 452198400, 197525504, 814809088, 178880512, 1034764288, 104062976, 987164672, 58316800, 132463616, 506343936, 48065280, 346724224, 1040412352, 867096992, 496797488, 457848840, 640928780, 181922314, 729306895 + ], + [ + 536870912, 268435456, 134217728, 67108864, 1040187392, 218103808, 92274688, 239075328, 568328192, 1060110336, 217579520, 44826624, 932315136, 296550400, 789741568, 309149696, 78815232, 851226624, 981125120, 963156992, 17086976, 1052152576, 9094016, 254883008, 351876832, 246192208, 227722120, 581776580, 663959266, 430807121 + ], + [ + 536870912, 268435456, 939524096, 738197504, 33554432, 184549376, 142606336, 1010827264, 677380096, 711983104, 376963072, 445906944, 366608384, 962265088, 52133888, 913981440, 831201280, 439562240, 386361344, 873278464, 629132800, 681118976, 765730432, 1010994496, 327150048, 496561968, 338029032, 797175604, 232679910, 684306239 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 436207616, 352321536, 176160768, 994050048, 773849088, 781189120, 640155648, 909377536, 239206400, 891224064, 994607104, 981778432, 888840192, 201469952, 331282432, 798571520, 504147456, 404675328, 365469056, 264628672, 702211808, 655613104, 290870632, 105655932, 733908482, 194521859 + ], + [ + 536870912, 268435456, 671088640, 201326592, 570425344, 520093696, 612368384, 54525952, 153092096, 311427072, 222822400, 790888448, 165019648, 500760576, 762085376, 712196096, 458186752, 462721024, 177158144, 418710528, 750774784, 300802304, 489924736, 342754368, 939799072, 507995952, 252760584, 193520900, 348406410, 648537411 + ], + [ + 536870912, 268435456, 939524096, 738197504, 771751936, 218103808, 25165824, 943718400, 610271232, 128974848, 470286336, 1061421056, 387842048, 632356864, 789086208, 197509120, 48193536, 395341824, 30992384, 301845504, 433234432, 464212736, 885511552, 122465344, 39458848, 95374320, 70838280, 1041091588, 431661582, 257905419 + ], + [ + 536870912, 805306368, 939524096, 738197504, 33554432, 285212672, 847249408, 574619648, 782237696, 101711872, 746061824, 800325632, 376832000, 3211264, 86605824, 636338176, 546529280, 606015488, 536610816, 116118528, 246067712, 353010944, 932964480, 111304640, 641190816, 932211888, 632907784, 97895436, 847723022, 402166027 + ], + [ + 536870912, 805306368, 134217728, 603979776, 167772160, 788529152, 8388608, 759169024, 836763648, 267386880, 782761984, 762052608, 520749056, 182255616, 532905984, 226574336, 381722624, 505417728, 407918592, 439899136, 242487808, 766479104, 436868480, 358382144, 973264096, 891415824, 584174984, 276393548, 454321890, 85947929 + ], + [ + 536870912, 268435456, 402653184, 469762048, 301989888, 956301312, 796917760, 130023424, 895483904, 32505856, 266862592, 231473152, 551944192, 77791232, 855212032, 991182848, 388112384, 926511104, 796252160, 626160640, 756064768, 786007296, 734309504, 563866816, 613269280, 835160656, 1039372712, 746623892, 88168974, 186745091 + ], + [ + 536870912, 805306368, 134217728, 872415232, 100663296, 788529152, 746586112, 104857600, 480247808, 735051776, 1018691584, 972292096, 977928192, 226820096, 195264512, 461979648, 624697344, 72773632, 113498112, 809096192, 263490048, 787112192, 307625088, 823904448, 226348320, 871842192, 261227656, 297823436, 6332194, 372372637 + ], + [ + 536870912, 268435456, 671088640, 469762048, 1040187392, 989855744, 746586112, 624951296, 312475648, 397410304, 484966400, 859570176, 503185408, 984023040, 326336512, 850444288, 459874304, 318525440, 907986944, 28724224, 589960704, 837032704, 283779712, 654680000, 142314272, 1016896848, 969889064, 630114900, 246374818, 64966291 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 234881024, 620756992, 880803840, 79691776, 450887680, 1020264448, 749207552, 1067188224, 522321920, 294322176, 488013824, 129351680, 343875584, 1011470336, 206387200, 940293120, 156649984, 60138752, 625934208, 867193024, 171526432, 840216496, 621740840, 93391548, 269089954, 745364083 + ], + [ + 536870912, 805306368, 939524096, 67108864, 436207616, 150994944, 746586112, 205520896, 44040192, 238026752, 956825600, 252968960, 48103424, 671940608, 364085248, 65978368, 444899328, 291934208, 777037824, 81269760, 873282048, 1001593088, 686729088, 990213952, 732379168, 699477296, 617190792, 259385932, 252677550, 722835313 + ], + [ + 536870912, 268435456, 671088640, 603979776, 234881024, 956301312, 260046848, 289406976, 211812352, 95420416, 428343296, 869531648, 1029308416, 377028608, 712802304, 184500224, 1036656640, 369225728, 620759040, 226499584, 37870080, 874634496, 577870208, 199768640, 730165664, 767795792, 966087176, 1031438596, 302539658, 1016403785 + ], + [ + 536870912, 268435456, 671088640, 335544320, 234881024, 83886080, 243269632, 381681664, 379584512, 248512512, 842530816, 819200000, 1007550464, 666173440, 637435904, 538722304, 955392000, 586559488, 448858112, 883016704, 970030592, 599265536, 596940928, 938440896, 662975008, 427225776, 981481608, 146868420, 1000413738, 340788917 + ], + [ + 536870912, 805306368, 134217728, 67108864, 301989888, 855638016, 310378496, 683671552, 908066816, 856686592, 849870848, 614727680, 621412352, 448593920, 240615424, 760954880, 661954560, 495144960, 319354880, 1022731264, 549588480, 90807552, 637885056, 400210496, 1001699488, 832795536, 387517576, 249353036, 531010594, 79933649 + ], + [ + 536870912, 268435456, 939524096, 335544320, 100663296, 620756992, 377487360, 792723456, 580911104, 412090368, 306708480, 547094528, 815661056, 247922688, 408125440, 896548864, 947511296, 306532352, 374061056, 415542272, 51013120, 895752960, 974818176, 1038988224, 619076128, 243422800, 756646952, 506847572, 45279654, 717228433 + ], + [ + 536870912, 805306368, 671088640, 469762048, 570425344, 1023410176, 75497472, 985661440, 190840832, 877658112, 215482368, 780402688, 669122560, 195756032, 630620160, 354533376, 904929280, 468234240, 168564736, 666819584, 1070406144, 224274688, 31223680, 237436736, 258596960, 684500464, 417227368, 899518716, 512178146, 383383227 + ], + [ + 536870912, 268435456, 939524096, 67108864, 637534208, 385875968, 142606336, 775946240, 740294656, 743440384, 292028416, 851181568, 742785024, 565903360, 777879552, 1031225344, 69394432, 764973056, 801425408, 145955840, 965813760, 763960064, 864894848, 836698048, 645873056, 451923024, 652706344, 413823892, 26500998, 953823173 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 503316480, 83886080, 226492416, 935329792, 610271232, 338690048, 683147264, 314834944, 132775936, 634454016, 256409600, 337461248, 639623168, 470020096, 119384064, 44018688, 272768512, 767406848, 558872960, 504013248, 1042404384, 395426384, 820529160, 307059716, 597112330, 905928463 + ], + [ + 536870912, 805306368, 939524096, 67108864, 234881024, 587202560, 478150656, 171966464, 526385152, 126877696, 974651392, 121372672, 595722240, 426442752, 400457728, 1064910848, 632053760, 438013952, 43403264, 209521664, 23326208, 423275776, 224806272, 460668736, 285624736, 811914032, 425693096, 741925436, 860646438, 743079037 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 301989888, 352321536, 75497472, 79691776, 576716800, 846200832, 155713536, 814481408, 835846144, 462225408, 710115328, 449593344, 645029888, 152883200, 782944256, 48821248, 1895936, 137029376, 992607616, 452750656, 748411360, 83891152, 478281096, 281046348, 207739370, 896603103 + ], + [ + 536870912, 268435456, 939524096, 738197504, 905969664, 419430400, 8388608, 750780416, 115343360, 735051776, 498597888, 602669056, 977403904, 512688128, 58556416, 274415616, 504602624, 645353472, 842086400, 132705280, 102003200, 697256192, 654120320, 840603968, 20080544, 1036395248, 832131624, 1071426484, 413904262, 370816335 + ], + [ + 536870912, 268435456, 671088640, 738197504, 637534208, 922746880, 327155712, 1002438656, 1000341504, 703594496, 555220992, 378798080, 420610048, 816644096, 439779328, 717635584, 324984832, 596373504, 569907200, 914689024, 681276928, 502376704, 320341376, 60125120, 932316192, 166509776, 1054315400, 282474180, 467048874, 106405659 + ], + [ + 536870912, 805306368, 939524096, 201326592, 905969664, 285212672, 1031798784, 331350016, 815792128, 552599552, 600309760, 746848256, 980287488, 522649600, 853704704, 862797824, 676995072, 501288960, 487643136, 249107456, 442341888, 741558016, 85300352, 653783232, 672867296, 327207952, 1052817896, 52464412, 775007590, 417938399 + ], + [ + 536870912, 805306368, 134217728, 469762048, 570425344, 1023410176, 914358272, 650117120, 450887680, 439353344, 511180800, 948174848, 310509568, 652935168, 449216512, 495501312, 127737856, 678932480, 170989568, 645450752, 746924544, 746763520, 971710592, 289905984, 231248480, 1002288624, 682033256, 242793724, 8729322, 109242555 + ], + [ + 536870912, 805306368, 402653184, 67108864, 905969664, 184549376, 1048576000, 1069547520, 710934528, 732954624, 347602944, 588513280, 897187840, 387121152, 932085760, 798507008, 889544704, 1007898624, 957270016, 140024832, 459608576, 564377856, 649552000, 365806400, 299764960, 483523760, 982038248, 787319228, 130944110, 364408829 + ], + [ + 536870912, 805306368, 939524096, 201326592, 234881024, 318767104, 847249408, 658505728, 367001600, 357564416, 784859136, 663486464, 759824384, 497352704, 941064192, 753319936, 2023424, 55259136, 1051047936, 848806912, 128414208, 469709568, 85699712, 585944896, 844875744, 1057844112, 319438472, 331664460, 696767342, 521101523 + ], + [ + 536870912, 805306368, 134217728, 67108864, 637534208, 16777216, 713031680, 801112064, 937426944, 611319808, 765984768, 741605376, 847118336, 532348928, 808222720, 520339456, 604069888, 369135616, 151091200, 780237824, 163650048, 920701184, 250726528, 40448192, 466990048, 370135504, 840106856, 471375132, 763177610, 1002128845 + ], + [ + 536870912, 268435456, 402653184, 201326592, 369098752, 956301312, 830472192, 180355072, 408944640, 397410304, 668467200, 848560128, 959315968, 159711232, 740720640, 955891712, 696573952, 1009152000, 553166848, 629521408, 707223040, 435695360, 335862656, 552007104, 26854688, 62165424, 121508744, 856488388, 983225126, 247165619 + ], + [ + 536870912, 268435456, 671088640, 67108864, 570425344, 285212672, 8388608, 859832320, 421527552, 609222656, 973602816, 1015808000, 457572352, 417923072, 649887744, 373243904, 792535040, 436178944, 190629888, 328115200, 646236672, 936042752, 732853888, 978674240, 310638944, 671255216, 910387720, 568537348, 32710282, 291182145 + ], + [ + 536870912, 805306368, 402653184, 335544320, 838860800, 553648128, 713031680, 901775360, 882900992, 1053818880, 717750272, 815005696, 485359616, 987037696, 890208256, 1013301248, 725032960, 522735616, 941893632, 500564992, 874055168, 710729984, 880513152, 842663744, 1037749280, 678124592, 1037176968, 31377228, 330066982, 455330869 + ], + [ + 536870912, 268435456, 402653184, 67108864, 33554432, 318767104, 209715200, 46137344, 815792128, 462422016, 445120512, 242483200, 168165376, 1005256704, 1020362752, 594034688, 822403072, 780021760, 178751488, 679181312, 978924032, 723383040, 704883072, 169189568, 943115232, 963840400, 544069736, 75179604, 878184462, 639384581 + ], + [ + 536870912, 268435456, 134217728, 603979776, 100663296, 1023410176, 897581056, 1027604480, 65011712, 122683392, 805830656, 253493248, 997851136, 459997184, 797147136, 89112576, 436002816, 1034670080, 404994048, 981390336, 182738432, 853430528, 726938496, 470169536, 184609056, 276830192, 616616232, 480314356, 1068527402, 1071153917 + ], + [ + 536870912, 268435456, 939524096, 603979776, 1040187392, 486539264, 780140544, 859832320, 442499072, 670040064, 936902656, 298582016, 450232320, 728039424, 562200576, 522108928, 1027645440, 794865664, 359663616, 513385472, 682394112, 245845760, 24957312, 426670016, 945398496, 101578736, 687233928, 24485060, 309031278, 220860217 + ], + [ + 536870912, 805306368, 402653184, 469762048, 973078528, 822083584, 964689920, 792723456, 136314880, 420478976, 924319744, 108265472, 37093376, 106496000, 693469184, 833011712, 176283648, 197152768, 1021396992, 326183936, 631810560, 910018816, 50005120, 877380288, 302183072, 30316848, 660417032, 818612492, 381871238, 330273479 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 167772160, 419430400, 226492416, 79691776, 845152256, 504365056, 844627968, 49545216, 1036648448, 776929280, 340623360, 628047872, 352133120, 1061629952, 205543424, 555860992, 162650624, 799579392, 545087360, 638028864, 48331360, 827436912, 804871656, 100980532, 314811782, 826483019 + ], + [ + 536870912, 805306368, 671088640, 469762048, 234881024, 1023410176, 662700032, 876609536, 358612992, 812646400, 142082048, 392953856, 1057095680, 24444928, 111116288, 533610496, 514220032, 398700544, 383043584, 374303744, 669424128, 220360448, 249906560, 89636544, 1039916512, 500746576, 750632840, 699032012, 321933418, 228137879 + ], + [ + 536870912, 268435456, 939524096, 67108864, 771751936, 285212672, 696254464, 272629760, 685768704, 321912832, 167247872, 381943808, 236060672, 683868160, 428572672, 368459776, 926965760, 73404416, 1022367744, 609784832, 714356224, 362414336, 916394112, 36475712, 306079584, 66908400, 267788136, 541095156, 14692710, 791798261 + ], + [ + 536870912, 268435456, 134217728, 201326592, 369098752, 520093696, 109051904, 71303168, 1054867456, 309329920, 154664960, 866910208, 514457600, 601817088, 489259008, 799326208, 39723008, 199872512, 117753856, 734956544, 522286592, 542237952, 988404864, 176459328, 990856864, 545351472, 54643752, 1013046388, 204578314, 1054456071 + ], + [ + 536870912, 268435456, 939524096, 872415232, 369098752, 285212672, 562036736, 792723456, 1004535808, 28311552, 608698368, 995360768, 274071552, 418971648, 211582976, 994295808, 936288256, 219492352, 372754432, 738749440, 540338688, 656811776, 470886784, 463037504, 535574432, 296483888, 97198600, 507136772, 236176270, 1052132173 + ], + [ + 536870912, 805306368, 402653184, 738197504, 167772160, 83886080, 394264576, 826277888, 689963008, 97517568, 152567808, 675020800, 310509568, 235208704, 7307264, 522174464, 748150784, 529666048, 343738368, 673369088, 76894720, 56061184, 712155264, 349044672, 910819424, 455129424, 483398280, 211321548, 813541606, 639863451 + ], + [ + 536870912, 805306368, 671088640, 872415232, 369098752, 620756992, 645922816, 557842432, 593494016, 118489088, 639107072, 157548544, 869400576, 678625280, 348291072, 1047248896, 900096000, 968413184, 198506496, 142232576, 322897408, 480001280, 166131072, 274320704, 663077472, 167976688, 147530344, 731320060, 206649954, 846811889 + ], + [ + 536870912, 805306368, 134217728, 872415232, 503316480, 520093696, 813694976, 381681664, 224395264, 942669824, 493355008, 941359104, 529399808, 652935168, 922779648, 880918528, 12705792, 643911680, 380635136, 346651648, 100479488, 830397696, 920824448, 925739712, 912714656, 506977424, 250485544, 81413980, 594018314, 387710977 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 436207616, 989855744, 578813952, 801112064, 610271232, 9437184, 771227648, 675545088, 839778304, 193134592, 138510336, 606158848, 816848896, 55128064, 906823680, 126012416, 977365504, 455138560, 875620224, 227052352, 200080864, 173214288, 471455848, 395698196, 727154694, 62275595 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 167772160, 251658240, 612368384, 440401920, 480247808, 61865984, 208142336, 1054081024, 1001521152, 1056636928, 744390656, 417611776, 1744896, 1062105088, 87902208, 27675648, 346664448, 355803904, 723698304, 971188160, 486714976, 689063792, 877371496, 431363196, 737192686, 331890611 + ], + [ + 536870912, 268435456, 134217728, 872415232, 369098752, 16777216, 578813952, 197132288, 316669952, 879755264, 126353408, 575930368, 642908160, 890568704, 443711488, 788873216, 390799360, 750383104, 771565568, 135783424, 528414208, 240825088, 67122560, 234938176, 1023524640, 8421840, 482391432, 828415812, 489692962, 514339293 + ], + [ + 536870912, 268435456, 402653184, 738197504, 436207616, 754974720, 142606336, 876609536, 182452224, 479199232, 987234304, 749993984, 491388928, 887422976, 624066560, 203538432, 523362304, 1009258496, 314312704, 465998848, 881576448, 1053135616, 84084352, 562635200, 122466592, 776881296, 365399688, 1066104260, 423893798, 952240027 + ], + [ + 536870912, 268435456, 671088640, 738197504, 436207616, 16777216, 864026624, 574619648, 1059061760, 951058432, 314048512, 448004096, 960364544, 785317888, 987201536, 328384512, 414556160, 742289408, 55572480, 798467072, 70424064, 818208512, 275169920, 1009402688, 58841312, 440523280, 992059624, 246464020, 163092194, 674566431 + ], + [ + 536870912, 268435456, 402653184, 469762048, 905969664, 754974720, 662700032, 926941184, 803209216, 238026752, 771227648, 528744448, 54657024, 597229568, 66355200, 584761344, 795729920, 430911488, 443983872, 316824576, 533285376, 343717632, 700898688, 459009472, 556656416, 600819088, 604416520, 746227460, 868021638, 99054023 + ], + [ + 536870912, 805306368, 671088640, 738197504, 436207616, 620756992, 528482304, 46137344, 987758592, 986710016, 522715136, 504102912, 62259200, 401276928, 724860928, 24297472, 486612992, 729821184, 482392064, 702592000, 441465344, 661186816, 967638400, 21445056, 150134304, 281131856, 65051560, 391198364, 350814082, 560833735 + ], + [ + 536870912, 268435456, 402653184, 67108864, 637534208, 520093696, 964689920, 1044381696, 492830720, 860880896, 192413696, 44302336, 456523776, 88539136, 856653824, 167985152, 464084992, 446517248, 477308928, 836838400, 26310144, 886631680, 374697856, 12576832, 980076384, 135610832, 232722280, 289043924, 124531054, 695921877 + ], + [ + 536870912, 268435456, 134217728, 738197504, 33554432, 889192448, 226492416, 12582912, 538968064, 531628032, 83361792, 287047680, 838991872, 392888320, 843022336, 156876800, 510500864, 517681152, 902289408, 113529856, 976159232, 332483328, 2624128, 968106816, 251066016, 360465712, 450071720, 1036151348, 1003183146, 114251391 + ], + [ + 536870912, 268435456, 671088640, 201326592, 905969664, 654311424, 578813952, 440401920, 207618048, 493879296, 806879232, 719585280, 559808512, 557252608, 810254336, 3194880, 251240448, 97816576, 287762432, 547527680, 101547520, 694314240, 95189632, 682776640, 853865568, 358551824, 859267688, 759949332, 867198690, 288937303 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 973078528, 452984832, 377487360, 339738624, 513802240, 303038464, 880279552, 742129664, 679346176, 1030422528, 1030782976, 906608640, 850763776, 462041088, 868222976, 1063382016, 980440576, 713668352, 905295232, 799796032, 261191200, 247005200, 316415400, 584020060, 973285386, 682957827 + ], + [ + 536870912, 805306368, 402653184, 738197504, 503316480, 855638016, 612368384, 566231040, 1025507328, 80740352, 265814016, 714342400, 1032454144, 506134528, 305823744, 490881024, 927408128, 276156416, 729499648, 933424128, 162963968, 234679040, 49700224, 169724736, 730227680, 315917744, 518734824, 379213244, 936545262, 754907575 + ], + [ + 536870912, 805306368, 939524096, 738197504, 167772160, 855638016, 1031798784, 180355072, 761266176, 1047527424, 282591232, 1048313856, 222691328, 875888640, 22249472, 1001832448, 447602688, 772673536, 1050687488, 764500992, 568876544, 621051648, 707402112, 618341312, 641861472, 52300144, 889823112, 1068830924, 982776046, 207014331 + ], + [ + 536870912, 805306368, 939524096, 201326592, 369098752, 452984832, 914358272, 490733568, 954204160, 133169152, 285736960, 789839872, 183369728, 979173376, 446398464, 696434688, 904847360, 517861376, 1054537728, 652452864, 350118400, 133520128, 85956992, 525599040, 797958688, 778845104, 573733768, 797416012, 855153582, 740084467 + ], + [ + 536870912, 805306368, 939524096, 603979776, 570425344, 117440512, 662700032, 432013312, 891289600, 355467264, 361234432, 709623808, 1036386304, 567214080, 457342976, 220545024, 110845952, 640741376, 403277824, 680383488, 694610432, 138300160, 460027520, 203018432, 37026208, 228739344, 1043600296, 1000538652, 590734630, 1059295957 + ], + [ + 536870912, 805306368, 671088640, 67108864, 838860800, 318767104, 763363328, 532676608, 664797184, 735051776, 973602816, 217317376, 265945088, 423034880, 766541824, 595116032, 967663616, 476557312, 1039665152, 1005351936, 201773568, 898163456, 406090624, 704337600, 455605216, 286914416, 987615848, 1044313788, 835053570, 333644813 + ], + [ + 536870912, 805306368, 134217728, 872415232, 167772160, 251658240, 813694976, 230686720, 652214272, 735051776, 486014976, 838074368, 7733248, 699203584, 972259328, 164839424, 241377280, 864718848, 1021777920, 561296384, 1035347456, 122452736, 639810688, 522932928, 815223840, 58587120, 411712136, 1047001548, 531910818, 366395709 + ], + [ + 536870912, 268435456, 402653184, 872415232, 771751936, 117440512, 176160768, 826277888, 337641472, 776994816, 678952960, 551813120, 158728192, 764870656, 640122880, 879706112, 1057153024, 91852800, 191145984, 431389696, 410400256, 68663040, 736589184, 571452992, 569609568, 890270928, 492367208, 792044756, 13575534, 17959129 + ], + [ + 536870912, 805306368, 939524096, 201326592, 167772160, 822083584, 914358272, 339738624, 819986432, 787480576, 716701696, 434372608, 1011744768, 923729920, 242122752, 224346112, 46604288, 485715968, 131397632, 1062620160, 880438784, 522823936, 90996352, 582130496, 909462624, 522613264, 109300840, 1009594908, 651357286, 159728159 + ], + [ + 536870912, 805306368, 939524096, 872415232, 637534208, 251658240, 176160768, 734003200, 1021313024, 428867584, 571998208, 131334144, 257032192, 359596032, 94404608, 179322880, 426270720, 123506688, 102713344, 958999552, 704416256, 674199808, 142707584, 180448320, 895522400, 718385200, 473481192, 656742780, 362471430, 662949889 + ], + [ + 536870912, 268435456, 402653184, 738197504, 1040187392, 989855744, 864026624, 977272832, 857735168, 149946368, 887619584, 936116224, 438173696, 526450688, 617644032, 93896704, 275079168, 678686720, 1062131712, 901258240, 387289600, 14301440, 748935040, 718671680, 1037875808, 325566192, 26599432, 572207108, 239319046, 122153995 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 503316480, 1023410176, 847249408, 499122176, 908066816, 890241024, 706215936, 512491520, 62783488, 128122880, 289767424, 998916096, 373301248, 727814144, 636606464, 447323136, 818252288, 566933248, 723553664, 395351616, 802739616, 346857744, 682590248, 280669012, 1028218766, 636878155 + ], + [ + 536870912, 805306368, 402653184, 67108864, 973078528, 419430400, 8388608, 473956352, 367001600, 544210944, 662175744, 274989056, 917897216, 329449472, 351043584, 879443968, 609345536, 472412160, 466475008, 180022272, 221787648, 176489728, 692545664, 253491776, 782780384, 848149776, 970651496, 369666908, 463242894, 479400781 + ], + [ + 536870912, 268435456, 939524096, 67108864, 301989888, 855638016, 880803840, 608174080, 14680064, 141557760, 153616384, 512491520, 993656832, 914292736, 79265792, 441794560, 929030144, 132755456, 925730816, 439090176, 48735744, 574371072, 347249792, 727928512, 240824096, 231629488, 632321448, 738765172, 534629894, 490895621 + ], + [ + 536870912, 268435456, 939524096, 67108864, 905969664, 654311424, 478150656, 490733568, 1038090240, 95420416, 682098688, 373555200, 278790144, 193265664, 306085888, 450150400, 10919936, 335114240, 31299584, 741512192, 675213824, 668285696, 824622976, 121155136, 754804128, 849569456, 956710792, 1009348164, 654656942, 662623921 + ], + [ + 536870912, 268435456, 671088640, 738197504, 973078528, 620756992, 528482304, 364904448, 111149056, 793772032, 122159104, 41680896, 447610880, 125108224, 934445056, 640303104, 299819008, 825036800, 535267328, 604507136, 614315520, 731869440, 441213056, 840371520, 437295712, 1051245744, 164451976, 232209476, 296786666, 578347515 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 33554432, 218103808, 964689920, 406847488, 664797184, 550502400, 133693440, 354680832, 673841152, 692387840, 505053184, 642596864, 123166720, 228282368, 520882176, 326573056, 67766784, 81035520, 868449408, 905447104, 2478496, 631945616, 251960456, 918230724, 840710562, 560969119 + ], + [ + 536870912, 805306368, 671088640, 603979776, 1040187392, 822083584, 897581056, 960495616, 648019968, 984612864, 479723520, 152829952, 660209664, 557252608, 613711872, 1072611328, 698966016, 331698176, 610744320, 337380352, 953816576, 1064777472, 582282368, 933219136, 466710816, 860380080, 475276712, 101602556, 146317954, 443394117 + ], + [ + 536870912, 805306368, 939524096, 335544320, 1040187392, 184549376, 931135488, 557842432, 731906048, 330301440, 295174144, 413401088, 334364672, 254738432, 13533184, 1012875264, 1018683392, 23728128, 959465472, 274265088, 935624192, 733930240, 606592640, 126034496, 468483936, 562232336, 887947112, 268614684, 179150694, 841215001 + ], + [ + 536870912, 805306368, 671088640, 469762048, 33554432, 922746880, 796917760, 507510784, 224395264, 714080256, 176685056, 1026293760, 644743168, 30998528, 1015382016, 145965056, 430956544, 1073254400, 938833920, 124443648, 137036288, 466305792, 26890368, 515045952, 11419744, 226002160, 758512136, 969662220, 110834314, 422734151 + ], + [ + 536870912, 805306368, 402653184, 469762048, 503316480, 922746880, 847249408, 62914560, 878706688, 546308096, 879230976, 732168192, 351928320, 429850624, 176455680, 835403776, 134684672, 744001536, 364644352, 778439680, 231250432, 542471424, 914508672, 127061440, 683357024, 431924592, 506853608, 185804988, 746318734, 123608523 + ], + [ + 536870912, 268435456, 134217728, 201326592, 33554432, 150994944, 411041792, 717225984, 799014912, 598736896, 1063780352, 194248704, 497156096, 240844800, 668434432, 657047552, 469016576, 53620736, 1027815424, 638262272, 829299200, 4542208, 677086848, 819389376, 1017759328, 750010608, 483542120, 311632884, 234053866, 216159031 + ], + [ + 536870912, 268435456, 671088640, 335544320, 838860800, 83886080, 629145600, 482344960, 404750336, 674234368, 1019740160, 669777920, 539623424, 272171008, 788824064, 569851904, 802922496, 173019136, 312076288, 1064619008, 643814912, 904296704, 824427904, 678751296, 383678560, 614986192, 566410760, 711324932, 120042378, 436372805 + ], + [ + 536870912, 805306368, 671088640, 469762048, 704643072, 16777216, 545259520, 650117120, 1012924416, 860880896, 277348352, 304873472, 914751488, 304807936, 426541056, 1051115520, 249208832, 274018304, 43227136, 655993856, 331612672, 897240320, 266638720, 797703360, 98338848, 775895248, 6167976, 907002908, 403051906, 468335819 + ], + [ + 536870912, 268435456, 402653184, 335544320, 369098752, 218103808, 58720256, 952107008, 383778816, 852492288, 868745216, 483655680, 854458368, 666828800, 850886656, 964902912, 943579136, 260722688, 965326848, 997516288, 958382592, 1019651328, 255576960, 80761280, 784901472, 122973968, 506404200, 660572948, 224878446, 164261393 + ], + [ + 536870912, 805306368, 134217728, 872415232, 771751936, 822083584, 1031798784, 893386752, 836763648, 879755264, 250085376, 237240320, 284033024, 356974592, 595755008, 110936064, 846356480, 825593856, 532076544, 1051350016, 647556608, 718108928, 164359808, 1026058176, 268793824, 280963600, 218044904, 211718940, 531535722, 195519697 + ], + [ + 536870912, 268435456, 939524096, 469762048, 167772160, 251658240, 796917760, 851443712, 991952896, 844103680, 699924480, 758382592, 367132672, 728694784, 884572160, 28655616, 983769088, 831500288, 407480320, 664552448, 714066432, 164232960, 878502784, 657333056, 601435744, 881154480, 506071016, 607305204, 303548934, 162397955 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 369098752, 989855744, 25165824, 926941184, 685768704, 596639744, 792199168, 614203392, 720502784, 493027328, 274366464, 499597312, 666148864, 555159552, 342640640, 874185728, 10886656, 560220416, 936320384, 1071669312, 1007737504, 662242352, 670864040, 320995388, 540708006, 563497267 + ], + [ + 536870912, 268435456, 671088640, 872415232, 33554432, 385875968, 293601280, 574619648, 417333248, 988807168, 522715136, 781451264, 325976064, 697106432, 619872256, 245776384, 652746752, 657838080, 184440832, 219429888, 506411520, 1022145280, 172190080, 477068352, 873266208, 414378416, 927370120, 412660548, 484183978, 256620285 + ], + [ + 536870912, 268435456, 939524096, 738197504, 973078528, 184549376, 880803840, 96468992, 513802240, 439353344, 885522432, 870055936, 81133568, 198115328, 9142272, 978862080, 1042554880, 591622144, 788916224, 540191744, 346886656, 25075456, 260250240, 841300672, 155442464, 470140944, 951224104, 728615700, 350144422, 557052639 + ], + [ + 536870912, 268435456, 134217728, 872415232, 301989888, 50331648, 1065353216, 423624704, 81788928, 923795456, 84410368, 478937088, 97386496, 1008795648, 397443072, 611860480, 760586240, 795512832, 861083648, 1046903808, 1021118976, 824657664, 826132608, 112689216, 888459360, 379199600, 1045110792, 1046728708, 769538050, 816360461 + ], + [ + 536870912, 268435456, 402653184, 872415232, 771751936, 956301312, 343932928, 1002438656, 975175680, 271581184, 1010302976, 494141440, 180224000, 226689024, 588349440, 814235648, 915234816, 938135552, 899072, 1059843072, 564967936, 224079616, 653648000, 956270656, 786636384, 1069582416, 471891176, 87065364, 850974734, 833960969 + ], + [ + 536870912, 268435456, 671088640, 335544320, 33554432, 520093696, 494927872, 171966464, 1050673152, 258998272, 150470656, 1002176512, 226361344, 712704000, 991526912, 1005436928, 1052237824, 782217216, 36399104, 483447808, 1024056832, 411326208, 337888896, 198522944, 342580256, 611368208, 125355176, 117183060, 979353090, 759834369 + ], + [ + 536870912, 268435456, 671088640, 872415232, 771751936, 956301312, 8388608, 1010827264, 157286400, 267386880, 742916096, 486801408, 767688704, 305987584, 47087616, 546979840, 289415168, 937472000, 582035456, 296276992, 11885056, 837519104, 4757888, 1057246016, 650353824, 834458576, 688843656, 742004804, 722525994, 561602461 + ], + [ + 536870912, 805306368, 671088640, 603979776, 301989888, 587202560, 897581056, 423624704, 970981376, 877658112, 966262784, 914620416, 282460160, 623968256, 67731456, 54345728, 2301952, 1057984512, 433428480, 550464512, 351644160, 943718144, 383543936, 846452928, 529924640, 500251568, 249083912, 845544460, 67613194, 23646985 + ], + [ + 536870912, 268435456, 402653184, 603979776, 33554432, 1056964608, 847249408, 473956352, 723517440, 74448896, 471334912, 690749440, 541982720, 455409664, 665485312, 1022345216, 982818816, 609374208, 1037244416, 420684800, 762464768, 379802880, 797648256, 1008653248, 533475296, 266223408, 892098440, 374289092, 1042610278, 237751801 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 570425344, 184549376, 1031798784, 910163968, 169869312, 546308096, 914882560, 114032640, 20054016, 33882112, 601849856, 312983552, 500391936, 511004672, 958855168, 378723328, 617978368, 125285632, 150676096, 141151040, 297589216, 642415696, 812726408, 284802636, 724867942, 445048607 + ], + [ + 536870912, 268435456, 671088640, 469762048, 973078528, 620756992, 109051904, 205520896, 656408576, 198180864, 728236032, 772538368, 296615936, 400883712, 98729984, 376061952, 643260416, 136384512, 273680384, 363348992, 594311680, 576713984, 349970560, 172405824, 44578272, 216846768, 983456392, 113000772, 439784810, 189801975 + ], + [ + 536870912, 805306368, 671088640, 67108864, 570425344, 251658240, 394264576, 4194304, 48234496, 540016640, 1043857408, 282853376, 408027136, 74514432, 786006016, 401424384, 904536064, 921440256, 996931584, 606927872, 625713664, 859653888, 920836480, 680009152, 539319520, 414071184, 573732872, 58833932, 977371658, 568416001 + ], + [ + 536870912, 805306368, 939524096, 335544320, 234881024, 956301312, 612368384, 79691776, 291504128, 303038464, 641204224, 564920320, 702676992, 750321664, 745373696, 604225536, 778674176, 355856384, 784205824, 87196672, 484496896, 978387712, 530109568, 954058688, 717897312, 917255056, 73586184, 888668940, 768431246, 695338949 + ], + [ + 536870912, 805306368, 671088640, 335544320, 436207616, 50331648, 679477248, 918552576, 929038336, 1041235968, 900202496, 951320576, 270925824, 708902912, 732004352, 577847296, 926457856, 568119296, 485627904, 754336768, 42546688, 101022464, 998117504, 151838016, 775589280, 39034160, 856129544, 250626060, 66658314, 700289029 + ], + [ + 536870912, 268435456, 939524096, 201326592, 503316480, 889192448, 679477248, 708837376, 656408576, 133169152, 574095360, 176422912, 724959232, 16318464, 400850944, 870825984, 691101696, 559443968, 659843072, 712975360, 470065664, 611717376, 928627584, 911516608, 687758624, 289779248, 14033416, 124309764, 831282062, 686494659 + ], + [ + 536870912, 805306368, 939524096, 603979776, 436207616, 150994944, 360710144, 926941184, 241172480, 808452096, 724041728, 1035730944, 1039532032, 273350656, 633110528, 704004096, 843833344, 146632704, 645322752, 202048512, 324822528, 554111232, 692254336, 516996800, 937010592, 79033552, 110842664, 241519132, 323155590, 667991749 + ], + [ + 536870912, 268435456, 671088640, 603979776, 973078528, 956301312, 696254464, 289406976, 333447168, 363855872, 188219392, 529793024, 648937472, 1051656192, 581926912, 346996736, 867164160, 422457344, 418379776, 869184512, 618544640, 699834624, 682232960, 447239488, 490580448, 663886992, 792570344, 714218644, 347974114, 651304093 + ], + [ + 536870912, 805306368, 939524096, 872415232, 301989888, 318767104, 58720256, 968884224, 715128832, 619708416, 585629696, 776208384, 998113280, 792395776, 994344960, 167657472, 1048272896, 530952192, 745424896, 29615104, 880304640, 578605824, 291673728, 1065996992, 487945824, 870817616, 752345320, 1067339164, 984258182, 1023267521 + ], + [ + 536870912, 805306368, 939524096, 67108864, 301989888, 553648128, 427819008, 935329792, 966787072, 19922944, 896008192, 400818176, 428474368, 660537344, 129794048, 419840000, 808509440, 619261952, 472143872, 908846080, 359588352, 173406976, 547571840, 668662976, 992405856, 801153776, 228719080, 724679228, 275378822, 476373965 + ], + [ + 536870912, 268435456, 134217728, 738197504, 33554432, 50331648, 360710144, 398458880, 35651584, 221249536, 983040000, 557056000, 915537920, 687931392, 713064448, 138428416, 987848704, 412094464, 594024448, 202157056, 223788544, 657133824, 797305216, 785061056, 982854048, 1046627472, 448266248, 1057226756, 294256642, 871694347 + ], + [ + 536870912, 268435456, 134217728, 469762048, 1040187392, 1056964608, 494927872, 524288000, 828375040, 468713472, 378011648, 430178304, 524156928, 322240512, 38174720, 337199104, 417095680, 638824448, 917379072, 768384000, 623624704, 576898816, 778483072, 797505344, 1059399328, 939461552, 538234248, 878172996, 614530210, 609308855 + ], + [ + 536870912, 805306368, 402653184, 738197504, 503316480, 16777216, 998244352, 247463936, 941621248, 277872640, 819462144, 1029439488, 841613312, 1037631488, 685604864, 636141568, 309878784, 680357888, 739428352, 70630400, 616498688, 347474176, 240302208, 206913728, 323879904, 824089040, 266798600, 388630796, 475576454, 219955403 + ], + [ + 536870912, 268435456, 671088640, 603979776, 100663296, 956301312, 864026624, 356515840, 195035136, 426770432, 159907840, 284426240, 932839424, 103350272, 528777216, 789790720, 22814720, 996061184, 463177728, 875117568, 142957056, 26473728, 563955584, 482319936, 986369696, 831578448, 442071560, 1066222852, 430362506, 367436361 + ], + [ + 536870912, 268435456, 134217728, 67108864, 301989888, 989855744, 1015021568, 272629760, 350224384, 831520768, 953679872, 705429504, 126746624, 777584640, 491552768, 837697536, 579411968, 619974656, 1035180032, 637453312, 361861632, 987348736, 420219008, 1058010304, 739884896, 850201840, 1023382024, 168869636, 437815426, 195933377 + ], + [ + 536870912, 805306368, 939524096, 335544320, 234881024, 956301312, 746586112, 750780416, 408944640, 368050176, 584581120, 523501568, 1015939072, 780861440, 381452288, 871514112, 60317696, 588599296, 736000000, 750980096, 471921152, 659565824, 977823872, 513544000, 446862432, 13639248, 285738216, 498949404, 879886982, 416824905 + ], + [ + 536870912, 268435456, 134217728, 335544320, 100663296, 318767104, 864026624, 398458880, 794820608, 619708416, 714604544, 859045888, 980549632, 281608192, 289177600, 1018052608, 819437568, 567521280, 819550208, 345373696, 409103872, 140538624, 24155008, 643346112, 1003839648, 256049424, 103814664, 897089284, 998507906, 1011519941 + ], + [ + 536870912, 268435456, 134217728, 67108864, 704643072, 989855744, 629145600, 1061158912, 643825664, 179306496, 851968000, 710672384, 1007026176, 439418880, 688422912, 637288448, 236331008, 292048896, 642603008, 778005504, 267704832, 308994816, 104779136, 71637568, 908277984, 849505072, 191059976, 1002597380, 106060290, 155951873 + ], + [ + 536870912, 805306368, 134217728, 201326592, 369098752, 1023410176, 109051904, 926941184, 119537664, 321912832, 530055168, 131334144, 568983552, 66387968, 895188992, 866992128, 871358464, 383250432, 921896960, 979387392, 118616576, 858299648, 864820096, 1029679552, 227524896, 197575824, 786168712, 845961676, 193906978, 247955603 + ], + [ + 536870912, 268435456, 939524096, 738197504, 167772160, 1056964608, 696254464, 901775360, 10485760, 821035008, 38273024, 446955520, 843186176, 234160128, 360349696, 316194816, 775806976, 1042255872, 1044092928, 171482112, 900535808, 352839936, 178657664, 64372544, 207595168, 978993744, 854090120, 39138116, 604711086, 827340635 + ], + [ + 536870912, 805306368, 671088640, 335544320, 301989888, 486539264, 176160768, 834666496, 933232640, 921698304, 129499136, 296484864, 1056833536, 280297472, 220430336, 724713472, 706355200, 442454016, 130385920, 383427584, 1065293312, 1022734592, 549639552, 388125376, 305393120, 446428848, 580903816, 686076876, 216707178, 98959477 + ], + [ + 536870912, 268435456, 134217728, 738197504, 503316480, 50331648, 780140544, 859832320, 736100352, 554696704, 539492352, 1038876672, 719192064, 469434368, 559513600, 370458624, 993730560, 75010048, 153380864, 245574656, 223120896, 472823040, 214110080, 329096640, 833045536, 979361424, 1002169768, 741893716, 675661322, 787613967 + ], + [ + 536870912, 268435456, 939524096, 335544320, 234881024, 218103808, 377487360, 88080384, 845152256, 223346688, 936902656, 923533312, 114163712, 786366464, 996638720, 960118784, 472702976, 201297920, 995522560, 976456704, 406373888, 412910848, 850818944, 883152192, 549507872, 77720656, 15805224, 396894292, 1021644070, 281752913 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 503316480, 1023410176, 494927872, 390070272, 1029701632, 319815680, 1010302976, 144441344, 232390656, 327221248, 843153408, 887177216, 642899968, 576253952, 990767104, 992144384, 826128896, 300575488, 138991744, 548766144, 335541472, 50816720, 951713800, 210829324, 947486730, 1031618575 + ], + [ + 536870912, 268435456, 939524096, 67108864, 704643072, 385875968, 562036736, 448790528, 866123776, 265289728, 699924480, 988020736, 523632640, 332595200, 635797504, 313999360, 521330688, 793047040, 31893504, 451630080, 490809856, 945939200, 485603200, 606705984, 649869792, 904100112, 577605224, 64675924, 122271622, 500013381 + ], + [ + 536870912, 268435456, 671088640, 469762048, 503316480, 1056964608, 947912704, 985661440, 1012924416, 357564416, 952631296, 69468160, 280625152, 834469888, 139886592, 253902848, 340877312, 793325568, 778328064, 169595904, 109960704, 449797888, 189724800, 974033728, 841963680, 48115984, 900169352, 433723460, 829193770, 1004535127 + ], + [ + 536870912, 805306368, 671088640, 335544320, 771751936, 117440512, 931135488, 801112064, 975175680, 869269504, 1004011520, 1059323904, 1049755648, 250413056, 189759488, 420102144, 304619520, 120434688, 309319680, 458976256, 355513856, 464033024, 938261632, 600744384, 1028390560, 1036562640, 668750472, 719788236, 132633642, 23540757 + ], + [ + 536870912, 805306368, 402653184, 738197504, 100663296, 352321536, 444596224, 994050048, 618659840, 147849216, 533200896, 584843264, 174718976, 686227456, 151289856, 912211968, 622895104, 661704704, 737695744, 432348160, 830422528, 357651712, 822621568, 754819776, 1050390432, 1021195056, 912376360, 932285948, 153736078, 353217479 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 704643072, 486539264, 411041792, 549453824, 102760448, 506462208, 309854208, 412876800, 545652736, 467206144, 871137280, 882884608, 127197184, 855887872, 647112704, 110797824, 77469184, 798324992, 922994048, 814943680, 832301536, 18862000, 399832584, 300132612, 679701902, 1037265359 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 503316480, 654311424, 629145600, 759169024, 513802240, 638582784, 390594560, 434896896, 862846976, 787546112, 75005952, 720650240, 988536832, 287567872, 923711488, 436268032, 486558208, 679585024, 230758528, 794844736, 393326944, 658057328, 458610696, 91970564, 892015106, 390314255 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 704643072, 16777216, 746586112, 801112064, 195035136, 66060288, 680001536, 312213504, 11665408, 865140736, 114917376, 451166208, 724033536, 150884352, 278562816, 192783360, 866344448, 143240448, 580724608, 145963072, 261121760, 752390800, 467986440, 128431116, 658388482, 456808719 + ], + [ + 536870912, 268435456, 939524096, 335544320, 704643072, 956301312, 427819008, 331350016, 52428800, 420478976, 279445504, 171704320, 516292608, 806682624, 934969344, 531808256, 442441728, 143724544, 1063790592, 253557760, 14067200, 708660480, 247976576, 135532096, 599408224, 900936432, 593458312, 286278468, 749300974, 205323445 + ], + [ + 536870912, 268435456, 402653184, 469762048, 771751936, 16777216, 75497472, 683671552, 65011712, 483393536, 870842368, 18087936, 562954240, 535363584, 655654912, 613335040, 694804480, 550891520, 586074112, 435799040, 941405696, 1019926272, 391062144, 352856384, 994336672, 229109488, 77379080, 403363588, 581902982, 349710663 + ], + [ + 536870912, 805306368, 134217728, 603979776, 167772160, 83886080, 813694976, 188743680, 375390208, 475004928, 656932864, 202113024, 6422528, 592117760, 356941824, 405061632, 804184064, 1005072384, 816633856, 865319936, 605279744, 248757504, 561177472, 16977088, 379212192, 799961392, 571049896, 440257596, 488334378, 594460917 + ], + [ + 536870912, 268435456, 939524096, 67108864, 637534208, 218103808, 696254464, 205520896, 954204160, 1043333120, 728236032, 324796416, 413794304, 60358656, 1007976448, 921157632, 868950016, 250130432, 354232320, 927640576, 992506368, 431759104, 899356032, 141645120, 747147232, 401431504, 520346120, 736391940, 590268302, 826751553 + ], + [ + 536870912, 268435456, 402653184, 469762048, 905969664, 1023410176, 713031680, 88080384, 6291456, 110100480, 120061952, 711196672, 33685504, 156565504, 496664576, 761905152, 126115840, 944992256, 14419968, 684614656, 384958976, 267138816, 156757632, 198111808, 359850912, 304946000, 460785288, 750724676, 101321126, 281147479 + ], + [ + 536870912, 268435456, 671088640, 201326592, 973078528, 855638016, 545259520, 784334848, 375390208, 263192576, 558366720, 419168256, 187301888, 729088000, 129400832, 955138048, 453763072, 6623232, 758003712, 837481472, 857005568, 621166336, 1009235840, 79166272, 544208736, 298557840, 537258376, 731874372, 52666602, 631851731 + ], + [ + 536870912, 805306368, 134217728, 738197504, 637534208, 922746880, 125829120, 322961408, 1067450368, 959447040, 474480640, 163315712, 982646784, 626720768, 94797824, 429178880, 427728896, 844173312, 966289408, 459600896, 978746880, 742222592, 617780864, 75213504, 861281312, 146634288, 840065576, 362487100, 591819946, 235173879 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 637534208, 50331648, 260046848, 62914560, 249561088, 883949568, 1066926080, 833880064, 257556480, 1032650752, 33456128, 375341056, 994992128, 113700864, 729430016, 895314944, 831919616, 13861632, 422612864, 1029177792, 567641376, 782952080, 632584584, 89862852, 277729954, 830421855 + ], + [ + 536870912, 805306368, 134217728, 603979776, 503316480, 1056964608, 1015021568, 1010827264, 673185792, 441450496, 893911040, 120324096, 931004416, 869597184, 1034649600, 301940736, 513122304, 504049664, 795842560, 566014976, 341256704, 193543424, 474776704, 831406400, 76388064, 972010800, 83629704, 334936140, 723091554, 476384633 + ], + [ + 536870912, 268435456, 134217728, 603979776, 33554432, 1056964608, 830472192, 104857600, 383778816, 477102080, 696778752, 821297152, 604897280, 321323008, 541294592, 892715008, 330293248, 70676480, 905660416, 128558080, 363177472, 760641792, 650882688, 1010891968, 367046240, 66159248, 919169128, 714361748, 817786602, 462381917 + ], + [ + 536870912, 805306368, 134217728, 603979776, 436207616, 117440512, 813694976, 943718400, 639631360, 776994816, 943194112, 330039296, 109707264, 105185280, 132087808, 637747200, 31563776, 347148288, 436819968, 14971904, 701442560, 337349888, 35501184, 922940096, 945864416, 158398224, 401196680, 441715660, 650616930, 125815001 + ], + [ + 536870912, 805306368, 402653184, 603979776, 905969664, 889192448, 528482304, 910163968, 652214272, 508559360, 79167488, 648806400, 895090688, 219348992, 615940096, 522731520, 146038784, 340152320, 438319104, 561079296, 306718208, 1051023616, 1059047296, 794642496, 634560032, 899074160, 416833576, 960292220, 490985902, 17809461 + ], + [ + 536870912, 268435456, 671088640, 201326592, 33554432, 50331648, 696254464, 390070272, 543162368, 1039138816, 1023934464, 900464640, 174981120, 343474176, 258244608, 107167744, 860315648, 767922176, 917755904, 887057408, 1058097664, 574147328, 361077632, 760376896, 896474208, 133721072, 1059361288, 25339652, 418795914, 439149891 + ], + [ + 536870912, 268435456, 402653184, 872415232, 1040187392, 553648128, 1031798784, 876609536, 551550976, 544210944, 164102144, 732692480, 572653568, 332070912, 959938560, 168640512, 825483264, 926126080, 842192896, 699552768, 150185472, 731011328, 514047616, 168541888, 899040928, 1050497840, 646676648, 878107188, 104629806, 739959033 + ], + [ + 536870912, 268435456, 134217728, 738197504, 973078528, 452984832, 192937984, 20971520, 811597824, 873463808, 607649792, 848560128, 357433344, 686751744, 73367552, 441958400, 353017856, 45707264, 156542976, 1022260224, 174013952, 525819136, 327904640, 695858240, 687140064, 845026448, 727174376, 227255444, 611861738, 41181343 + ], + [ + 536870912, 805306368, 939524096, 872415232, 33554432, 318767104, 813694976, 213909504, 488636416, 384827392, 145227776, 356777984, 101580800, 144637952, 413564928, 1021001728, 86564864, 1007022080, 242149376, 403680256, 631237120, 891736832, 630938752, 893947328, 412473824, 827786384, 49500648, 900536476, 816460774, 776066961 + ], + [ + 536870912, 805306368, 939524096, 738197504, 973078528, 117440512, 931135488, 583008256, 488636416, 999292928, 847773696, 854327296, 387055616, 990838784, 577011712, 1056849920, 429760512, 279654400, 205203456, 959603712, 287193600, 925755136, 229800320, 442439360, 567107104, 226750832, 990326696, 784921532, 462177158, 568521159 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 704643072, 587202560, 981467136, 507510784, 723517440, 571473920, 537395200, 255590400, 98959360, 234553344, 135036928, 50216960, 693051392, 957755392, 788727808, 415788032, 543020544, 400016128, 157496704, 326762176, 286368, 969087312, 44583720, 32298908, 344923526, 502768323 + ], + [ + 536870912, 268435456, 402653184, 201326592, 838860800, 922746880, 729808896, 457179136, 903872512, 514850816, 484966400, 820248576, 133562368, 69140480, 461078528, 567099392, 422715392, 846737408, 144492544, 611038208, 569728512, 449788160, 392427648, 1017184704, 206610400, 836364496, 994951656, 821219796, 710424942, 671928343 + ], + [ + 536870912, 805306368, 402653184, 67108864, 436207616, 452984832, 142606336, 213909504, 492830720, 907018240, 289931264, 138674176, 178126848, 122224640, 625311744, 522108928, 101261312, 1030049792, 724441088, 946955264, 64566784, 332198656, 448517248, 843529280, 738521376, 725540976, 876164616, 102560524, 471061638, 533937217 + ], + [ + 536870912, 805306368, 402653184, 469762048, 905969664, 754974720, 595591168, 683671552, 509607936, 309329920, 640155648, 954990592, 249167872, 1047461888, 678461440, 355024896, 845946880, 798707712, 332388352, 719385600, 707860992, 436835584, 364720256, 388201152, 574325280, 559901616, 234385576, 508915836, 372234254, 1011938315 + ], + [ + 536870912, 805306368, 402653184, 335544320, 100663296, 117440512, 830472192, 851443712, 480247808, 386924544, 997720064, 299630592, 1064173568, 571408384, 775847936, 798375936, 1007869952, 829476864, 214558720, 934667264, 13283840, 1010693888, 924843904, 1011244096, 80395936, 305955792, 1008656040, 533074908, 923522734, 941369305 + ], + [ + 536870912, 805306368, 134217728, 67108864, 301989888, 788529152, 360710144, 784334848, 748683264, 508559360, 395837440, 594804736, 855244800, 297336832, 1046839296, 721567744, 373104640, 945229824, 886454272, 43387904, 846669312, 1070005504, 644755072, 259179200, 45472416, 1004189520, 690488840, 22867212, 69703298, 476024513 + ], + [ + 536870912, 805306368, 402653184, 335544320, 436207616, 184549376, 1031798784, 4194304, 10485760, 412090368, 619184128, 436469760, 566099968, 718077952, 837517312, 284934144, 106045440, 469143552, 291026944, 238869504, 334686720, 132563200, 259072640, 660198464, 993894304, 661821744, 623372424, 672171340, 875136294, 979718517 + ], + [ + 536870912, 805306368, 939524096, 872415232, 100663296, 721420288, 125829120, 507510784, 249561088, 909115392, 552075264, 271319040, 779485184, 834469888, 869236736, 1007206400, 991698944, 438300672, 206698496, 186223616, 509897216, 428600064, 143815552, 133605440, 956058848, 816801520, 225979272, 1066669132, 247725806, 368046589 + ], + [ + 536870912, 805306368, 134217728, 335544320, 1040187392, 150994944, 662700032, 549453824, 207618048, 321912832, 696778752, 1057226752, 739901440, 654901248, 138772480, 146423808, 744071168, 217870336, 389416960, 415669248, 657356288, 874179328, 185189760, 709155392, 733659936, 1020845392, 45905416, 471329548, 659965314, 301439557 + ], + [ + 536870912, 268435456, 134217728, 335544320, 838860800, 754974720, 411041792, 180355072, 601882624, 389021696, 876085248, 311689216, 716046336, 488701952, 382763008, 101203968, 707567616, 16486400, 963536896, 71386112, 773887488, 491912960, 390695296, 277699008, 963328160, 113690480, 75243528, 473157636, 950192130, 126538757 + ], + [ + 536870912, 805306368, 671088640, 738197504, 704643072, 83886080, 947912704, 104857600, 408944640, 653262848, 92798976, 395051008, 420347904, 1055457280, 385712128, 256327680, 600072192, 488820736, 263612416, 961291264, 523215360, 75090688, 864371584, 843195968, 281539424, 67492336, 964936200, 510073612, 282405770, 681247307 + ], + [ + 536870912, 268435456, 939524096, 201326592, 973078528, 989855744, 192937984, 20971520, 668991488, 382730240, 29884416, 384565248, 789446656, 670629888, 544505856, 980140032, 1048272896, 85086208, 550475776, 802716672, 780466688, 223516416, 330269312, 1036636224, 82658912, 537855984, 444072456, 540326660, 755687566, 577387331 + ], + [ + 536870912, 268435456, 134217728, 738197504, 637534208, 218103808, 981467136, 633339904, 299892736, 296747008, 565706752, 23855104, 825622528, 590020608, 600145920, 175292416, 462954496, 809291776, 364845056, 121625600, 519981568, 555616512, 296711808, 748109376, 87716256, 527246160, 137862952, 464191764, 17138826, 169081679 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 771751936, 83886080, 58720256, 532676608, 568328192, 663748608, 58195968, 211025920, 154533888, 8978432, 113016832, 783990784, 712695808, 85651456, 449538048, 898808832, 343354880, 1059649280, 739104896, 288522688, 809906592, 954220592, 437298696, 28949252, 318054022, 526781135 + ], + [ + 536870912, 805306368, 134217728, 201326592, 234881024, 83886080, 494927872, 155189248, 970981376, 152043520, 887619584, 906231808, 506331136, 20119552, 895516672, 668057600, 189276160, 477368320, 1008097280, 738182144, 964306432, 898974976, 218507136, 454475712, 226406240, 549139792, 347395816, 985078684, 437133322, 453185551 + ], + [ + 536870912, 805306368, 939524096, 469762048, 301989888, 754974720, 679477248, 524288000, 966787072, 584056832, 573046784, 882114560, 934936576, 104136704, 384532480, 148684800, 253714432, 752242688, 716376064, 3183616, 123286016, 862796032, 948368512, 551247936, 746906656, 737320848, 244421768, 67711052, 679865390, 368249751 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 905969664, 83886080, 813694976, 817889280, 866123776, 217055232, 311951360, 125566976, 843972608, 897122304, 183271424, 143048704, 334290944, 503787520, 1043195904, 556196864, 874378752, 85906688, 252810112, 352869056, 246764256, 559660016, 567514632, 1059464452, 85728134, 664751823 + ], + [ + 536870912, 268435456, 402653184, 469762048, 234881024, 318767104, 478150656, 281018368, 1063256064, 47185920, 678952960, 485752832, 299237376, 102432768, 639205376, 396640256, 586031104, 1003458560, 129984512, 200752128, 1055638016, 647015680, 333030784, 725973312, 981454432, 857085968, 880421352, 860392532, 798876174, 532364547 + ], + [ + 536870912, 805306368, 671088640, 335544320, 704643072, 788529152, 327155712, 281018368, 77594624, 831520768, 232259584, 691273728, 46268416, 1003290624, 782729216, 846610432, 919478272, 709529600, 696260608, 667003904, 723602944, 525349120, 209305216, 606415296, 207288864, 110647120, 424988808, 905087180, 1015340202, 868913813 + ], + [ + 536870912, 805306368, 402653184, 469762048, 234881024, 654311424, 662700032, 356515840, 937426944, 563085312, 34078720, 588513280, 786825216, 894763008, 478642176, 814071808, 904880128, 247574528, 480270336, 695307264, 404320768, 979170048, 487759488, 497259328, 1050295840, 955684976, 169680520, 208819020, 770924070, 733096055 + ], + [ + 536870912, 805306368, 402653184, 603979776, 301989888, 285212672, 343932928, 373293056, 996147200, 804257792, 835190784, 394002432, 353239040, 672989184, 419397632, 282443776, 1057136640, 26955776, 1031743488, 571765760, 170023424, 822808320, 826701184, 362850624, 483474016, 442080048, 985978248, 846985548, 47059558, 868085561 + ], + [ + 536870912, 805306368, 134217728, 872415232, 301989888, 184549376, 427819008, 750780416, 392167424, 628097024, 865599488, 567017472, 237895680, 278462464, 1011712000, 955138048, 955817984, 314380288, 750131200, 399797248, 354579968, 416785152, 790939520, 276540096, 293277024, 268052208, 347764232, 35365644, 814401410, 404925133 + ], + [ + 536870912, 268435456, 939524096, 872415232, 838860800, 855638016, 109051904, 222298112, 354418688, 391118848, 571998208, 168034304, 846331904, 883228672, 199393280, 828162048, 257368064, 445075456, 803190784, 268166144, 710414848, 816180480, 300071040, 240985536, 265698464, 382151760, 260020360, 325809604, 270599342, 953223261 + ], + [ + 536870912, 805306368, 671088640, 335544320, 369098752, 956301312, 545259520, 583008256, 631242752, 919601152, 650641408, 955514880, 1010171904, 512557056, 905674752, 378945536, 31203328, 963801088, 1023617024, 949720064, 250064384, 910459136, 135230592, 136353088, 311427104, 816401264, 520376968, 418361420, 470930090, 661240629 + ], + [ + 536870912, 268435456, 134217728, 1006632960, 637534208, 50331648, 25165824, 29360128, 681574400, 116391936, 215482368, 691273728, 923402240, 449380352, 779911168, 783695872, 400482304, 47362048, 125687808, 305605632, 547331584, 808586496, 233624448, 843013312, 63151776, 196447440, 659170824, 1000919300, 1009579394, 43945423 + ], + [ + 536870912, 268435456, 134217728, 335544320, 167772160, 16777216, 562036736, 977272832, 1029701632, 934281216, 196608000, 251396096, 278265856, 984285184, 396197888, 891731968, 739500032, 652308480, 351311872, 190440448, 487337472, 760111360, 593908352, 393395776, 106025760, 566805968, 358875560, 708557716, 116765322, 265539137 + ], + [ + 536870912, 268435456, 671088640, 603979776, 570425344, 989855744, 494927872, 255852544, 547356672, 506462208, 647495680, 974389248, 1019871232, 883228672, 697466880, 198197248, 1057595392, 826036224, 302446592, 375061504, 369893888, 35531008, 378530688, 556237248, 707471648, 1018431120, 737874824, 482115012, 625445674, 989556633 + ], + [ + 536870912, 805306368, 671088640, 738197504, 704643072, 956301312, 780140544, 700448768, 782237696, 789577728, 520617984, 659816448, 302120960, 125501440, 462848000, 844742656, 599629824, 539455488, 591460352, 828402688, 984658432, 194522880, 354161536, 188169664, 977849952, 87399664, 1060349032, 195260412, 166354402, 954163511 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 637534208, 50331648, 260046848, 364904448, 81788928, 741343232, 748158976, 644087808, 523894784, 997261312, 87588864, 385138688, 397664256, 870068224, 630102016, 652459008, 766823936, 1267456, 1011702144, 75974848, 948925728, 107141840, 166991880, 775060484, 1025355270, 317630223 + ], + [ + 536870912, 268435456, 134217728, 469762048, 167772160, 50331648, 746586112, 507510784, 517996544, 682622976, 364380160, 697040896, 402522112, 283312128, 699760640, 397590528, 1061003264, 122040320, 351209472, 327818240, 560989696, 1033387264, 530327168, 555201088, 568801952, 868136976, 352465960, 965011028, 172630154, 22056771 + ], + [ + 536870912, 268435456, 402653184, 738197504, 503316480, 654311424, 1031798784, 79691776, 396361728, 168820736, 489160704, 75759616, 1069678592, 706019328, 749371392, 410107904, 639229952, 754724864, 1041127424, 794958848, 226795008, 759369984, 659871360, 231425088, 1019247776, 731915088, 202411656, 371742788, 654598822, 470020699 + ], + [ + 536870912, 268435456, 939524096, 67108864, 905969664, 218103808, 444596224, 88080384, 1042284544, 957349888, 927465472, 537133056, 923926528, 745603072, 695762944, 987611136, 740171776, 700887040, 55306240, 742167552, 602884608, 25075968, 871870592, 798160448, 976352800, 1020815248, 772622344, 456647684, 426934798, 633373953 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 1040187392, 788529152, 327155712, 381681664, 262144000, 955252736, 641204224, 4456448, 599392256, 885325824, 855277568, 396673024, 682319872, 200093696, 613816320, 586394624, 309964288, 899961088, 699017600, 258785472, 500661152, 93549840, 170404232, 955105476, 421002158, 590525727 + ], + [ + 536870912, 805306368, 671088640, 469762048, 100663296, 1056964608, 931135488, 801112064, 304087040, 934281216, 404226048, 640942080, 510263296, 230621184, 440696832, 374521856, 289054720, 246829056, 479725568, 544498688, 680219136, 95405824, 590207104, 853444416, 110428768, 949665904, 147258088, 497080124, 477188226, 943203147 + ], + [ + 536870912, 805306368, 939524096, 603979776, 838860800, 620756992, 578813952, 390070272, 987758592, 300941312, 219676672, 513540096, 259129344, 20381696, 293109760, 439107584, 629858304, 148615168, 911357952, 442989568, 150064640, 161062144, 652017792, 370305856, 386304544, 348216944, 220251304, 559015996, 545861126, 657796357 + ], + [ + 536870912, 805306368, 402653184, 872415232, 503316480, 150994944, 897581056, 624951296, 1000341504, 923795456, 890765312, 482607104, 564527104, 295895040, 753172480, 183975936, 848977920, 376557568, 1005189120, 32277504, 464246272, 423186176, 93585792, 564024896, 162994656, 71040656, 316774504, 380758236, 218653070, 559711809 + ], + [ + 536870912, 805306368, 939524096, 335544320, 973078528, 486539264, 696254464, 1010827264, 945815552, 380633088, 348651520, 185860096, 620625920, 259325952, 340754432, 280805376, 98246656, 109252608, 974047232, 702405632, 753658368, 487276288, 133844864, 324161856, 452414240, 281074864, 161574792, 277954892, 857309998, 451739829 + ], + [ + 536870912, 805306368, 671088640, 469762048, 167772160, 553648128, 125829120, 1069547520, 325058560, 286261248, 974651392, 226230272, 724434944, 894107648, 949518336, 993837056, 412065792, 129740800, 13752320, 108655616, 82600448, 511169792, 940985216, 143060032, 241154336, 717453200, 582848680, 542002908, 274358786, 343987467 + ], + [ + 536870912, 268435456, 134217728, 603979776, 301989888, 721420288, 461373440, 557842432, 811597824, 814743552, 576192512, 26476544, 913702912, 792788992, 895516672, 1041252352, 93921280, 842305536, 658987008, 925490176, 924682752, 727433984, 267625600, 1034814144, 882152608, 553029552, 612401160, 817905668, 371269634, 762351625 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 503316480, 184549376, 75497472, 432013312, 329252864, 898629632, 1572864, 692846592, 622198784, 491978752, 416382976, 578371584, 192684032, 849285120, 554149888, 453770240, 125610496, 77525760, 772202880, 1032545344, 196970144, 415133904, 114713896, 938679188, 79702022, 136428555 + ], + [ + 536870912, 805306368, 939524096, 603979776, 905969664, 654311424, 444596224, 348127232, 392167424, 254803968, 786956288, 545521664, 609353728, 639565824, 366510080, 812400640, 1071046656, 181243904, 906430464, 257240064, 248173056, 408120576, 69098112, 1020865216, 703368544, 127343024, 778855912, 886541948, 978180614, 398868741 + ], + [ + 536870912, 268435456, 134217728, 67108864, 637534208, 855638016, 461373440, 440401920, 668991488, 141557760, 902299648, 958660608, 482213888, 345571328, 415006720, 1015169024, 568008704, 13021184, 903108608, 448150528, 219972096, 118699776, 845379456, 992712768, 768477216, 1003565936, 1029274120, 823982852, 1024593282, 727933761 + ], + [ + 536870912, 268435456, 402653184, 469762048, 167772160, 150994944, 58720256, 88080384, 685768704, 403701760, 671612928, 671875072, 796524544, 330235904, 208764928, 634929152, 1059332096, 759607296, 728569856, 640340992, 491255296, 594283776, 573282176, 189196480, 544025632, 682248624, 227005864, 231553140, 408631310, 1033856003 + ], + [ + 536870912, 805306368, 939524096, 469762048, 771751936, 117440512, 729808896, 398458880, 744488960, 653262848, 1572864, 563871744, 873070592, 354877440, 664043520, 1061044224, 50864128, 833884160, 829327360, 671122432, 335614464, 167781632, 889317504, 42006848, 994072352, 270583600, 491894696, 176814716, 125063814, 361711691 + ], + [ + 536870912, 805306368, 134217728, 67108864, 301989888, 654311424, 75497472, 725614592, 736100352, 210763776, 378011648, 899940352, 326238208, 362610688, 1030717440, 993214464, 419209216, 901730304, 114972672, 411571200, 1017459200, 787620608, 190622336, 206477632, 344115872, 113612112, 446881928, 301317708, 836381218, 604580625 + ], + [ + 536870912, 805306368, 134217728, 603979776, 1040187392, 16777216, 226492416, 750780416, 727711744, 745537536, 509083648, 473694208, 776601600, 1012203520, 219119616, 527646720, 35233792, 874262528, 379283456, 865975296, 1029381632, 947683072, 711641472, 511999936, 1036415328, 598097680, 72826760, 466615500, 991135458, 719867865 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 33554432, 218103808, 125829120, 239075328, 656408576, 594542592, 301465600, 375652352, 23986176, 509542400, 495419392, 991084544, 465903616, 1004417024, 247977984, 867312640, 183825920, 252133120, 919854208, 614778688, 210737760, 885959184, 821019240, 857624084, 438703202, 547569947 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 234881024, 620756992, 830472192, 499122176, 966787072, 149946368, 251133952, 999030784, 830341120, 370081792, 406224896, 530235392, 164962304, 58871808, 1011480576, 806663168, 807565824, 733570816, 409802880, 216955712, 707218720, 326269392, 917550376, 832163292, 375148330, 657877715 + ], + [ + 536870912, 268435456, 402653184, 67108864, 301989888, 419430400, 394264576, 155189248, 996147200, 179306496, 232259584, 673447936, 241565696, 173735936, 179929088, 613695488, 280944640, 687845376, 136304640, 99562496, 1012372992, 37904640, 104642176, 31637312, 1034707424, 795535120, 438354280, 1037138260, 157906446, 721277189 + ], + [ + 536870912, 268435456, 939524096, 469762048, 369098752, 486539264, 947912704, 650117120, 903872512, 959447040, 562561024, 1007943680, 511049728, 963575808, 753106944, 215498752, 552443904, 600543232, 777893888, 453188608, 183032320, 384122112, 379461760, 277504704, 771608928, 353534288, 766546792, 961048660, 821424614, 365421459 + ], + [ + 536870912, 268435456, 134217728, 201326592, 905969664, 83886080, 629145600, 566231040, 429916160, 726663168, 689438720, 664535040, 611450880, 364576768, 805273600, 405913600, 795385856, 328568832, 764934144, 841331712, 490637824, 823242496, 142113152, 250425152, 251356832, 287230896, 595596456, 1019334836, 941713194, 814780663 + ], + [ + 536870912, 268435456, 671088640, 67108864, 905969664, 218103808, 142606336, 247463936, 182452224, 634388480, 986185728, 303300608, 380764160, 688979968, 858292224, 507854848, 406462464, 69513216, 254470144, 772539392, 133092864, 838313728, 933947008, 416080448, 554659488, 640120464, 912418824, 257508356, 838661642, 186062593 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 570425344, 1056964608, 192937984, 683671552, 916455424, 416284672, 790102016, 738983936, 82968576, 487260160, 238518272, 74268672, 58957824, 407056384, 258115584, 611578880, 675955200, 693575424, 10255744, 168501056, 834079776, 715921456, 337866280, 370308916, 1010547630, 497020027 + ], + [ + 536870912, 805306368, 134217728, 335544320, 369098752, 1056964608, 897581056, 817889280, 325058560, 588251136, 62390272, 886308864, 406716416, 781778944, 803569664, 943079424, 503685120, 979841024, 538753024, 365071360, 990541312, 66536192, 518308992, 515310528, 289784224, 616970096, 216815112, 254489356, 440818818, 799932357 + ], + [ + 536870912, 268435456, 134217728, 67108864, 570425344, 419430400, 528482304, 373293056, 853540864, 787480576, 1028128768, 67895296, 539361280, 218038272, 202080256, 873054208, 40689664, 370634752, 244774912, 542548992, 746014208, 111556864, 356426368, 548090560, 739801504, 869645584, 911419304, 893210644, 449821482, 509820885 + ], + [ + 536870912, 805306368, 402653184, 469762048, 704643072, 520093696, 947912704, 574619648, 153092096, 814743552, 876085248, 1056702464, 654704640, 215416832, 340688896, 467812352, 758947840, 837218304, 682002432, 520489984, 550977024, 642696960, 417524608, 1069315648, 212228000, 419869840, 232153000, 500103324, 673431982, 199085979 + ], + [ + 536870912, 268435456, 939524096, 872415232, 167772160, 587202560, 176160768, 859832320, 425721856, 439353344, 454557696, 714342400, 1030619136, 82640896, 600473600, 865779712, 271720448, 519966720, 778369024, 618062848, 829010432, 846001920, 109811584, 268068288, 495144992, 354937648, 122684808, 589857476, 512507822, 595290877 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 369098752, 352321536, 562036736, 633339904, 769654784, 946864128, 715653120, 356253696, 881983488, 1049952256, 439320576, 617037824, 31154176, 349728768, 311724032, 875437056, 96982528, 173734656, 840534400, 200554560, 136199008, 659465552, 183918472, 340968268, 183874274, 866098463 + ], + [ + 536870912, 268435456, 402653184, 1006632960, 301989888, 117440512, 964689920, 197132288, 840957952, 735051776, 589824000, 272367616, 586809344, 244908032, 2392064, 10403840, 803659776, 171118592, 274036736, 195456000, 181595648, 1025857792, 169769600, 732336960, 449999584, 623144528, 908064264, 967304452, 500403334, 480540239 + ], + [ + 536870912, 268435456, 939524096, 335544320, 100663296, 218103808, 1065353216, 448790528, 924844032, 611319808, 932708352, 180617216, 675151872, 726859776, 928088064, 1038696448, 475881472, 259690496, 313350144, 430117888, 193587712, 1003310848, 179530368, 637622080, 486581984, 125856208, 247529064, 824255892, 695220230, 135889921 + ], + [ + 536870912, 268435456, 402653184, 872415232, 234881024, 50331648, 662700032, 624951296, 35651584, 470810624, 491257856, 805568512, 68812800, 406126592, 574783488, 83476480, 69017600, 863416320, 70957056, 757386240, 227242496, 20794624, 249993856, 322130752, 41968800, 1036053648, 585171592, 40972100, 704229030, 815623581 + ], + [ + 536870912, 805306368, 402653184, 603979776, 503316480, 654311424, 159383552, 88080384, 446693376, 242221056, 977797120, 448528384, 503185408, 365756416, 490176512, 95535104, 472424448, 321662976, 392566784, 625589248, 121410048, 515791104, 208435584, 80115520, 498622048, 364237232, 98722184, 574868300, 749915238, 624593081 + ], + [ + 536870912, 268435456, 671088640, 603979776, 436207616, 50331648, 360710144, 314572800, 249561088, 842006528, 50855936, 689176576, 256507904, 176095232, 31817728, 916701184, 593190912, 715550720, 440928256, 1010062336, 219843072, 403048704, 769131136, 791440320, 47676896, 434156144, 95526760, 516516276, 209029762, 918290381 + ], + [ + 536870912, 268435456, 671088640, 872415232, 234881024, 855638016, 1048576000, 406847488, 840957952, 26214400, 136839168, 505675776, 414056448, 221184000, 670007296, 529448960, 624910336, 788992000, 751470592, 1050770432, 13680128, 294235904, 1047847808, 174523072, 200967136, 978935440, 494699496, 1045585556, 985465826, 867409561 + ], + [ + 536870912, 268435456, 671088640, 201326592, 100663296, 754974720, 729808896, 901775360, 635437056, 5242880, 912785408, 142868480, 506855424, 728170496, 42958848, 499826688, 18653184, 715886592, 755857408, 65201152, 213510656, 514610432, 261271424, 828455104, 17905376, 46694992, 343166696, 950953556, 58434786, 430256983 + ], + [ + 536870912, 268435456, 939524096, 872415232, 436207616, 822083584, 176160768, 708837376, 127926272, 30408704, 967311360, 439091200, 869924864, 72810496, 794656768, 337854464, 622026752, 776663040, 895424512, 757087232, 999372288, 101209856, 805085056, 276012480, 796569376, 369621552, 976572584, 233740276, 1001973638, 702894537 + ], + [ + 536870912, 805306368, 402653184, 603979776, 973078528, 822083584, 192937984, 339738624, 442499072, 686817280, 355991552, 791412736, 33161216, 887029760, 353402880, 529088512, 393601024, 581365760, 886921216, 977425408, 640892416, 265015552, 675677312, 451741248, 383401120, 835677360, 580443688, 889040892, 735229966, 494642181 + ], + [ + 536870912, 268435456, 134217728, 469762048, 1040187392, 855638016, 864026624, 272629760, 526385152, 663748608, 665321472, 423362560, 816185344, 553451520, 914784256, 848117760, 75390976, 1035513856, 97908736, 293219328, 92994048, 598939392, 975693440, 37583424, 254191456, 113085296, 115828360, 412957252, 9848674, 140802935 + ], + [ + 536870912, 268435456, 402653184, 738197504, 771751936, 822083584, 377487360, 490733568, 1025507328, 202375168, 544735232, 641990656, 190185472, 332464128, 303595520, 276086784, 750739456, 808218624, 778766336, 792949760, 475924992, 157145344, 866306176, 187590592, 630571040, 22003632, 799377416, 279360516, 291105286, 341141771 + ], + [ + 536870912, 805306368, 671088640, 469762048, 33554432, 50331648, 830472192, 339738624, 576716800, 911212544, 461897728, 518782976, 874905600, 44367872, 803962880, 993148928, 148267008, 836620288, 746469376, 629226496, 977390080, 190961408, 416310400, 1011413312, 734850272, 295063792, 993799816, 149841484, 665413738, 635253175 + ], + [ + 536870912, 268435456, 939524096, 335544320, 704643072, 687865856, 377487360, 415236096, 597688320, 326107136, 454557696, 273416192, 345636864, 625410048, 727023616, 349650944, 165437440, 437481472, 360896512, 873126912, 89088512, 391148288, 36274816, 573963584, 151473056, 87414576, 881324328, 242599540, 661053574, 627412545 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 838860800, 419430400, 847249408, 54525952, 950009856, 386924544, 54001664, 239337472, 1054736384, 785580032, 771784704, 453001216, 327163904, 230715392, 165763072, 917593088, 648646144, 238935808, 138116480, 119382336, 65792992, 994395344, 912187496, 814962332, 706740230, 609222659 + ], + [ + 536870912, 268435456, 671088640, 201326592, 100663296, 1056964608, 92274688, 884998144, 601882624, 999292928, 932708352, 561774592, 499777536, 921894912, 406814720, 27049984, 500932608, 782897152, 354560000, 705111040, 97571328, 490276096, 701336960, 941816640, 579217824, 697349232, 983096232, 972841332, 428564002, 492006967 + ], + [ + 536870912, 268435456, 671088640, 1006632960, 570425344, 687865856, 1015021568, 675282944, 794820608, 856686592, 608698368, 553910272, 421658624, 601161728, 483033088, 199245824, 525426688, 1026052096, 622110720, 183170048, 1058081280, 1044913920, 470129280, 1000585536, 9732256, 640295760, 741454472, 1010306372, 6056618, 728706143 + ], + [ + 536870912, 268435456, 402653184, 67108864, 973078528, 318767104, 226492416, 742391808, 174063616, 206569472, 303562752, 141295616, 312606720, 182517760, 345014272, 850968576, 731652096, 281792512, 94738432, 496430080, 483303936, 625210112, 586216064, 283666624, 142942048, 36085520, 214310920, 576114692, 66000902, 636693505 + ], + [ + 536870912, 268435456, 939524096, 67108864, 234881024, 956301312, 209715200, 1027604480, 421527552, 137363456, 675807232, 683409408, 629538816, 488177664, 224690176, 671334400, 625680384, 460845056, 212961280, 956892160, 60586496, 515330304, 248552832, 756646976, 627426016, 335703728, 793399816, 745956612, 959467406, 147398977 + ], + [ + 536870912, 805306368, 402653184, 738197504, 973078528, 587202560, 696254464, 767557632, 270532608, 711983104, 634912768, 823918592, 317849600, 917700608, 995262464, 419577856, 984293376, 342814720, 344057856, 423732224, 962677248, 185666304, 46741632, 165004864, 942102176, 655723824, 830985896, 950324540, 679376558, 432569655 + ], + [ + 536870912, 268435456, 939524096, 335544320, 973078528, 587202560, 746586112, 700448768, 383778816, 896532480, 300417024, 721682432, 684064768, 893452288, 388005888, 261210112, 177774592, 602787840, 205723648, 415654912, 490786304, 992081664, 563137408, 328859456, 745377824, 151206448, 669417480, 1053868036, 532160526, 461115397 + ], + [ + 536870912, 805306368, 402653184, 67108864, 570425344, 788529152, 897581056, 239075328, 559939584, 57671680, 817364992, 164364288, 612499456, 351207424, 666664960, 1052459008, 1055121408, 673165312, 709109760, 93828096, 441527808, 933802240, 1015288960, 3610688, 461442720, 792785136, 98597416, 833624252, 655899790, 1058843725 + ], + [ + 536870912, 805306368, 671088640, 872415232, 905969664, 486539264, 109051904, 750780416, 891289600, 894435328, 698875904, 696516608, 230817792, 932118528, 368607232, 11321344, 1032249344, 1038946304, 233232384, 350002176, 662663680, 146882304, 455134080, 877667264, 757608288, 776277808, 593753832, 681493500, 632400386, 693740289 + ], + [ + 536870912, 805306368, 402653184, 738197504, 637534208, 117440512, 310378496, 289406976, 652214272, 686817280, 970457088, 408682496, 648937472, 32571392, 676954112, 161267712, 470769664, 1012936704, 1035057152, 221795328, 1034807808, 754321152, 493649792, 735500992, 389908704, 60744304, 1015658504, 647255052, 240904710, 253429515 + ], + [ + 536870912, 268435456, 671088640, 603979776, 905969664, 318767104, 125829120, 574619648, 786432000, 781189120, 498597888, 129761280, 557711360, 821231616, 568688640, 613662720, 632643584, 134877184, 20539392, 377291776, 866115072, 126016768, 592187264, 265802560, 710343456, 353780368, 595000488, 975603156, 238989698, 494083661 + ], + [ + 536870912, 268435456, 939524096, 335544320, 167772160, 218103808, 931135488, 398458880, 291504128, 256901120, 617086976, 203685888, 363462656, 234160128, 186810368, 846249984, 590880768, 165515264, 479643648, 452127744, 351884800, 146568960, 734504064, 708468032, 316515232, 269950736, 296971400, 920236356, 835483054, 1014933525 + ], + [ + 536870912, 268435456, 402653184, 469762048, 704643072, 855638016, 394264576, 826277888, 610271232, 774897664, 536346624, 952893440, 657850368, 416874496, 228360192, 863944704, 565043200, 193449984, 551573504, 418438144, 316152320, 781998848, 1023319424, 216919488, 99015008, 1037042224, 277445128, 458574596, 768288134, 169271751 + ], + [ + 536870912, 805306368, 402653184, 738197504, 234881024, 822083584, 343932928, 155189248, 241172480, 101711872, 42467328, 364118016, 996802560, 936181760, 84377600, 284934144, 746971136, 764620800, 820062208, 877671424, 325677568, 493108992, 356691584, 113812800, 693488160, 825980304, 228922504, 551722572, 49856166, 355212251 + ], + [ + 536870912, 805306368, 134217728, 335544320, 838860800, 687865856, 780140544, 4194304, 979369984, 818937856, 782761984, 569638912, 114950144, 255000576, 86409216, 250396672, 114778112, 880046080, 823916544, 328395776, 467017216, 418772224, 274366336, 326247616, 424085088, 624751408, 805279848, 994166332, 232818666, 370184953 + ], + [ + 536870912, 805306368, 402653184, 469762048, 100663296, 285212672, 578813952, 650117120, 299892736, 324009984, 734527488, 570163200, 995753984, 811794432, 1059487744, 913850368, 518365184, 925765632, 384129024, 53357568, 350579200, 137350400, 560255872, 493790144, 885272352, 958354800, 498941224, 544990332, 752024750, 180287163 + ], + [ + 536870912, 268435456, 671088640, 335544320, 33554432, 486539264, 377487360, 775946240, 849346560, 196083712, 372768768, 225705984, 546963456, 141623296, 995655680, 765804544, 561160192, 460132352, 840853504, 762508288, 896291328, 287196416, 821187968, 313341376, 108929440, 824323536, 331671560, 606254084, 21262858, 543364357 + ], + [ + 536870912, 268435456, 134217728, 201326592, 301989888, 218103808, 1065353216, 801112064, 44040192, 674234368, 287834112, 1000603648, 452329472, 145948672, 731217920, 534691840, 622272512, 576942080, 938293248, 331559936, 794636800, 397112064, 169414784, 437109440, 873665376, 212084752, 880190440, 49502932, 133441674, 416216775 + ], + [ + 536870912, 805306368, 671088640, 335544320, 503316480, 385875968, 511705088, 549453824, 916455424, 72351744, 488112128, 96731136, 996540416, 996999168, 587956224, 686178304, 338436096, 15347712, 777410560, 302261248, 591891968, 939333888, 481427584, 930239424, 626251168, 549704560, 385513096, 925769420, 271688490, 48876981 + ], + [ + 536870912, 805306368, 402653184, 67108864, 570425344, 83886080, 578813952, 1052770304, 819986432, 428867584, 483917824, 630980608, 756416512, 338231296, 731217920, 636665856, 764616704, 1002672128, 259680256, 213349376, 219710976, 519954176, 382075008, 634395840, 586740192, 351021360, 744476168, 258751244, 639594118, 1045264321 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 167772160, 352321536, 226492416, 390070272, 648019968, 747634688, 586678272, 400818176, 352714752, 1015611392, 497909760, 189415424, 485679104, 884396032, 44066816, 579881984, 167332352, 962866432, 281538688, 367552960, 224189472, 885130160, 601768456, 943517964, 506606210, 22534351 + ], + [ + 536870912, 268435456, 134217728, 335544320, 771751936, 419430400, 159383552, 809500672, 589299712, 791674880, 543686656, 237764608, 727842816, 374669312, 337018880, 41107456, 982327296, 890482688, 10299392, 1061886976, 492403200, 491109632, 332367744, 167178304, 916631008, 859155408, 486995336, 1051451716, 327776354, 603847317 + ], + [ + 536870912, 805306368, 671088640, 603979776, 704643072, 553648128, 595591168, 834666496, 119537664, 288358400, 306708480, 172752896, 33947648, 893976576, 919437312, 860307456, 623386624, 412930048, 668878848, 146619392, 577723904, 263549184, 306394496, 48368704, 269665120, 679155120, 512187912, 873033996, 246232458, 957811785 + ], + [ + 536870912, 805306368, 134217728, 872415232, 704643072, 989855744, 780140544, 96468992, 677380096, 972029952, 73924608, 985923584, 829554688, 1063321600, 829521920, 749223936, 421896192, 851660800, 53008384, 828699648, 232943104, 158982912, 899489664, 524270400, 770048544, 753563024, 835559432, 851922956, 381343746, 1026946061 + ], + [ + 536870912, 805306368, 939524096, 201326592, 301989888, 620756992, 276824064, 448790528, 740294656, 749731840, 730333184, 532414464, 708968448, 928448512, 244875264, 449069056, 479698944, 473559040, 599013376, 582904832, 930427392, 832481024, 440790144, 240606656, 68757408, 285476592, 1043749160, 491260988, 295479814, 468859663 + ], + [ + 536870912, 268435456, 671088640, 603979776, 771751936, 318767104, 696254464, 641728512, 983564288, 829423616, 358088704, 749993984, 244973568, 223412224, 434667520, 336412672, 427761664, 354578432, 188028928, 735742976, 913330688, 718865664, 368386944, 398089920, 660695968, 210799568, 101201928, 509475844, 1058523658, 946850057 + ], + [ + 536870912, 805306368, 671088640, 872415232, 838860800, 721420288, 243269632, 457179136, 236978176, 179306496, 520617984, 181665792, 530448384, 639827968, 578322432, 868007936, 56287232, 826617856, 111626240, 733965312, 60001792, 703658752, 1026038912, 778414528, 764878048, 997680976, 52883048, 243254684, 1056065026, 425744129 + ], + [ + 536870912, 268435456, 939524096, 603979776, 436207616, 452984832, 998244352, 616562688, 501219328, 982515712, 39321600, 357826560, 280625152, 104529920, 343638016, 198852608, 384524288, 763604992, 431974400, 641250304, 604279296, 377683200, 843049344, 989354816, 501539296, 907222064, 728162792, 338435124, 698311142, 768171069 + ], + [ + 536870912, 268435456, 134217728, 201326592, 301989888, 486539264, 931135488, 507510784, 589299712, 1064304640, 1067974656, 149684224, 306053120, 392888320, 910262272, 1059110912, 628105216, 782823424, 762083328, 293557248, 63589888, 393243392, 598221440, 317466304, 54479392, 854306448, 889257640, 729843540, 71401482, 841007111 + ], + [ + 536870912, 268435456, 134217728, 335544320, 369098752, 1056964608, 713031680, 801112064, 610271232, 982515712, 354942976, 638844928, 720764928, 830275584, 566394880, 549142528, 644292608, 190148608, 626497536, 831259648, 628758016, 788954880, 977610368, 507498560, 548970784, 29150576, 1059303560, 1038872388, 53356450, 30420277 + ], + [ + 536870912, 805306368, 939524096, 201326592, 234881024, 419430400, 427819008, 432013312, 316669952, 946864128, 690487296, 698613760, 448921600, 902234112, 777289728, 925515776, 755146752, 237408256, 933623808, 197272576, 407294464, 898892032, 852189312, 368238784, 659423584, 354548144, 999375336, 1020840316, 458004614, 914867407 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 1040187392, 117440512, 327155712, 994050048, 543162368, 856686592, 117964800, 764674048, 265420800, 619511808, 954171392, 610484224, 869621760, 892481536, 809277440, 192351232, 533156352, 796837632, 466873984, 384694592, 165591840, 216230992, 622150792, 689046092, 818716578, 70147615 + ], + [ + 536870912, 268435456, 671088640, 872415232, 838860800, 989855744, 897581056, 725614592, 866123776, 852492288, 343408640, 176422912, 198574080, 559611904, 505511936, 361873408, 165208064, 89403392, 590235648, 236942336, 949450240, 519702272, 49376128, 1021887808, 1071407072, 725765776, 789899880, 974112980, 940498946, 990851081 + ], + [ + 536870912, 805306368, 134217728, 335544320, 973078528, 855638016, 729808896, 46137344, 106954752, 456130560, 792199168, 835977216, 325713920, 58654720, 99909632, 58441728, 30924800, 558493696, 72189952, 1055794176, 681392640, 187165952, 328298112, 610912832, 282935904, 990300016, 25210088, 163630396, 836767370, 938539593 + ], + [ + 536870912, 805306368, 671088640, 67108864, 234881024, 318767104, 142606336, 918552576, 329252864, 110100480, 20447232, 293863424, 676462592, 192086016, 656572416, 398180352, 430956544, 625315840, 317851648, 811781120, 257669632, 635324160, 17572736, 851427904, 356323936, 211182320, 583070312, 94434044, 965769826, 62521085 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 503316480, 117440512, 914358272, 960495616, 350224384, 533725184, 718798848, 126615552, 108134400, 834994176, 180781056, 946520064, 594042880, 29732864, 583407616, 1013687296, 23626240, 415525632, 323395712, 866790336, 751381984, 334845904, 642693768, 520037572, 758607726, 608347935 + ], + [ + 536870912, 268435456, 134217728, 335544320, 704643072, 285212672, 260046848, 130023424, 480247808, 416284672, 614989824, 185335808, 987365376, 787808256, 767459328, 1057177600, 738271232, 637636608, 654338048, 545360896, 859956736, 98570496, 204506240, 656014912, 735345632, 229520656, 998967944, 849175364, 110336354, 273193557 + ], + [ + 536870912, 268435456, 671088640, 469762048, 503316480, 218103808, 931135488, 364904448, 199229440, 135266304, 750256128, 588513280, 198836224, 461701120, 438468608, 707805184, 558391296, 582856704, 804685824, 948587520, 211633664, 335946496, 673336960, 19966656, 801636384, 50155280, 584500872, 33285828, 175490602, 92941335 + ], + [ + 536870912, 805306368, 671088640, 67108864, 234881024, 50331648, 461373440, 440401920, 44040192, 1066401792, 43515904, 158597120, 332267520, 714932224, 303267840, 816726016, 1038917632, 96120832, 13793280, 734923776, 916290048, 806498560, 967828096, 728505280, 125556256, 62062640, 213893256, 154457804, 74421930, 562927345 + ], + [ + 536870912, 268435456, 671088640, 738197504, 301989888, 822083584, 830472192, 432013312, 316669952, 810549248, 180879360, 781451264, 208535552, 1006567424, 282558464, 647151616, 611688448, 675164160, 657864704, 826438656, 947689984, 113966336, 38397824, 987067840, 1028645728, 72247568, 164518760, 705617172, 636445026, 910037023 + ], + [ + 536870912, 268435456, 134217728, 872415232, 301989888, 553648128, 578813952, 700448768, 874512384, 959447040, 432537600, 180617216, 1038483456, 544800768, 63733760, 495075328, 728670208, 1029509120, 775669760, 428078080, 560987648, 543029504, 716879232, 54715456, 382664992, 304925616, 781334024, 77008132, 198298498, 559504717 + ], + [ + 536870912, 805306368, 671088640, 335544320, 369098752, 587202560, 713031680, 406847488, 387973120, 978321408, 192413696, 52166656, 573440000, 285147136, 113672192, 863748096, 231038976, 253939712, 76105728, 242605056, 57376256, 1016960768, 66047360, 488548928, 670456992, 57881296, 485561512, 266989276, 755296930, 759413209 + ], + [ + 536870912, 268435456, 134217728, 469762048, 838860800, 721420288, 209715200, 281018368, 799014912, 779091968, 603455488, 529268736, 891420672, 524877824, 550797312, 475938816, 928243712, 380637184, 5871616, 201114624, 568063488, 1044690176, 775344000, 540458432, 691431264, 112719760, 116846088, 194392324, 558291330, 541989063 + ] + ], + + "md_c" : [ + [[ 1.0000000 , 0.6000000 , 0.8000000 ], + [ 0.6000000 , 0.8000000 , 0.1500000 ], + [ 0.8000000 , 0.1500000 , 0.5809475 ]] + ], + + "md_vols" : [ + [[ 0.0000000 , 0.0000000 , 0.0000000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ]] + ], + + "md_drifts" : [ + [[ 0.0000000000000000 , 0.0000000000000000 , 0.0000000000000000 ], + [ -0.0000769148269844 , 0.0000327749731970 , -0.0000051340050666 ], + [ -0.0000769148269844 , 0.0000327749731970 , -0.0000051340050666 ], + [ -0.0000769148269844 , 0.0000327749731970 , -0.0000051340050666 ], + [ -0.0000769117410220 , 0.0000327819160986 , -0.0000051309191042 ], + [ -0.0000769117410220 , 0.0000327819160986 , -0.0000051309191042 ], + [ -0.0000769197006278 , 0.0000342555768863 , -0.0000036470215480 ], + [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], + [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], + [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], + [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], + [ -0.0000769231082238 , 0.0000348871540378 , -0.0000030110617889 ], + [ -0.0000769364349073 , 0.0000371477302492 , -0.0000007324359000 ], + [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], + [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], + [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], + [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], + [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], + [ -0.0000769436108138 , 0.0000383649635937 , 0.0000004945165018 ], + [ -0.0000769609069770 , 0.0000476737925826 , 0.0000098342203061 ], + [ -0.0000769695550586 , 0.0000523282070770 , 0.0000145040722083 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000769782031402 , 0.0000569826215715 , 0.0000191739241105 ], + [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], + [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], + [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], + [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], + [ -0.0000770387184138 , 0.0000525750483138 , 0.0000148283938103 ], + [ -0.0000770387184138 , 0.0000516935336623 , 0.0000148283938103 ], + [ -0.0000770931821601 , 0.0000481674750561 , 0.0000109174165401 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000481674750561 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000486764057747 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000486764057747 , 0.0000104828635101 ], + [ -0.0000770992336875 , 0.0000486764057747 , 0.0000104828635101 ], + [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], + [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], + [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], + [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], + [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], + [ -0.0000772189449197 , 0.0000486764057747 , 0.0000112366493239 ], + [ -0.0000772189449197 , 0.0000489308711339 , 0.0000112366493239 ], + [ -0.0000772189449197 , 0.0000491853364932 , 0.0000112366493239 ], + [ -0.0000772189449197 , 0.0000491853364932 , 0.0000112366493239 ], + [ -0.0000773147139055 , 0.0000491853364932 , 0.0000118396779749 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351376 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351377 ], + [ -0.0000773386561520 , 0.0000491853364932 , 0.0000119904351376 ], + [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], + [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], + [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], + [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], + [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], + [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], + [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], + [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], + [ -0.0000774788281904 , 0.0000502714491067 , 0.0000132707320858 ], + [ -0.0000775909658212 , 0.0000511403391975 , 0.0000142949696444 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000776190002289 , 0.0000513575617202 , 0.0000145510290340 ], + [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], + [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], + [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], + [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], + [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], + [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], + [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], + [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], + [ -0.0000777566242513 , 0.0000494090965224 , 0.0000128043798313 ], + [ -0.0000778667234691 , 0.0000478503243642 , 0.0000114070604692 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ], + [ -0.0000778942482736 , 0.0000474606313246 , 0.0000110577306286 ] + ] + ], + + "md_starts" : [ + [ 3758.0500000000001819, + 11840.0000000000000000, + 1200.0000000000000000 ] + ], + + "md_deterministic_values" : [ + [ ] + ], + + "md_discounts" : [ + [ 0.9800680293073579 , 0.9800680293073579 ] + ], + + "bb_inds" : + [[ 367, 183, 91, 45, 22, 11, 5, 2, 1, 3, 4, 8, 6, 7, 9, 10, 16, 13, 12, 14, 15, 19, 17, 18, 20, 21, 33, 27, 24, 23, 25, 26, 30, 28, 29, 31, 32, 39, 36, 34, 35, 37, 38, 42, 40, 41, 43, 44, 68, 56, 50, 47, 46, 48, 49, 53, 51, 52, 54, 55, 62, 59, 57, 58, 60, 61, 65, 63, 64, 66, 67, 79, 73, 70, 69, 71, 72, 76, 74, 75, 77, 78, 85, 82, 80, 81, 83, 84, 88, 86, 87, 89, 90, 137, 114, 102, 96, 93, 92, 94, 95, 99, 97, 98, 100, 101, 108, 105, 103, 104, 106, 107, 111, 109, 110, 112, 113, 125, 119, 116, 115, 117, 118, 122, 120, 121, 123, 124, 131, 128, 126, 127, 129, 130, 134, 132, 133, 135, 136, 160, 148, 142, 139, 138, 140, 141, 145, 143, 144, 146, 147, 154, 151, 149, 150, 152, 153, 157, 155, 156, 158, 159, 171, 165, 162, 161, 163, 164, 168, 166, 167, 169, 170, 177, 174, 172, 173, 175, 176, 180, 178, 179, 181, 182, 275, 229, 206, 194, 188, 185, 184, 186, 187, 191, 189, 190, 192, 193, 200, 197, 195, 196, 198, 199, 203, 201, 202, 204, 205, 217, 211, 208, 207, 209, 210, 214, 212, 213, 215, 216, 223, 220, 218, 219, 221, 222, 226, 224, 225, 227, 228, 252, 240, 234, 231, 230, 232, 233, 237, 235, 236, 238, 239, 246, 243, 241, 242, 244, 245, 249, 247, 248, 250, 251, 263, 257, 254, 253, 255, 256, 260, 258, 259, 261, 262, 269, 266, 264, 265, 267, 268, 272, 270, 271, 273, 274, 321, 298, 286, 280, 277, 276, 278, 279, 283, 281, 282, 284, 285, 292, 289, 287, 288, 290, 291, 295, 293, 294, 296, 297, 309, 303, 300, 299, 301, 302, 306, 304, 305, 307, 308, 315, 312, 310, 311, 313, 314, 318, 316, 317, 319, 320, 344, 332, 326, 323, 322, 324, 325, 329, 327, 328, 330, 331, 338, 335, 333, 334, 336, 337, 341, 339, 340, 342, 343, 355, 349, 346, 345, 347, 348, 352, 350, 351, 353, 354, 361, 358, 356, 357, 359, 360, 364, 362, 363, 365, 366 ], + [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 5, 5, 6, 8, 9, 11, 11, 11, 13, 14, 16, 16, 17, 19, 20, 22, 22, 22, 22, 24, 25, 27, 27, 28, 30, 31, 33, 33, 33, 34, 36, 37, 39, 39, 40, 42, 43, 45, 45, 45, 45, 45, 47, 48, 50, 50, 51, 53, 54, 56, 56, 56, 57, 59, 60, 62, 62, 63, 65, 66, 68, 68, 68, 68, 70, 71, 73, 73, 74, 76, 77, 79, 79, 79, 80, 82, 83, 85, 85, 86, 88, 89, 91, 91, 91, 91, 91, 91, 93, 94, 96, 96, 97, 99, 100, 102, 102, 102, 103, 105, 106, 108, 108, 109, 111, 112, 114, 114, 114, 114, 116, 117, 119, 119, 120, 122, 123, 125, 125, 125, 126, 128, 129, 131, 131, 132, 134, 135, 137, 137, 137, 137, 137, 139, 140, 142, 142, 143, 145, 146, 148, 148, 148, 149, 151, 152, 154, 154, 155, 157, 158, 160, 160, 160, 160, 162, 163, 165, 165, 166, 168, 169, 171, 171, 171, 172, 174, 175, 177, 177, 178, 180, 181, 183, 183, 183, 183, 183, 183, 183, 185, 186, 188, 188, 189, 191, 192, 194, 194, 194, 195, 197, 198, 200, 200, 201, 203, 204, 206, 206, 206, 206, 208, 209, 211, 211, 212, 214, 215, 217, 217, 217, 218, 220, 221, 223, 223, 224, 226, 227, 229, 229, 229, 229, 229, 231, 232, 234, 234, 235, 237, 238, 240, 240, 240, 241, 243, 244, 246, 246, 247, 249, 250, 252, 252, 252, 252, 254, 255, 257, 257, 258, 260, 261, 263, 263, 263, 264, 266, 267, 269, 269, 270, 272, 273, 275, 275, 275, 275, 275, 275, 277, 278, 280, 280, 281, 283, 284, 286, 286, 286, 287, 289, 290, 292, 292, 293, 295, 296, 298, 298, 298, 298, 300, 301, 303, 303, 304, 306, 307, 309, 309, 309, 310, 312, 313, 315, 315, 316, 318, 319, 321, 321, 321, 321, 321, 323, 324, 326, 326, 327, 329, 330, 332, 332, 332, 333, 335, 336, 338, 338, 339, 341, 342, 344, 344, 344, 344, 346, 347, 349, 349, 350, 352, 353, 355, 355, 355, 356, 358, 359, 361, 361, 362, 364, 365 ], + [ 0, 367, 183, 91, 45, 22, 11, 5, 2, 5, 5, 11, 8, 8, 11, 11, 22, 16, 13, 16, 16, 22, 19, 19, 22, 22, 45, 33, 27, 24, 27, 27, 33, 30, 30, 33, 33, 45, 39, 36, 36, 39, 39, 45, 42, 42, 45, 45, 91, 68, 56, 50, 47, 50, 50, 56, 53, 53, 56, 56, 68, 62, 59, 59, 62, 62, 68, 65, 65, 68, 68, 91, 79, 73, 70, 73, 73, 79, 76, 76, 79, 79, 91, 85, 82, 82, 85, 85, 91, 88, 88, 91, 91, 183, 137, 114, 102, 96, 93, 96, 96, 102, 99, 99, 102, 102, 114, 108, 105, 105, 108, 108, 114, 111, 111, 114, 114, 137, 125, 119, 116, 119, 119, 125, 122, 122, 125, 125, 137, 131, 128, 128, 131, 131, 137, 134, 134, 137, 137, 183, 160, 148, 142, 139, 142, 142, 148, 145, 145, 148, 148, 160, 154, 151, 151, 154, 154, 160, 157, 157, 160, 160, 183, 171, 165, 162, 165, 165, 171, 168, 168, 171, 171, 183, 177, 174, 174, 177, 177, 183, 180, 180, 183, 183, 367, 275, 229, 206, 194, 188, 185, 188, 188, 194, 191, 191, 194, 194, 206, 200, 197, 197, 200, 200, 206, 203, 203, 206, 206, 229, 217, 211, 208, 211, 211, 217, 214, 214, 217, 217, 229, 223, 220, 220, 223, 223, 229, 226, 226, 229, 229, 275, 252, 240, 234, 231, 234, 234, 240, 237, 237, 240, 240, 252, 246, 243, 243, 246, 246, 252, 249, 249, 252, 252, 275, 263, 257, 254, 257, 257, 263, 260, 260, 263, 263, 275, 269, 266, 266, 269, 269, 275, 272, 272, 275, 275, 367, 321, 298, 286, 280, 277, 280, 280, 286, 283, 283, 286, 286, 298, 292, 289, 289, 292, 292, 298, 295, 295, 298, 298, 321, 309, 303, 300, 303, 303, 309, 306, 306, 309, 309, 321, 315, 312, 312, 315, 315, 321, 318, 318, 321, 321, 367, 344, 332, 326, 323, 326, 326, 332, 329, 329, 332, 332, 344, 338, 335, 335, 338, 338, 344, 341, 341, 344, 344, 367, 355, 349, 346, 349, 349, 355, 352, 352, 355, 355, 367, 361, 358, 358, 361, 361, 367, 364, 364, 367, 367 ] + ], + + "bb_data" : + [[ 1.0013689260344547, 0.5006769876043941, 0.3530474200541117, 0.2482204548705323, 0.1734206441019846, 0.1197954333762150, 0.0810884854079383, 0.0453298413911625, 0.0000000000000000, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0864406158858196, 0.0573382179080996, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.1253939592915132, 0.0864406158858196, 0.0573382179080996, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0906596827823249, 0.0641060764756032, 0.0427373843170688, 0.0370116605098802, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098802, 0.0427373843170688, 0.0370116605098803, 0.1775016882034323, 0.1253939592915132, 0.0864406158858195, 0.0573382179080996, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0906596827823249, 0.0641060764756033, 0.0427373843170689, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.1253939592915132, 0.0864406158858196, 0.0573382179080996, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756033, 0.0427373843170689, 0.0370116605098802, 0.0427373843170689, 0.0370116605098803, 0.0906596827823249, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170688, 0.0370116605098803, 0.0641060764756032, 0.0427373843170688, 0.0370116605098803, 0.0427373843170689, 0.0370116605098802, 0.2510252948014144, 0.1775016882034323, 0.1253939592915132, 0.0864406158858195, 0.0573382179080996, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0906596827823250, 0.0641060764756033, 0.0427373843170690, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.0641060764756032, 0.0427373843170687, 0.0370116605098802, 0.0427373843170690, 0.0370116605098802, 0.1253939592915132, 0.0864406158858195, 0.0573382179080996, 0.0370116605098802, 0.0427373843170690, 0.0370116605098802, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0906596827823250, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170690, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.1775016882034323, 0.1253939592915131, 0.0864406158858195, 0.0573382179080996, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.0641060764756032, 0.0427373843170687, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.0906596827823249, 0.0641060764756032, 0.0427373843170687, 0.0370116605098802, 0.0427373843170690, 0.0370116605098802, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.1253939592915132, 0.0864406158858195, 0.0573382179080996, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0641060764756032, 0.0427373843170688, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0906596827823250, 0.0641060764756033, 0.0427373843170690, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.0641060764756032, 0.0427373843170687, 0.0370116605098802, 0.0427373843170688, 0.0370116605098804, 0.3550033764068646, 0.2510252948014144, 0.1775016882034323, 0.1253939592915132, 0.0864406158858196, 0.0573382179080996, 0.0370116605098804, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0906596827823249, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170693, 0.0370116605098802, 0.1253939592915131, 0.0864406158858195, 0.0573382179080995, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0906596827823249, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.1775016882034323, 0.1253939592915131, 0.0864406158858196, 0.0573382179080996, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0906596827823249, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.1253939592915133, 0.0864406158858197, 0.0573382179080998, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0906596827823249, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170693, 0.0370116605098802, 0.2510252948014144, 0.1775016882034322, 0.1253939592915131, 0.0864406158858195, 0.0573382179080995, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0906596827823249, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170693, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.1253939592915131, 0.0864406158858196, 0.0573382179080996, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0906596827823249, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.1775016882034324, 0.1253939592915133, 0.0864406158858197, 0.0573382179080998, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806, 0.0906596827823249, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170687, 0.0370116605098802, 0.0427373843170693, 0.0370116605098802, 0.1253939592915133, 0.0864406158858195, 0.0573382179080995, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756033, 0.0427373843170689, 0.0370116605098806, 0.0427373843170687, 0.0370116605098802, 0.0906596827823250, 0.0641060764756031, 0.0427373843170687, 0.0370116605098802, 0.0427373843170687, 0.0370116605098802, 0.0641060764756035, 0.0427373843170693, 0.0370116605098802, 0.0427373843170689, 0.0370116605098806 ], + [ 0.0000000000000000, 0.5027322404371586, 0.5054945054945055, 0.5111111111111111, 0.5227272727272727, 0.5238095238095238, 0.6000000000000000, 0.7500000000000001, 1.0000000000000000, 0.6666666666666666, 0.5000000000000001, 0.4999999999999999, 0.6666666666666669, 0.5000000000000003, 0.6666666666666666, 0.5000000000000000, 0.5454545454545455, 0.6000000000000001, 0.4999999999999994, 0.6666666666666664, 0.4999999999999994, 0.5000000000000000, 0.6666666666666664, 0.4999999999999994, 0.6666666666666664, 0.5000000000000007, 0.5217391304347826, 0.5454545454545455, 0.5999999999999996, 0.5000000000000000, 0.6666666666666677, 0.5000000000000000, 0.4999999999999996, 0.6666666666666666, 0.5000000000000000, 0.6666666666666677, 0.5000000000000000, 0.5000000000000000, 0.5000000000000004, 0.6666666666666661, 0.4999999999999987, 0.6666666666666666, 0.5000000000000000, 0.5000000000000004, 0.6666666666666661, 0.5000000000000012, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.5217391304347827, 0.5454545454545453, 0.5999999999999996, 0.5000000000000026, 0.6666666666666677, 0.5000000000000026, 0.5000000000000000, 0.6666666666666677, 0.4999999999999974, 0.6666666666666677, 0.4999999999999974, 0.4999999999999996, 0.4999999999999992, 0.6666666666666655, 0.5000000000000026, 0.6666666666666677, 0.5000000000000026, 0.5000000000000000, 0.6666666666666677, 0.4999999999999974, 0.6666666666666677, 0.4999999999999974, 0.5217391304347823, 0.5454545454545457, 0.5999999999999996, 0.4999999999999974, 0.6666666666666677, 0.4999999999999974, 0.5000000000000009, 0.6666666666666644, 0.5000000000000000, 0.6666666666666655, 0.5000000000000026, 0.5000000000000000, 0.5000000000000000, 0.6666666666666677, 0.5000000000000026, 0.6666666666666677, 0.4999999999999974, 0.5000000000000000, 0.6666666666666677, 0.4999999999999974, 0.6666666666666644, 0.5000000000000000, 0.4999999999999999, 0.5000000000000000, 0.5217391304347829, 0.5454545454545453, 0.5999999999999975, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.6666666666666690, 0.4999999999999949, 0.6666666666666666, 0.5000000000000000, 0.4999999999999992, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.6666666666666690, 0.5000000000000051, 0.5000000000000017, 0.6666666666666666, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.5217391304347829, 0.5454545454545453, 0.6000000000000016, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.4999999999999983, 0.6666666666666690, 0.5000000000000051, 0.6666666666666666, 0.5000000000000000, 0.5000000000000009, 0.4999999999999983, 0.6666666666666690, 0.4999999999999949, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.6666666666666690, 0.5000000000000051, 0.5000000000000002, 0.5217391304347825, 0.5454545454545453, 0.6000000000000016, 0.5000000000000000, 0.6666666666666690, 0.5000000000000051, 0.5000000000000017, 0.6666666666666666, 0.5000000000000000, 0.6666666666666690, 0.4999999999999949, 0.5000000000000000, 0.5000000000000017, 0.6666666666666666, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.4999999999999983, 0.6666666666666690, 0.5000000000000051, 0.6666666666666666, 0.5000000000000000, 0.5217391304347829, 0.5454545454545453, 0.5999999999999975, 0.5000000000000051, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.6666666666666690, 0.4999999999999949, 0.6666666666666666, 0.5000000000000000, 0.4999999999999992, 0.5000000000000000, 0.6666666666666622, 0.5000000000000000, 0.6666666666666690, 0.5000000000000051, 0.5000000000000017, 0.6666666666666666, 0.5000000000000000, 0.6666666666666690, 0.4999999999999949, 0.5000000000000000, 0.5000000000000001, 0.4999999999999998, 0.5217391304347820, 0.5454545454545461, 0.5999999999999975, 0.4999999999999949, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101, 0.5000000000000017, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666576, 0.5000000000000000, 0.5217391304347825, 0.5454545454545471, 0.6000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000004, 0.5217391304347825, 0.5454545454545434, 0.6000000000000032, 0.5000000000000000, 0.6666666666666712, 0.4999999999999899, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5217391304347816, 0.5454545454545451, 0.5999999999999951, 0.4999999999999899, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101, 0.5000000000000017, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666576, 0.5000000000000000, 0.5000000000000004, 0.5000000000000000, 0.5217391304347825, 0.5454545454545471, 0.6000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.5000000000000017, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999966, 0.6666666666666576, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5217391304347825, 0.5454545454545434, 0.6000000000000032, 0.5000000000000000, 0.6666666666666712, 0.4999999999999899, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999983, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.5217391304347816, 0.5454545454545451, 0.5999999999999951, 0.4999999999999899, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101, 0.5000000000000017, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.6666666666666666, 0.5000000000000000, 0.6666666666666576, 0.5000000000000000, 0.5217391304347834, 0.5454545454545471, 0.6000000000000000, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.4999999999999966, 0.6666666666666712, 0.5000000000000101, 0.6666666666666666, 0.5000000000000000, 0.5000000000000033, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.6666666666666666, 0.5000000000000000, 0.5000000000000000, 0.6666666666666576, 0.5000000000000000, 0.6666666666666712, 0.5000000000000101 ], + [ 0.0000000000000000, 0.4972677595628415, 0.4945054945054945, 0.4888888888888889, 0.4772727272727272, 0.4761904761904762, 0.4000000000000000, 0.2500000000000000, 0.0000000000000000, 0.3333333333333333, 0.4999999999999998, 0.5000000000000001, 0.3333333333333332, 0.4999999999999997, 0.3333333333333333, 0.5000000000000000, 0.4545454545454545, 0.3999999999999999, 0.5000000000000007, 0.3333333333333336, 0.5000000000000007, 0.5000000000000000, 0.3333333333333336, 0.5000000000000007, 0.3333333333333336, 0.4999999999999994, 0.4782608695652174, 0.4545454545454545, 0.4000000000000004, 0.5000000000000000, 0.3333333333333322, 0.5000000000000000, 0.5000000000000004, 0.3333333333333333, 0.5000000000000000, 0.3333333333333322, 0.5000000000000000, 0.5000000000000000, 0.4999999999999996, 0.3333333333333339, 0.5000000000000012, 0.3333333333333333, 0.5000000000000000, 0.4999999999999996, 0.3333333333333339, 0.4999999999999987, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.4782608695652172, 0.4545454545454547, 0.4000000000000004, 0.4999999999999974, 0.3333333333333322, 0.4999999999999974, 0.5000000000000000, 0.3333333333333322, 0.5000000000000026, 0.3333333333333322, 0.5000000000000026, 0.5000000000000004, 0.5000000000000009, 0.3333333333333345, 0.4999999999999974, 0.3333333333333322, 0.4999999999999974, 0.5000000000000000, 0.3333333333333322, 0.5000000000000026, 0.3333333333333322, 0.5000000000000026, 0.4782608695652177, 0.4545454545454543, 0.4000000000000004, 0.5000000000000026, 0.3333333333333322, 0.5000000000000026, 0.4999999999999992, 0.3333333333333356, 0.5000000000000000, 0.3333333333333345, 0.4999999999999974, 0.5000000000000000, 0.5000000000000000, 0.3333333333333322, 0.4999999999999974, 0.3333333333333322, 0.5000000000000026, 0.5000000000000000, 0.3333333333333322, 0.5000000000000026, 0.3333333333333356, 0.5000000000000000, 0.5000000000000001, 0.5000000000000000, 0.4782608695652171, 0.4545454545454547, 0.4000000000000024, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.3333333333333311, 0.5000000000000051, 0.3333333333333333, 0.5000000000000000, 0.5000000000000009, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.3333333333333311, 0.4999999999999949, 0.4999999999999983, 0.3333333333333333, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.4782608695652171, 0.4545454545454547, 0.3999999999999984, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.5000000000000017, 0.3333333333333311, 0.4999999999999949, 0.3333333333333333, 0.5000000000000000, 0.4999999999999992, 0.5000000000000017, 0.3333333333333311, 0.5000000000000051, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.3333333333333311, 0.4999999999999949, 0.4999999999999998, 0.4782608695652175, 0.4545454545454547, 0.3999999999999984, 0.5000000000000000, 0.3333333333333311, 0.4999999999999949, 0.4999999999999983, 0.3333333333333333, 0.5000000000000000, 0.3333333333333311, 0.5000000000000051, 0.5000000000000000, 0.4999999999999983, 0.3333333333333333, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.5000000000000017, 0.3333333333333311, 0.4999999999999949, 0.3333333333333333, 0.5000000000000000, 0.4782608695652171, 0.4545454545454547, 0.4000000000000024, 0.4999999999999949, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.3333333333333311, 0.5000000000000051, 0.3333333333333333, 0.5000000000000000, 0.5000000000000009, 0.5000000000000000, 0.3333333333333378, 0.5000000000000000, 0.3333333333333311, 0.4999999999999949, 0.4999999999999983, 0.3333333333333333, 0.5000000000000000, 0.3333333333333311, 0.5000000000000051, 0.4999999999999999, 0.4999999999999999, 0.5000000000000002, 0.4782608695652179, 0.4545454545454539, 0.4000000000000024, 0.5000000000000051, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899, 0.4999999999999983, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333424, 0.5000000000000000, 0.4782608695652175, 0.4545454545454529, 0.4000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4999999999999996, 0.4782608695652175, 0.4545454545454565, 0.3999999999999967, 0.5000000000000000, 0.3333333333333288, 0.5000000000000101, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4782608695652184, 0.4545454545454549, 0.4000000000000049, 0.5000000000000101, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899, 0.4999999999999983, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333424, 0.5000000000000000, 0.4999999999999996, 0.5000000000000000, 0.4782608695652175, 0.4545454545454529, 0.4000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.4999999999999983, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000033, 0.3333333333333424, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4782608695652175, 0.4545454545454565, 0.3999999999999967, 0.5000000000000000, 0.3333333333333288, 0.5000000000000101, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000017, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.4782608695652184, 0.4545454545454549, 0.4000000000000049, 0.5000000000000101, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899, 0.4999999999999983, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.3333333333333333, 0.5000000000000000, 0.3333333333333424, 0.5000000000000000, 0.4782608695652166, 0.4545454545454529, 0.4000000000000000, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000033, 0.3333333333333288, 0.4999999999999899, 0.3333333333333333, 0.5000000000000000, 0.4999999999999966, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.3333333333333333, 0.5000000000000000, 0.5000000000000000, 0.3333333333333424, 0.5000000000000000, 0.3333333333333288, 0.4999999999999899 ] + ] +} diff --git a/benchmarks/OptionPricing/datasets/large/output.json b/benchmarks/OptionPricing/datasets/large/output.json new file mode 100644 index 0000000..5be6d0f --- /dev/null +++ b/benchmarks/OptionPricing/datasets/large/output.json @@ -0,0 +1 @@ +[ 1046.2474858484 ] diff --git a/benchmarks/OptionPricing/datasets/medium/input.json b/benchmarks/OptionPricing/datasets/medium/input.json new file mode 100644 index 0000000..17206ae --- /dev/null +++ b/benchmarks/OptionPricing/datasets/medium/input.json @@ -0,0 +1,106 @@ +{ + "contract_number" : 2, + "monte_carlo_iterations" : 1048576, + "num_path_dates" : 5, + "num_underlyings" : 3, + "num_models" : 1, + "num_bits" : 30, + "dir_vs" : + [ + [ + 536870912, 268435456, 134217728, 67108864, 33554432, 16777216, 8388608, 4194304, 2097152, 1048576, 524288, 262144, 131072, 65536, 32768, 16384, 8192, 4096, 2048, 1024, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1 + ], + [ + 536870912, 805306368, 671088640, 1006632960, 570425344, 855638016, 713031680, 1069547520, 538968064, 808452096, 673710080, 1010565120, 572653568, 858980352, 715816960, 1073725440, 536879104, 805318656, 671098880, 1006648320, 570434048, 855651072, 713042560, 1069563840, 538976288, 808464432, 673720360, 1010580540, 572662306, 858993459 + ], + [ + 536870912, 805306368, 402653184, 603979776, 973078528, 385875968, 595591168, 826277888, 438304768, 657457152, 999817216, 358875136, 538574848, 807862272, 406552576, 605372416, 975183872, 389033984, 597170176, 828646400, 437926400, 656873216, 1002152832, 357921088, 536885792, 805312304, 402662296, 603992420, 973085210, 385885991 + ], + [ + 536870912, 805306368, 939524096, 335544320, 234881024, 721420288, 411041792, 616562688, 920649728, 1062207488, 381157376, 258736128, 771883008, 453181440, 545488896, 817971200, 954261504, 340963328, 238651392, 732843008, 417426944, 609285376, 909831040, 1068349120, 383778848, 256901168, 783810616, 460062740, 537001998, 805503019 + ], + [ + 536870912, 805306368, 402653184, 1006632960, 167772160, 285212672, 713031680, 566231040, 853540864, 489684992, 952631296, 208928768, 316801024, 758317056, 550076416, 813154304, 417505280, 1009913856, 172697600, 297131008, 704744960, 553894656, 847291520, 499194688, 954376224, 204607536, 306915352, 766893116, 536972810, 805552913 + ], + [ + 536870912, 805306368, 402653184, 469762048, 301989888, 721420288, 92274688, 264241152, 941621248, 741343232, 169345024, 924581888, 395444224, 619380736, 1034256384, 603963392, 838868992, 452997120, 494934016, 331357184, 706744832, 120597248, 261621120, 953946048, 800208928, 148581424, 935168536, 350484252, 630339474, 1072370923 + ], + [ + 536870912, 805306368, 134217728, 1006632960, 503316480, 754974720, 629145600, 440401920, 94371840, 711983104, 229113856, 374079488, 330694656, 996212736, 907247616, 557531136, 867573760, 190918656, 1041467392, 490437632, 766918144, 643898624, 462663040, 125527616, 672545696, 202454896, 373006376, 288845836, 1000351766, 930090001 + ], + [ + 536870912, 268435456, 402653184, 872415232, 838860800, 956301312, 612368384, 717225984, 211812352, 386924544, 302514176, 688128000, 1015414784, 516751360, 1051492352, 773734400, 914432000, 63877120, 807741440, 165200896, 748683776, 118489344, 168296832, 486802240, 243663648, 667747216, 439124552, 81674924, 975249610, 350138737 + ], + [ + 536870912, 268435456, 671088640, 469762048, 973078528, 1023410176, 713031680, 339738624, 912261120, 797966336, 176685056, 71565312, 510263296, 865533952, 814120960, 961232896, 887136256, 668078080, 116070400, 382772224, 1047134720, 597098752, 411468416, 625689024, 249602976, 449975248, 745216680, 43033924, 134873446, 201786361 + ], + [ + 536870912, 268435456, 402653184, 67108864, 704643072, 385875968, 696254464, 205520896, 920649728, 946864128, 359137280, 859045888, 302907392, 50659328, 462192640, 524599296, 895541248, 590794752, 168810496, 118033408, 831447552, 138662144, 485185920, 796511296, 1021313184, 1064304752, 619184920, 997458052, 250479054, 745865975 + ], + [ + 536870912, 268435456, 939524096, 1006632960, 838860800, 889192448, 645922816, 46137344, 476053504, 584056832, 210239488, 465829888, 820903936, 689897472, 73695232, 249118720, 110075904, 315338752, 610637824, 517665792, 1049494016, 785318144, 376210304, 735921088, 402760480, 738505552, 168368744, 151499820, 344957894, 936096557 + ], + [ + 536870912, 805306368, 939524096, 1006632960, 503316480, 922746880, 41943040, 423624704, 228589568, 651165696, 195559424, 500957184, 791019520, 261292032, 1040285696, 118407168, 982065152, 625250304, 329533440, 298984448, 153690624, 76845824, 579619712, 692987840, 900670432, 450334832, 363187112, 719119956, 765461306, 382730781 + ], + [ + 536870912, 805306368, 402653184, 603979776, 838860800, 117440512, 478150656, 658505728, 752877568, 1060110336, 141033472, 209453056, 244187136, 272957440, 678068224, 1014546432, 377724928, 876875776, 443160576, 998185984, 168665600, 318837504, 914397568, 71818816, 40763680, 527762288, 939688008, 335855668, 705536494, 587273091 + ], + [ + 536870912, 268435456, 671088640, 738197504, 637534208, 150994944, 813694976, 943718400, 77594624, 179306496, 798490624, 967049216, 134348800, 1006698496, 235044864, 620937216, 377643008, 826314752, 874711040, 854819840, 725109248, 856992512, 664336768, 94804544, 100663328, 419430416, 411041832, 339738668, 580911142, 61865993 + ], + [ + 536870912, 805306368, 939524096, 603979776, 100663296, 452984832, 998244352, 188743680, 866123776, 389021696, 287834112, 172228608, 824836096, 977731584, 153714688, 507854848, 254402560, 88403968, 883578880, 235160576, 118055424, 422917888, 371224704, 326210368, 654926368, 691353392, 773877944, 930190180, 554263078, 842348331 + ] + ], + + "md_c" : [ + [[ 1.0000000 , 0.6000000 , 0.8000000 ], + [ 0.6000000 , 0.8000000 , 0.1500000 ], + [ 0.8000000 , 0.1500000 , 0.5809475 ] + ] + ], + + "md_vols" : [ + [[ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ], + [ 0.1900000 , 0.1900000 , 0.1500000 ] + ] + ], + + "md_drifts" : [ + [[ -0.0283491736871803 , 0.0178771081725381 , 0.0043096808044729 ], + [ -0.0183841413744211 , -0.0044530897672834 , 0.0024263805987983 ], + [ -0.0172686581005089 , 0.0125638544546015 , 0.0094452810918001 ], + [ -0.0144179417871814 , 0.0157411263968213 , 0.0125315353728014 ], + [ -0.0121497422218761 , 0.0182904634062437 , 0.0151125070556484 ] + ] + ], + + "md_starts" : [ + [ 3758.0500000000001819, 11840.0000000000000000, 1200.0000000000000000 ] + ], + + "md_deterministic_values" : [ + [ ] + ], + + "md_discounts" : [ + [ 0.9797862861805930, + 0.9505748482484491, + 0.9214621679912968, + 0.8906693055891434, + 0.8588567633110704] + ], + + "bb_inds" : [[ 5, 2, 1, 3, 4 ], + [ 0, 0, 0, 2, 3 ], + [ 0, 5, 2, 5, 5 ] + ], + + "bb_data" : [[ 2.2372928847280580, 1.0960951589853829, 0.7075902730592357, 0.8166828043492210, 0.7075902730592357 ], + [ 0.0000000000000000, 0.5998905309250137, 0.4993160054719562, 0.6669708029197080, 0.5006839945280438 ], + [ 0.0000000000000000, 0.4001094690749863, 0.5006839945280438, 0.3330291970802919, 0.4993160054719562 ]] +} diff --git a/benchmarks/OptionPricing/datasets/medium/output.json b/benchmarks/OptionPricing/datasets/medium/output.json new file mode 100644 index 0000000..b82a9e1 --- /dev/null +++ b/benchmarks/OptionPricing/datasets/medium/output.json @@ -0,0 +1 @@ +[ 937.3915829436 ] diff --git a/benchmarks/OptionPricing/datasets/small/input.json b/benchmarks/OptionPricing/datasets/small/input.json new file mode 100644 index 0000000..5579e24 --- /dev/null +++ b/benchmarks/OptionPricing/datasets/small/input.json @@ -0,0 +1,39 @@ +{ + "contract_number": 1, + "monte_carlo_iterations" : 8388608, + "num_path_dates": 1, + "num_underlyings" : 1, + "num_models" : 1, + "num_bits" : 30, + "dir_vs" : + [ + [ + 536870912, 268435456, 134217728, 67108864, 33554432, 16777216, 8388608, 4194304, 2097152, 1048576, 524288, 262144, 131072, 65536, 32768, 16384, 8192, 4096, 2048, 1024, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1 + ] + ], + "md_c" : [ + [[1.0000000]] + ], + "md_vols" : [ + [[0.1900000]] + ], + "md_drifts" : [ + [[ -0.0276481070940405]] + ], + "md_starts" : [ + [3758.0500000000001819] + ], + "md_deterministic_values" : [ + [0.9997817434496459] + ], + "md_discounts" : [ + [0.9805494836196852] + ], + + "bb_inds" : [[1], + [0], + [0]], + "bb_data" : [[0.9889803798765787], + [0.0000000000000000], + [0.0000000000000000]] +} diff --git a/benchmarks/OptionPricing/datasets/small/output.json b/benchmarks/OptionPricing/datasets/small/output.json new file mode 100644 index 0000000..b96dce3 --- /dev/null +++ b/benchmarks/OptionPricing/datasets/small/output.json @@ -0,0 +1 @@ +[ 167.05571416613 ] diff --git a/OptionPricing/CppOpenCL/ContractDefs/LargeContract.cl b/benchmarks/OptionPricing/implementations/cpp_opencl/ContractDefs/LargeContract.cl similarity index 71% rename from OptionPricing/CppOpenCL/ContractDefs/LargeContract.cl rename to benchmarks/OptionPricing/implementations/cpp_opencl/ContractDefs/LargeContract.cl index 47be034..c491c9e 100644 --- a/OptionPricing/CppOpenCL/ContractDefs/LargeContract.cl +++ b/benchmarks/OptionPricing/implementations/cpp_opencl/ContractDefs/LargeContract.cl @@ -1,4 +1,4 @@ -#include "../includeC/Constants.h" +#include "Constants.h" #ifdef VECT_KERNEL #define underlyings(i,j) \ @@ -13,9 +13,9 @@ void trajectory_inner( const UINT num_cash_flows, // number of discounts const UINT model_ind, // the model index const UINT disct_index, // index of the discount - const REAL amount, // update with amount - __constant REAL* md_discts, - __local REAL* local_vhat + const real_t amount, // update with amount + __constant real_t* md_discts, + __local real_t* local_vhat ) { UINT index = model_ind * get_local_size(0); //block_size; local_vhat[index] += ( amount * md_discts[model_ind*num_cash_flows+disct_index] ); @@ -28,17 +28,17 @@ void payoffFunction( // BARRIER const UINT num_under, // the number of underlyings const UINT num_cash_flows, // the number of discounts const UINT num_pricers,// the number of deterministic procers - __constant REAL* md_discts, // [num_models][num_cash_flows] discounts - __constant REAL* md_detvals, // [num_models, num_det_pricers] pricers + __constant real_t* md_discts, // [num_models][num_cash_flows] discounts + __constant real_t* md_detvals, // [num_models, num_det_pricers] pricers #ifdef VECT_KERNEL - __global REAL* inst_traj, + __global real_t* inst_traj, #else - const REAL* inst_traj, // [num_dates, num_under] current trajectory + const real_t* inst_traj, // [num_dates, num_under] current trajectory #endif - __local REAL* vhat // [model_num] Accumulated per-model price + __local real_t* vhat // [model_num] Accumulated per-model price ) { bool goto_L40, x3309 = false; - REAL mult = 0.0; + real_t mult = 0.0; for(int i=0; (i<367 && (!x3309)); i++) { x3309 = x3309 || (underlyings(i,0) <= 2630.6349999999998) || @@ -55,11 +55,11 @@ void payoffFunction( // BARRIER mult = (goto_L40) ? 1.0 : 0.0; - const REAL min_amount = fmin( (underlyings(366,1) / 11840.) - 1., + const real_t min_amount = fmin( (underlyings(366,1) / 11840.) - 1., fmin( (underlyings(366,2) / 1200. ) - 1., (underlyings(366,0) / 3758.05) - 1. ) ); - const REAL amount = 1000. * ( 1. + mult*min_amount ) ; + const real_t amount = 1000. * ( 1. + mult*min_amount ) ; trajectory_inner( num_cash_flows, model_num, 1, amount, md_discts, vhat ); } diff --git a/OptionPricing/CppOpenCL/ContractDefs/MediumContract.cl b/benchmarks/OptionPricing/implementations/cpp_opencl/ContractDefs/MediumContract.cl similarity index 77% rename from OptionPricing/CppOpenCL/ContractDefs/MediumContract.cl rename to benchmarks/OptionPricing/implementations/cpp_opencl/ContractDefs/MediumContract.cl index 129971b..ca7866a 100644 --- a/OptionPricing/CppOpenCL/ContractDefs/MediumContract.cl +++ b/benchmarks/OptionPricing/implementations/cpp_opencl/ContractDefs/MediumContract.cl @@ -1,4 +1,4 @@ -#include "../includeC/Constants.h" +#include "Constants.h" #ifdef VECT_KERNEL #define underlyings(i,j) \ @@ -13,9 +13,9 @@ void trajectory_inner( const UINT num_cash_flows, // number of discounts const UINT model_ind, // the model index const UINT disct_index, // index of the discount - const REAL amount, // update with amount - __constant REAL* md_discts, - __local REAL* local_vhat + const real_t amount, // update with amount + __constant real_t* md_discts, + __local real_t* local_vhat ) { UINT index = model_ind * get_local_size(0); //block_size; local_vhat[index] += ( amount * md_discts[model_ind*num_cash_flows+disct_index] ); @@ -28,18 +28,18 @@ void payoffFunction( const UINT num_under, // the number of underlyings const UINT num_cash_flows, // the number of discounts const UINT num_pricers,// the number of deterministic procers - __constant REAL* md_discts, // [num_models][num_cash_flows] discounts - __constant REAL* md_detvals, // [num_models, num_det_pricers] pricers + __constant real_t* md_discts, // [num_models][num_cash_flows] discounts + __constant real_t* md_detvals, // [num_models, num_det_pricers] pricers #ifdef VECT_KERNEL - __global REAL* inst_traj, + __global real_t* inst_traj, #else - const REAL* inst_traj, // [num_dates, num_under] current trajectory + const real_t* inst_traj, // [num_dates, num_under] current trajectory #endif - __local REAL* vhat // [model_num] Accumulated per-model price + __local real_t* vhat // [model_num] Accumulated per-model price ) { - REAL x50; + real_t x50; UINT date; - REAL amount; + real_t amount; if ( 1. <= fmin( underlyings(0,1) / 11840., fmin( underlyings(0,2) / 1200., underlyings(0,0) / 3758.05 ) ) ) { //goto L21; diff --git a/OptionPricing/CppOpenCL/ContractDefs/SmallContract.cl b/benchmarks/OptionPricing/implementations/cpp_opencl/ContractDefs/SmallContract.cl similarity index 60% rename from OptionPricing/CppOpenCL/ContractDefs/SmallContract.cl rename to benchmarks/OptionPricing/implementations/cpp_opencl/ContractDefs/SmallContract.cl index f3b8b58..3d2dca7 100644 --- a/OptionPricing/CppOpenCL/ContractDefs/SmallContract.cl +++ b/benchmarks/OptionPricing/implementations/cpp_opencl/ContractDefs/SmallContract.cl @@ -1,4 +1,4 @@ -#include "../includeC/Constants.h" +#include "Constants.h" #ifdef VECT_KERNEL #define underlyings(i,j) \ @@ -13,9 +13,9 @@ void trajectory_inner( const UINT num_cash_flows, // number of discounts const UINT model_ind, // the model index const UINT disct_index, // index of the discount - const REAL amount, // update with amount - __constant REAL* md_discts, - __local REAL* local_vhat + const real_t amount, // update with amount + __constant real_t* md_discts, + __local real_t* local_vhat ) { UINT index = model_ind * get_local_size(0); //block_size; local_vhat[index] += ( amount * md_discts[model_ind*num_cash_flows+disct_index] ); @@ -28,17 +28,17 @@ void payoffFunction( // SIMPLE const UINT num_under, // the number of underlyings const UINT num_cash_flows, // the number of discounts const UINT num_pricers,// the number of deterministic procers - __constant REAL* md_discts, // [num_models][num_cash_flows] discounts - __constant REAL* md_detvals, // [num_models, num_det_pricers] pricers + __constant real_t* md_discts, // [num_models][num_cash_flows] discounts + __constant real_t* md_detvals, // [num_models, num_det_pricers] pricers #ifdef VECT_KERNEL - __global REAL* inst_traj, + __global real_t* inst_traj, #else - const REAL* inst_traj, // [num_dates, num_under] current trajectory + const real_t* inst_traj, // [num_dates, num_under] current trajectory #endif - __local REAL* vhat // [model_num] Accumulated per-model price + __local real_t* vhat // [model_num] Accumulated per-model price ) { - REAL amount = ((underlyings(0,0)) - 4000.0) * md_detvals[model_num*num_pricers]; - amount = fmax((REAL)0.0, amount); + real_t amount = ((underlyings(0,0)) - 4000.0) * md_detvals[model_num*num_pricers]; + amount = fmax((real_t)0.0, amount); trajectory_inner( num_cash_flows, model_num, 0, amount, md_discts, vhat ); } diff --git a/OptionPricing/CppOpenCL/GenPricing.cpp b/benchmarks/OptionPricing/implementations/cpp_opencl/GenPricing.cpp similarity index 72% rename from OptionPricing/CppOpenCL/GenPricing.cpp rename to benchmarks/OptionPricing/implementations/cpp_opencl/GenPricing.cpp index a810a57..51fe52f 100644 --- a/OptionPricing/CppOpenCL/GenPricing.cpp +++ b/benchmarks/OptionPricing/implementations/cpp_opencl/GenPricing.cpp @@ -1,7 +1,5 @@ #include "ParseInput.h" #include "StructGPU.h" -//#include "Contracts.h" -//#include /*****************************************************/ /*****************************************************/ @@ -28,7 +26,7 @@ run_GPUkernel ( size_t globalWorkSize[1]; // 1D var for Total # of work items size_t localWorkSize [1]; // 1D var for # of work items in the work group, e.g., { 128 } - REAL* glb_vhat = NULL; + real_t* glb_vhat = NULL; double* vhat_fin = (double*)malloc(ro_scal.num_models*sizeof(double)); @@ -43,17 +41,38 @@ run_GPUkernel ( const char* kernel_name = "GenericPricingVectUncoalesced"; #endif + char* kernel_filename = (char*) malloc(strlen(kernel_name) + + strlen(HIPERMARK_IMPLEMENTATION_DIR) + + 2); + sprintf(kernel_filename, "%s/%s", HIPERMARK_IMPLEMENTATION_DIR, kernel_name); + { // build the OpenCL program const char* preamble = makeGPUprogPreamble( ro_scal, kernel_type ); - char compile_opts[128]; - sprintf( compile_opts, "-D lgWARP=%d -D TILE=%d", lgWARP, TILE ); - build_for_GPU( cxGPUContext, cqCommandQueue, nDevice, + char compile_opts[1024]; +#ifdef _OPTIMIZATION_SOBOL_STRENGTH_RED_RECURR +#define STRENGTH_RED_FLAG "-D_OPTIMIZATION_SOBOL_STRENGTH_RED_RECURR" +#else +#define STRENGTH_RED_FLAG "" +#endif +#if (_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV == 0) +#define VECT_FLAG "-D_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV=0" +#elif (_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV == 1) +#define VECT_FLAG "-D_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV=1" +#elif (_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV == 2) +#define VECT_FLAG "-D_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV=2" +#endif + + sprintf( compile_opts, "-D lgWARP=%d -D TILE=%d -D%s %s -I%s/include -I%s/include -I%s", + lgWARP, TILE, + REAL_FLAG, + STRENGTH_RED_FLAG, + HIPERMARK_BENCHMARK_LIB_DIR, + HIPERMARK_LIB_DIR, + HIPERMARK_IMPLEMENTATION_DIR); + build_for_GPU( cxGPUContext, cqCommandQueue, nDevice, cdDevices, cpProgram, GPU_DEV_ID, - compile_opts, preamble, kernel_name ); + compile_opts, preamble, kernel_filename ); } - // we do not measure the just-in-time compilation time! - struct timeval t_start, t_end, t_diff; - gettimeofday(&t_start, NULL); { num_cores = discriminate_cost_model(ro_scal, cdDevices[GPU_DEV_ID], kernel_type); @@ -64,6 +83,21 @@ run_GPUkernel ( } oclLoopArrays ocl_arrs; + { // allocate RO scalars + cl_int ciErr2; + ocl_arrs.ro_scals = clCreateBuffer( + cxGPUContext, CL_MEM_READ_ONLY, sizeof(LoopROScalars), NULL, &ciErr2 + ); + ciErr2 |= clEnqueueWriteBuffer(cqCommandQueue[GPU_DEV_ID], ocl_arrs.ro_scals, CL_TRUE, 0, + sizeof(LoopROScalars), &ro_scal, 0, NULL, NULL); + oclCheckError(ciErr2, CL_SUCCESS); + clFinish(cqCommandQueue[GPU_DEV_ID]); + } + + // we do not measure the just-in-time compilation time! + struct timeval t_start, t_end, t_diff; + gettimeofday(&t_start, NULL); + if(kernel_type == PRIV) { // CALL THE PRIVATE KERNEL glb_vhat = oclAllocArrays_PrivKernel( ocl_arrs, cxGPUContext, cqCommandQueue[GPU_DEV_ID], @@ -115,14 +149,14 @@ run_GPUkernel ( ro_scal.sobol_count_ini = sob_ini_count; } - for(UINT ii = 0; iinum_under * ro_scal->num_dates; @@ -67,7 +67,7 @@ inline void mlfi_genmatrix_uniformGPUrec( __constant LoopROScalars* ro_scal, __constant int* sobol_v_dir, int* sobol_last_num_vec, - REAL* md_zd + real_t* md_zd ) { UINT ell, j; @@ -94,8 +94,8 @@ inline void mlfi_genmatrix_uniformGPUrec( (x*(x*(x*(x*(x*(x*(x*a7+a6)+a5)+a4)+a3)+a2)+a1)+a0)/ \ (x*(x*(x*(x*(x*(x*(x*b7+b6)+b5)+b4)+b3)+b2)+b1)+b0) -inline REAL small_case(REAL q) { - REAL x = 0.180625 - q * q; +inline real_t small_case(real_t q) { + real_t x = 0.180625 - q * q; return q * rat_eval( 3.387132872796366608, 133.14166789178437745, @@ -116,8 +116,8 @@ inline REAL small_case(REAL q) { 5226.495278852854561); } -inline REAL intermediate(REAL r) { - REAL x = r - 1.6; +inline real_t intermediate(real_t r) { + real_t x = r - 1.6; return rat_eval( 1.42343711074968357734, 4.6303378461565452959, @@ -138,8 +138,8 @@ inline REAL intermediate(REAL r) { 1.05075007164441684324e-9); } -inline REAL tail(REAL r) { - REAL x = r - 5.0; +inline real_t tail(real_t r) { + real_t x = r - 5.0; return rat_eval( 6.6579046435011037772, 5.4637849111641143699, @@ -160,17 +160,17 @@ inline REAL tail(REAL r) { 2.04426310338993978564e-15); } -inline void mlfi_ugaussian_Pinv_vector(REAL* p, UINT N, UINT logBLOCK) { +inline void mlfi_ugaussian_Pinv_vector(real_t* p, UINT N, UINT logBLOCK) { UINT i, UB = N; for ( i=0; i < UB; i++ ) { - REAL dp = p[i] - 0.5; + real_t dp = p[i] - 0.5; if (fabs(dp) <= 0.425) { p[i] = small_case(dp); } else { - REAL pp = (dp < 0.0) ? dp + 0.5 : (0.5 - dp); - REAL r = sqrt (- log(pp)); - REAL x = (r <= 5.0) ? intermediate(r) : tail(r); + real_t pp = (dp < 0.0) ? dp + 0.5 : (0.5 - dp); + real_t r = sqrt (- log(pp)); + real_t x = (r <= 5.0) ? intermediate(r) : tail(r); p[i] = (dp < 0.0) ? (0.0 - x) : x; } } @@ -183,15 +183,15 @@ inline void mlfi_ugaussian_Pinv_vector(REAL* p, UINT N, UINT logBLOCK) { inline void mlfi_brownianbridge_wiener_pathNoTransGPU( __constant LoopROScalars* ro_scal, __constant int* bb_inds, - __constant REAL* bb_data, - REAL* md_zd, - __local REAL* md_z, + __constant real_t* bb_data, + real_t* md_zd, + __local real_t* md_z, UINT block_size ) { UINT n, m, md_dim = ro_scal->num_under * block_size, nb_path_dates = ro_scal->num_dates; __constant int *bb_li, *bb_bi, *bb_ri; - __constant REAL *bb_rw, *bb_lw, *bb_sd; + __constant real_t *bb_rw, *bb_lw, *bb_sd; bb_bi = bb_inds; bb_li = bb_inds + nb_path_dates; @@ -211,8 +211,8 @@ inline void mlfi_brownianbridge_wiener_pathNoTransGPU( int k = bb_ri[i] - 1; int l = bb_bi[i] - 1; - REAL wk = md_z [k*md_dim+m]; - REAL zi = md_zd[i*ro_scal->num_under+n]; + real_t wk = md_z [k*md_dim+m]; + real_t zi = md_zd[i*ro_scal->num_under+n]; md_z[l*md_dim+m] = (j == -1) ? bb_rw[i] * wk + bb_sd[i] * zi : @@ -229,22 +229,22 @@ __kernel void payoffGPU( __constant UCHAR* fix_index, // RO Brownian Bridge __constant int* bb_ia, - __constant REAL* bb_coefs, + __constant real_t* bb_coefs, // RO MODELS DATA - __constant REAL* model_coefs, + __constant real_t* model_coefs, // WO (GLOBAL) VHAT - __global REAL* model_vhat, + __global real_t* model_vhat, // LOCAL ARRAYS - __local REAL* md_z, - //__local REAL* inst_trajWF, - __local REAL* vhat_local + __local real_t* md_z, + //__local real_t* inst_trajWF, + __local real_t* vhat_local ) { UINT k, block_size = get_local_size(0); const UINT ct_init = 0; //ro_scal->sobol_count_ini; int sobol_last_num_vec[15];//UINT[ro_scal->sobol_dim]; - REAL md_zd [15]; //[ro_scal->sobol_dim]; + real_t md_zd [15]; //[ro_scal->sobol_dim]; { // each local array is ajusted w.r.t. the local offset! UINT localID = get_local_id(0); @@ -310,9 +310,9 @@ __kernel void payoffGPU( UINT m, i, j, q, l; UINT num_under = ro_scal->num_under; UINT num_dates = ro_scal->num_dates; - REAL* trajWF = md_zd; + real_t* trajWF = md_zd; - __constant REAL *md_c, *md_vols, *md_drifts, *md_starts, *md_discts, *md_detvals; + __constant real_t *md_c, *md_vols, *md_drifts, *md_starts, *md_discts, *md_detvals; { UINT num_mods = ro_scal->num_models; UINT dim_paths = num_under*num_dates; @@ -328,9 +328,9 @@ __kernel void payoffGPU( for (m = 0; m < ro_scal->num_models; m++) { for (j = 0; j < num_under; j++) { - REAL accum = md_starts[j]; + real_t accum = md_starts[j]; for( i = 0; i < num_dates; i ++) { - REAL temp = 0.0; + real_t temp = 0.0; q = num_under*i + j; for (l = 0; l <= j; l++) diff --git a/OptionPricing/CppOpenCL/GenericPricingVectOpt.cl b/benchmarks/OptionPricing/implementations/cpp_opencl/GenericPricingVectOpt.cl similarity index 89% rename from OptionPricing/CppOpenCL/GenericPricingVectOpt.cl rename to benchmarks/OptionPricing/implementations/cpp_opencl/GenericPricingVectOpt.cl index fd82232..b716bab 100644 --- a/OptionPricing/CppOpenCL/GenericPricingVectOpt.cl +++ b/benchmarks/OptionPricing/implementations/cpp_opencl/GenericPricingVectOpt.cl @@ -2,9 +2,9 @@ /************* MACROS ***************/ /************************************/ -#define TYPE REAL +#define TYPE real_t #define FLAG uchar -#include "../../include/Utilities.cl" +#include "Utilities.cl" #define DUMMY 1 @@ -18,7 +18,7 @@ __kernel void mlfi_genmatrix_uniform2 ( __constant LoopROScalars* ro_scal, __constant UCHAR* sobol_fix_ind, __global int* sobol_v_dir, - __global REAL* md_zd + __global real_t* md_zd ) { UINT i, j, k; UINT seq_count = ( get_global_id (0) << ro_scal->log_chunk ); @@ -32,7 +32,7 @@ __kernel void mlfi_genmatrix_uniform2 ( md_zd = md_zd + ( ( (get_global_id (0) >> lgWARP) << (ro_scal->log_chunk+lgWARP) )*sobol_dim + (get_global_id(0) & (WARP-1)) ); - __global REAL* md_zd_tmp = md_zd; + __global real_t* md_zd_tmp = md_zd; UINT UB = (seq_count + (1 << ro_scal->log_chunk) < ro_scal->num_gpuits) ? seq_count + (1 << ro_scal->log_chunk) : ro_scal->num_gpuits ; @@ -122,7 +122,7 @@ __kernel void mlfi_genmatrix_uniform2 ( __constant LoopROScalars* ro_scal, __constant UCHAR* sobol_fix_ind, __global int* sobol_v_dir, - __global REAL* md_zd + __global real_t* md_zd ) { UINT i, j, k, m; UINT seq_count = ( get_global_id (0) << ro_scal->log_chunk ); @@ -134,7 +134,7 @@ __kernel void mlfi_genmatrix_uniform2 ( md_zd = md_zd + ( ( (get_global_id (0) >> lgWARP) << (ro_scal->log_chunk+lgWARP) )*sobol_dim + (get_global_id(0) & (WARP-1)) ); - __global REAL* md_zd_tmp = md_zd; + __global real_t* md_zd_tmp = md_zd; UINT UB = (seq_count + (1 << ro_scal->log_chunk) < ro_scal->num_gpuits) ? seq_count + (1 << ro_scal->log_chunk) : ro_scal->num_gpuits ; @@ -185,8 +185,8 @@ __kernel void mlfi_genmatrix_uniform2 ( (x*(x*(x*(x*(x*(x*(x*a7+a6)+a5)+a4)+a3)+a2)+a1)+a0)/ \ (x*(x*(x*(x*(x*(x*(x*b7+b6)+b5)+b4)+b3)+b2)+b1)+b0) -inline REAL small_case(REAL q) { - REAL x = 0.180625 - q * q; +inline real_t small_case(real_t q) { + real_t x = 0.180625 - q * q; return q * rat_eval( 3.387132872796366608, 133.14166789178437745, @@ -207,8 +207,8 @@ inline REAL small_case(REAL q) { 5226.495278852854561); } -inline REAL intermediate(REAL r) { - REAL x = r - 1.6; +inline real_t intermediate(real_t r) { + real_t x = r - 1.6; return rat_eval( 1.42343711074968357734, 4.6303378461565452959, @@ -229,8 +229,8 @@ inline REAL intermediate(REAL r) { 1.05075007164441684324e-9); } -inline REAL tail(REAL r) { - REAL x = r - 5.0; +inline real_t tail(real_t r) { + real_t x = r - 5.0; return rat_eval( 6.6579046435011037772, 5.4637849111641143699, @@ -252,7 +252,7 @@ inline REAL tail(REAL r) { } __kernel void mlfi_ugaussian_Pinv_vector1( - __constant LoopROScalars* ro_scal, __global REAL* p + __constant LoopROScalars* ro_scal, __global real_t* p ) { UINT sobol_dim = ro_scal->num_under * ro_scal->num_dates; UINT id = get_global_id(0), i, UB; @@ -265,13 +265,13 @@ __kernel void mlfi_ugaussian_Pinv_vector1( UB *= sobol_dim; for( id=0, i=0; id < UB; i+=WARP, id++) { - REAL dp = p[i] - 0.5; + real_t dp = p[i] - 0.5; if (fabs(dp) <= 0.425) { p[i] = small_case(dp); } else { - REAL pp = (dp < 0.0) ? dp + 0.5 : (0.5 - dp); - REAL r = sqrt (- log(pp)); - REAL x = (r <= 5.0) ? intermediate(r) : tail(r); + real_t pp = (dp < 0.0) ? dp + 0.5 : (0.5 - dp); + real_t r = sqrt (- log(pp)); + real_t x = (r <= 5.0) ? intermediate(r) : tail(r); p[i] = (dp < 0.0) ? (0.0 - x) : x; } } @@ -284,14 +284,14 @@ __kernel void mlfi_ugaussian_Pinv_vector1( __kernel void mlfi_brownianbridge_wiener_path1( __constant LoopROScalars* ro_scal, __constant int* bb_inds, - __constant REAL* bb_data, - __global REAL* md_zd, - __global REAL* md_z + __constant real_t* bb_data, + __global real_t* md_zd, + __global real_t* md_z ) { __constant int *bb_li, *bb_bi, *bb_ri; - __constant REAL *bb_rw, *bb_lw, *bb_sd; + __constant real_t *bb_rw, *bb_lw, *bb_sd; - ULONG cur_it = get_global_id (0) << ro_scal->log_chunk; + unsigned long cur_it = get_global_id (0) << ro_scal->log_chunk; UINT m, i, md_dim = ro_scal->num_under << lgWARP, nb_path_dates = ro_scal->num_dates; UINT sobol_dim = ro_scal->num_under * nb_path_dates; @@ -321,8 +321,8 @@ __kernel void mlfi_brownianbridge_wiener_path1( int k = bb_ri[i] - 1; int l = bb_bi[i] - 1; - REAL wk = md_z [k*md_dim+m]; - REAL zi = md_zd[i*md_dim+m]; + real_t wk = md_z [k*md_dim+m]; + real_t zi = md_zd[i*md_dim+m]; md_z[l*md_dim+m] = (j == -1) ? bb_rw[i] * wk + bb_sd[i] * zi : @@ -342,27 +342,27 @@ __kernel void mlfi_brownianbridge_wiener_path1( void trajectory_contract( UINT model_num, __constant LoopROScalars* ro_scal, - __constant REAL* pc_coefs, - __global REAL* inst_traj, - __global REAL* vhat + __constant real_t* pc_coefs, + __global real_t* inst_traj, + __global real_t* vhat ); __kernel void mlfi_comp_traj1( __constant LoopROScalars* ro_scal, // RO SCALARS // RO MD INSTANCE DATA - __constant REAL* model_coefs, + __constant real_t* model_coefs, // LOCAL SPACE 2 * ro_scal->num_under PER THREAD! - __local REAL* buff, + __local real_t* buff, // RO (GLOBAL) MD_Z - __global REAL* md_z, + __global real_t* md_z, // WO (GLOBAL) traj - __global REAL* trajWF + __global real_t* trajWF ) { UINT offset; UINT dim = ro_scal->num_under; UINT dim_sq = dim*dim; UINT dim_paths = dim*ro_scal->num_dates; - ULONG cur_it = get_global_id (0) << ro_scal->log_chunk; + unsigned long cur_it = get_global_id (0) << ro_scal->log_chunk; UINT UB = ( cur_it+(1<log_chunk) < ro_scal->num_gpuits) ? cur_it+(1<log_chunk) : ro_scal->num_gpuits ; @@ -391,7 +391,7 @@ __kernel void mlfi_comp_traj1( } - __constant REAL *md_c, *md_vols, *md_drifts, *md_starts, *md_discts, *md_detvals; + __constant real_t *md_c, *md_vols, *md_drifts, *md_starts, *md_discts, *md_detvals; { UINT num_mods = ro_scal->num_models; UINT offset = 0; @@ -416,7 +416,7 @@ __kernel void mlfi_comp_traj1( ind = dim*i; for (j = 0; j < dim; j++) { - REAL temp = 0.0; + real_t temp = 0.0; q = dim * i + j; for (l = 0; l <= j; l++) temp += md_c[dim * j + l] * buff[l<num_under; UINT dim_sq = dim*dim; UINT dim_paths = dim*ro_scal->num_dates; - ULONG cur_it = get_global_id (0) << ro_scal->log_chunk; + unsigned long cur_it = get_global_id (0) << ro_scal->log_chunk; UINT UB = ( cur_it+(1<log_chunk) < ro_scal->num_gpuits ) ? cur_it+(1<log_chunk) : ro_scal->num_gpuits ; @@ -477,7 +477,7 @@ __kernel void mlfi_comp_traj_unopt( } } - __constant REAL *md_c, *md_vols, *md_drifts, *md_starts, *md_discts, *md_detvals; + __constant real_t *md_c, *md_vols, *md_drifts, *md_starts, *md_discts, *md_detvals; { UINT num_mods = ro_scal->num_models; UINT offset = 0; @@ -491,7 +491,7 @@ __kernel void mlfi_comp_traj_unopt( for (i = 0; i < ro_scal->num_dates; i++) { UINT ind = dim*i; for (j = 0; j < dim; j++) { - REAL temp = 0.0; + real_t temp = 0.0; for (l = 0; l <= j; l++) { temp += md_c[dim * j + l] * md_z[ (ind + l) << lgWARP ]; @@ -519,17 +519,17 @@ __kernel void mlfi_comp_traj_unopt( __kernel void mlfi_reduction_step1( __constant LoopROScalars* ro_scal, // RO SCALARS // RO MD INSTANCE DATA - __constant REAL* model_coefs, + __constant real_t* model_coefs, // RO (GLOBAL) traj - __global REAL* inst_trajWF, + __global real_t* inst_trajWF, // WF (GLOBAL) traj - __global REAL* model_vhat, - __local REAL* vhat_local + __global real_t* model_vhat, + __local real_t* vhat_local ) { UINT j; uint block_size = get_local_size(0); int sobol_dim = ro_scal->num_under * ro_scal->num_dates; - ULONG cur_it = get_global_id (0) << ro_scal->log_chunk; + unsigned long cur_it = get_global_id (0) << ro_scal->log_chunk; UINT UB = ( cur_it + (1<log_chunk) < ro_scal->num_gpuits) ? cur_it + (1<log_chunk) : ro_scal->num_gpuits ; @@ -546,8 +546,8 @@ __kernel void mlfi_reduction_step1( vhat_local[j] = 0.0; } - __constant REAL *md_discts; - __constant REAL *md_detvals; + __constant real_t *md_discts; + __constant real_t *md_detvals; { // compute from model_coefs int offset; offset = ro_scal->num_under * ( ro_scal->num_under + 1) + 2 * sobol_dim; diff --git a/OptionPricing/CppOpenCL/GenericPricingVectUncoalesced.cl b/benchmarks/OptionPricing/implementations/cpp_opencl/GenericPricingVectUncoalesced.cl similarity index 85% rename from OptionPricing/CppOpenCL/GenericPricingVectUncoalesced.cl rename to benchmarks/OptionPricing/implementations/cpp_opencl/GenericPricingVectUncoalesced.cl index 550102c..5c23d37 100644 --- a/OptionPricing/CppOpenCL/GenericPricingVectUncoalesced.cl +++ b/benchmarks/OptionPricing/implementations/cpp_opencl/GenericPricingVectUncoalesced.cl @@ -2,9 +2,9 @@ /************* MACROS ***************/ /************************************/ -#define TYPE REAL +#define TYPE real_t #define FLAG uchar -#include "../../include/Utilities.cl" +#include "Utilities.cl" #define DUMMY 1 @@ -30,14 +30,14 @@ __kernel void mlfi_genmatrix_uniform2 ( __constant LoopROScalars* ro_scal, __constant UCHAR* sobol_fix_ind, __global int* sobol_v_dir, - __global REAL* md_zd + __global real_t* md_zd ) { UINT i, j, k; UINT seq_count = ( get_global_id (0) << ro_scal->log_chunk ); UINT sobol_dim = ro_scal->num_under * ro_scal->num_dates; md_zd = md_zd + (get_global_id (0) << ro_scal->log_chunk)*sobol_dim; - __global REAL* md_zd_tmp = md_zd; + __global real_t* md_zd_tmp = md_zd; //UINT UB = min(seq_count + (1 << ro_scal->log_chunk), ro_scal->num_gpuits); UINT UB = (seq_count + (1 << ro_scal->log_chunk) < ro_scal->num_gpuits) ? @@ -98,8 +98,8 @@ __kernel void mlfi_genmatrix_uniform2 ( (x*(x*(x*(x*(x*(x*(x*a7+a6)+a5)+a4)+a3)+a2)+a1)+a0)/ \ (x*(x*(x*(x*(x*(x*(x*b7+b6)+b5)+b4)+b3)+b2)+b1)+b0) -inline REAL small_case(REAL q) { - REAL x = 0.180625 - q * q; +inline real_t small_case(real_t q) { + real_t x = 0.180625 - q * q; return q * rat_eval( 3.387132872796366608, 133.14166789178437745, @@ -120,8 +120,8 @@ inline REAL small_case(REAL q) { 5226.495278852854561); } -inline REAL intermediate(REAL r) { - REAL x = r - 1.6; +inline real_t intermediate(real_t r) { + real_t x = r - 1.6; return rat_eval( 1.42343711074968357734, 4.6303378461565452959, @@ -142,8 +142,8 @@ inline REAL intermediate(REAL r) { 1.05075007164441684324e-9); } -inline REAL tail(REAL r) { - REAL x = r - 5.0; +inline real_t tail(real_t r) { + real_t x = r - 5.0; return rat_eval( 6.6579046435011037772, 5.4637849111641143699, @@ -166,8 +166,8 @@ inline REAL tail(REAL r) { __kernel void mlfi_ugaussian_Pinv_vector1( // UNTILED VERSION - __constant LoopROScalars* ro_scal, __global REAL* p - //__global REAL* p , __constant LoopROScalars* ro_scal, __local REAL* tmp_p + __constant LoopROScalars* ro_scal, __global real_t* p + //__global real_t* p , __constant LoopROScalars* ro_scal, __local real_t* tmp_p ) { UINT sobol_dim = ro_scal->num_under * ro_scal->num_dates; UINT i, UB, id = get_global_id(0) << ro_scal->log_chunk; @@ -178,13 +178,13 @@ __kernel void mlfi_ugaussian_Pinv_vector1( // UNTILED VERSION UB *= sobol_dim; for( i=0; i < UB; i++ ) { - REAL dp = p[i] - 0.5; + real_t dp = p[i] - 0.5; if (fabs(dp) <= 0.425) { p[i] = small_case(dp); } else { - REAL pp = (dp < 0.0) ? p[i] : (1.0 - p[i]); - REAL r = sqrt (- log(pp)); - REAL x = (r <= 5.0) ? intermediate(r) : tail(r); + real_t pp = (dp < 0.0) ? p[i] : (1.0 - p[i]); + real_t r = sqrt (- log(pp)); + real_t x = (r <= 5.0) ? intermediate(r) : tail(r); p[i] = (dp < 0.0) ? (0.0 - x) : x; } } @@ -197,14 +197,14 @@ __kernel void mlfi_ugaussian_Pinv_vector1( // UNTILED VERSION __kernel void mlfi_brownianbridge_wiener_path1( __constant LoopROScalars* ro_scal, __constant int* bb_inds, - __constant REAL* bb_data, - __global REAL* md_zd, - __global REAL* md_z + __constant real_t* bb_data, + __global real_t* md_zd, + __global real_t* md_z ) { __constant int *bb_li, *bb_bi, *bb_ri; - __constant REAL *bb_rw, *bb_lw, *bb_sd; + __constant real_t *bb_rw, *bb_lw, *bb_sd; - ULONG cur_it = get_global_id (0) << ro_scal->log_chunk; + unsigned long cur_it = get_global_id (0) << ro_scal->log_chunk; UINT m, i, md_dim = ro_scal->num_under, nb_path_dates = ro_scal->num_dates; UINT sobol_dim = ro_scal->num_under * nb_path_dates; @@ -236,8 +236,8 @@ __kernel void mlfi_brownianbridge_wiener_path1( int k = bb_ri[i] - 1; int l = bb_bi[i] - 1; - REAL wk = md_z [k*md_dim+m]; - REAL zi = md_zd[i*md_dim+m]; + real_t wk = md_z [k*md_dim+m]; + real_t zi = md_zd[i*md_dim+m]; md_z[l*md_dim+m] = (j == -1) ? bb_rw[i] * wk + bb_sd[i] * zi : @@ -257,28 +257,28 @@ __kernel void mlfi_brownianbridge_wiener_path1( void trajectory_contract( UINT model_num, __constant LoopROScalars* ro_scal, - __constant REAL* pc_coefs, - __global REAL* inst_traj, - __global REAL* vhat + __constant real_t* pc_coefs, + __global real_t* inst_traj, + __global real_t* vhat ); __kernel void mlfi_comp_traj1( __constant LoopROScalars* ro_scal, // RO SCALARS // RO MD INSTANCE DATA - __constant REAL* model_coefs, + __constant real_t* model_coefs, // RO MODEL ATTRIBUTES -// __constant REAL* pc_coefs, -// __local REAL* buff, +// __constant real_t* pc_coefs, +// __local real_t* buff, // RO (GLOBAL) MD_Z - __global REAL* md_z, + __global real_t* md_z, // WO (GLOBAL) traj - __global REAL* trajWF + __global real_t* trajWF ) { UINT dim = ro_scal->num_under; UINT dim_sq = dim*dim; UINT dim_paths = dim*ro_scal->num_dates; - ULONG cur_it = get_global_id (0) << ro_scal->log_chunk; + unsigned long cur_it = get_global_id (0) << ro_scal->log_chunk; UINT UB = (cur_it+(1<log_chunk) < ro_scal->num_gpuits) ? cur_it + (1<log_chunk) : ro_scal->num_gpuits; @@ -295,7 +295,7 @@ __kernel void mlfi_comp_traj1( } } - __constant REAL *c, *vols, *drift, *trajRO; + __constant real_t *c, *vols, *drift, *trajRO; { UINT num_mods = ro_scal->num_models; UINT offset = 0; @@ -310,15 +310,15 @@ __kernel void mlfi_comp_traj1( -// __constant REAL* c = inst_coefs + ( ro_scal->inst_c_beg + m*dim_sq ); -// __constant REAL* vols = inst_coefs + ( ro_scal->inst_vols_beg + m*dim_paths ); -// __constant REAL* drift = inst_coefs + ( ro_scal->inst_drifts_beg + m*dim_paths ); -// __constant REAL* trajRO= inst_coefs + ( ro_scal->inst_trajRO_beg + m*dim ); +// __constant real_t* c = inst_coefs + ( ro_scal->inst_c_beg + m*dim_sq ); +// __constant real_t* vols = inst_coefs + ( ro_scal->inst_vols_beg + m*dim_paths ); +// __constant real_t* drift = inst_coefs + ( ro_scal->inst_drifts_beg + m*dim_paths ); +// __constant real_t* trajRO= inst_coefs + ( ro_scal->inst_trajRO_beg + m*dim ); for (i = 0; i < ro_scal->num_dates; i++) { UINT ind = dim*i; for (j = 0; j < dim; j++) { - REAL temp = 0.0; + real_t temp = 0.0; for (l = 0; l <= j; l++) { temp += c[dim * j + l] * md_z[ (ind + l) ]; @@ -348,19 +348,19 @@ __kernel void mlfi_comp_traj1( __kernel void mlfi_reduction_step1( __constant LoopROScalars* ro_scal, // RO SCALARS // RO MD INSTANCE DATA - __constant REAL* inst_coefs, + __constant real_t* inst_coefs, // RO MODEL ATTRIBUTES -// __constant REAL* pc_coefs, +// __constant real_t* pc_coefs, // RO (GLOBAL) traj - __global REAL* inst_trajWF, + __global real_t* inst_trajWF, // WF (GLOBAL) traj - __global REAL* model_vhat, - __local REAL* vhat_local + __global real_t* model_vhat, + __local real_t* vhat_local ) { UINT j; uint block_size = get_local_size(0); int sobol_dim = ro_scal->num_under * ro_scal->num_dates; - ULONG cur_it = get_global_id (0) << ro_scal->log_chunk; + unsigned long cur_it = get_global_id (0) << ro_scal->log_chunk; //UINT UB = min(cur_it + (1<log_chunk), ro_scal->num_gpuits); UINT UB = ( cur_it + (1<log_chunk) < ro_scal->num_gpuits) ? @@ -389,8 +389,8 @@ __kernel void mlfi_reduction_step1( } #endif - __constant REAL *md_discts; - __constant REAL *md_detvals; + __constant real_t *md_discts; + __constant real_t *md_detvals; { // compute from model_coefs int offset; offset = ro_scal->num_under * ( ro_scal->num_under + 1) + 2 * sobol_dim; @@ -400,7 +400,7 @@ __kernel void mlfi_reduction_step1( } for( ; cur_it < UB; cur_it++ ) { - //__global REAL* vhat_loc = vhat; + //__global real_t* vhat_loc = vhat; for (j = 0; j < ro_scal->num_models; j++) { payoffFunction( j, ro_scal->num_under, @@ -435,7 +435,7 @@ __kernel void mlfi_reduction_step1( #if 0 for( ; cur_it < UB; cur_it++ ) { - __global REAL* vhat_loc = vhat; + __global real_t* vhat_loc = vhat; for (j = 0; j < ro_scal->num_models; j++) { trajectory_contract( j, ro_scal, pc_coefs, inst_trajWF, vhat_loc ); inst_trajWF += ro_scal->sobol_dim; @@ -481,10 +481,10 @@ __kernel void mlfi_reduction_step1( inline void trajectory_inner( UINT model_num, __constant LoopROScalars* ro_scal, - __constant REAL* model_discounts, - __global REAL* vhat, + __constant real_t* model_discounts, + __global real_t* vhat, const UINT contract_number, - const REAL amount, + const real_t amount, const UINT date_index ) { vhat[(contract_number << lgWARP)] += amount * model_discounts[model_num*ro_scal->num_cash_flows+date_index]; diff --git a/benchmarks/OptionPricing/implementations/cpp_opencl/Makefile b/benchmarks/OptionPricing/implementations/cpp_opencl/Makefile new file mode 100644 index 0000000..20c916a --- /dev/null +++ b/benchmarks/OptionPricing/implementations/cpp_opencl/Makefile @@ -0,0 +1,58 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +# Default to double if nothing else defined. +HIPERMARK_CONFIG_REAL_TYPE ?= double + +include $(HIPERMARK_LIB_DIR)/setup.mk +include $(HIPERMARK_LIB_DIR)/setup_real_type.mk + +# FIXME - this should not even exist! +include $(HIPERMARK_LIB_DIR)/platform.mk + +# Handle Strength reduction and vectorization +ifeq ($(HIPERMARK_CONFIG_STRENGTH_REDUCTION),on) + CXXFLAGS += -D_OPTIMIZATION_SOBOL_STRENGTH_RED_RECURR +endif +ifeq ($(HIPERMARK_CONFIG_VECTORIZATION),auto) + CXXFLAGS += -D_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV=0 +else ifeq ($(HIPERMARK_CONFIG_VECTORIZATION),off) + CXXFLAGS += -D_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV=2 +else ifeq ($(HIPERMARK_CONFIG_VECTORIZATION),on) + CXXFLAGS += -D_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV=1 +endif + +ifeq ($(HIPERMARK_CONFIG_MEM_COALESCING),on) + CXXFLAGS += -D_OPTIMIZATION_MEM_COALES_ON +endif + +INCLUDES += -I$(HIPERMARK_BENCHMARK_LIB_DIR)/include +INCLUDES += -I$(HIPERMARK_LIB_DIR)/include + +GPU_OPTS = -D lgWARP=$(GPU_LG_WARP) -D GPU_DEV_ID=$(GPU_DEVICE_ID) \ + -D GPU_LOC_MEM=$(GPU_LOCAL_MEM) -D GPU_CONST_MEM=$(GPU_CONST_MEM) \ + -D GPU_REG_MEM=$(GPU_REG_MEM) -D GPU_GLB_MEM=$(GPU_DEVICE_MEM) \ + -D GPU_TILE=$(GPU_LOCAL_MEM_PER_TH) -D GPU_CORES=$(GPU_NUM_CORES) \ + -D CURR_DIR_PATH='"$(MAKE_DIR)"' + +SOURCES_CPP =GenPricing.cpp +HELPERS =$(HIPERMARK_BENCHMARK_LIB_DIR)/include/ParseInput.h +OBJECTS =GenPricing.o +EXECUTABLE =GenPricing + +default: $(EXECUTABLE) + +%.o: $(HIPERMARK_IMPLEMENTATION_DIR)/%.cpp $(HELPERS) + $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -c -o $@ $< + +$(EXECUTABLE): $(OBJECTS) + $(CXX) $(CXXFLAGS) $(GPU_OPTS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) $(LIB) + +clean: + rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) + @# clean nVidia compiler cache + rm -rf $(HOME)/.nv/ComputeCache/* + +HIPERMARK_DATA_FIELDS=contract_number monte_carlo_iterations num_path_dates num_underlyings num_models num_bits dir_vs md_c md_vols md_drifts md_starts md_deterministic_values md_discounts bb_inds bb_data +HIPERMARK_RUN_ENVIRONMENT= +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/OptionPricing/CppOpenCL/StructGPU.h b/benchmarks/OptionPricing/implementations/cpp_opencl/StructGPU.h similarity index 92% rename from OptionPricing/CppOpenCL/StructGPU.h rename to benchmarks/OptionPricing/implementations/cpp_opencl/StructGPU.h index 42f5dd5..b7624d5 100644 --- a/OptionPricing/CppOpenCL/StructGPU.h +++ b/benchmarks/OptionPricing/implementations/cpp_opencl/StructGPU.h @@ -4,7 +4,7 @@ #include "Optimizations.h" #include "SDK_stub.h" -#if (_OPTIMIZATION_USE_FLOATS) +#if REAL_IS_FLOAT #define TILE GPU_TILE #else #define TILE GPU_TILE/2 @@ -24,20 +24,20 @@ struct oclLoopArrays { /* Brownian Bridge data RO */ cl_mem bb_inds; // UINT[3][num_dates] - cl_mem bb_data; // REAL[3][num_dates] + cl_mem bb_data; // real_t[3][num_dates] /* MD instance data; RO */ cl_mem md_c; // Includes all arrays bellow: -// cl_mem md_c // RO; REAL[num_models][num_under^2] -// cl_mem md_vols; // RO; REAL[num_models][num_under*num_dates] -// cl_mem md_drifts; // RO; REAL[num_models][num_under*num_dates] -// cl_mem md_starts; // RO; REAL[num_models][num_under] -// cl_mem md_discts; // REAL[num_models][num_cash_flows ] -// cl_mem md_detvals; // REAL[num_models][num_det_pricers] +// cl_mem md_c // RO; real_t[num_models][num_under^2] +// cl_mem md_vols; // RO; real_t[num_models][num_under*num_dates] +// cl_mem md_drifts; // RO; real_t[num_models][num_under*num_dates] +// cl_mem md_starts; // RO; real_t[num_models][num_under] +// cl_mem md_discts; // real_t[num_models][num_cash_flows ] +// cl_mem md_detvals; // real_t[num_models][num_det_pricers] /* FOR VECTORIZED VERSION */ - cl_mem md_zd; // RW: REAL[num_gpuits]x[num_under*num_dates] - cl_mem md_z; // RW: REAL[num_gpuits]x[num_models]x[num_under*num_dates] + cl_mem md_zd; // RW: real_t[num_gpuits]x[num_under*num_dates] + cl_mem md_z; // RW: real_t[num_gpuits]x[num_models]x[num_under*num_dates] /* global array to be reduced on CPU; WO */ cl_mem model_vhat; // WO; ~ [num_models]x[num_contracts]x[num_iter/(chunk*BLOCK)] @@ -90,6 +90,10 @@ enum GPU_KERNEL { PRIV, VECT }; GPU_KERNEL priv_or_vect_kernel(const LoopROScalars& ro_scal) { +#ifndef _OPTIMIZATION_MEM_COALES_ON + return VECT; +#endif + #if (_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV == 1) return VECT; #elif (_OPTIMIZATION_COST_MODEL_OR_FORCE_VECT_OR_FORCE_PRIV == 2) @@ -167,7 +171,7 @@ discriminate_cost_model( LoopROScalars& ro_scal, cl_device_id device, const GPU_ // check if there is enough memory UINT perit_mem_size = size_vct*( ro_scal.num_models + 1 ) + ro_scal.num_models; - perit_mem_size *= sizeof(REAL); + perit_mem_size *= sizeof(real_t); UINT max_mc_iter_num = ( (glob_mem_size * 3)/4 ) / perit_mem_size; @@ -226,7 +230,7 @@ discriminate_cost_model( LoopROScalars& ro_scal, cl_device_id device, const GPU_ /***running the Private Kernels***/ /*********************************/ -REAL* +real_t* oclAllocArrays_PrivKernel ( oclLoopArrays& ocl_arrs, cl_context cxGPUContext, @@ -239,8 +243,10 @@ oclAllocArrays_PrivKernel ( ) { cl_int ciErr2; size_t cur_size; - REAL* glb_vhat = NULL; + real_t* glb_vhat = NULL; + ciErr = 0; +#if 0 { // 1. RO scalars cur_size = sizeof(LoopROScalars); ocl_arrs.ro_scals = clCreateBuffer( @@ -251,6 +257,7 @@ oclAllocArrays_PrivKernel ( ciErr |= clEnqueueWriteBuffer(cqCommandQueue, ocl_arrs.ro_scals, CL_TRUE, 0, cur_size, &ro_scals, 0, NULL, NULL); } +#endif { // 2. Sobol RO Arrays const SobolArrays& cpu_arrs = sob_arrs; @@ -269,7 +276,7 @@ oclAllocArrays_PrivKernel ( cur_size = 3*ro_scals.num_dates*sizeof(UINT); CREATE_AND_ENQUEUE_RO_CL_BUFFER(bb_inds); - cur_size = 3*ro_scals.num_dates*sizeof(REAL); + cur_size = 3*ro_scals.num_dates*sizeof(real_t); CREATE_AND_ENQUEUE_RO_CL_BUFFER(bb_data); } @@ -278,7 +285,7 @@ oclAllocArrays_PrivKernel ( cur_size = ro_scals.num_under * ( ro_scals.num_under + 2*ro_scals.num_dates + 1); cur_size += ro_scals.num_cash_flows + ro_scals.num_det_pricers; - cur_size *= ro_scals.num_models * sizeof(REAL); + cur_size *= ro_scals.num_models * sizeof(real_t); CREATE_AND_ENQUEUE_RO_CL_BUFFER(md_c); } @@ -286,9 +293,9 @@ oclAllocArrays_PrivKernel ( { // 5. Finally, the WO Partial Result //red_sz = getGlobalRedArrSize( ro_scal->mc_iter_num, ro_scal->CHUNK*ro_scal->BLOCK ); cur_size = getWorkSize(ro_scals.num_gpuits, ro_scals.chunk, ro_scals.BLOCK) / ro_scals.BLOCK; - cur_size *= ro_scals.num_models * sizeof(REAL); + cur_size *= ro_scals.num_models * sizeof(real_t); - glb_vhat = (REAL*)malloc(cur_size); + glb_vhat = (real_t*)malloc(cur_size); ocl_arrs.model_vhat = clCreateBuffer( cxGPUContext, CL_MEM_WRITE_ONLY | CL_MEM_USE_HOST_PTR, cur_size, glb_vhat, &ciErr2 @@ -309,7 +316,7 @@ oclAllocArrays_PrivKernel ( void runGPU_PRIV( const LoopROScalars& ro_scals, - REAL* glb_vhat, + real_t* glb_vhat, oclLoopArrays& dev_arr, cl_command_queue& cqCommandQueue, cl_program& cpProgram, @@ -320,7 +327,7 @@ runGPU_PRIV( cl_int ciErr1; size_t counter = 0, priv_sz = 0; // ro_scals - const int PRIV_MULT = sizeof(REAL)*ro_scals.BLOCK; + const int PRIV_MULT = sizeof(real_t)*ro_scals.BLOCK; ckGenPricing = clCreateKernel(cpProgram, "payoffGPU", &ciErr1); oclCheckError(ciErr1, CL_SUCCESS); @@ -352,7 +359,7 @@ runGPU_PRIV( oclCheckError(ciErr1, CL_SUCCESS); - clFinish(cqCommandQueue); + //clFinish(cqCommandQueue); struct timeval t_start, t_end, t_diff; unsigned long long elapsed; gettimeofday(&t_start, NULL); @@ -370,7 +377,7 @@ runGPU_PRIV( gettimeofday(&t_start, NULL); // 9. FINALLY, WRITE BACK!!! // - priv_sz = (globalWorkSize[0]/ro_scals.BLOCK)*ro_scals.num_models*sizeof(REAL); + priv_sz = (globalWorkSize[0]/ro_scals.BLOCK)*ro_scals.num_models*sizeof(real_t); ciErr1 |= clEnqueueReadBuffer(cqCommandQueue, dev_arr.model_vhat, CL_TRUE, 0, priv_sz, glb_vhat, 0, NULL, NULL); @@ -386,7 +393,7 @@ runGPU_PRIV( } -void reduceVHAT_CPU(const LoopROScalars& ro_scals, REAL* vhat, double* cpu_vhat ) { +void reduceVHAT_CPU(const LoopROScalars& ro_scals, real_t* vhat, double* cpu_vhat ) { // final reduction on CPU!!! UINT SZ = getWorkSize(ro_scals.num_gpuits, ro_scals.chunk, ro_scals.BLOCK) / ro_scals.BLOCK; @@ -408,7 +415,7 @@ void reduceVHAT_CPU(const LoopROScalars& ro_scals, REAL* vhat, double* cpu_vhat /***** VECTORIZED KERNEL *****/ /*****************************/ -inline REAL* +inline real_t* oclAllocArrays_VectKernel ( oclLoopArrays& ocl_arrs, cl_context cxGPUContext, @@ -421,8 +428,9 @@ oclAllocArrays_VectKernel ( ) { cl_int ciErr2; size_t cur_size; - REAL* glb_vhat; - + real_t* glb_vhat; + ciErr = 0; +#if 0 { // 1. RO scalars cur_size = sizeof(LoopROScalars); ocl_arrs.ro_scals = clCreateBuffer( @@ -432,6 +440,7 @@ oclAllocArrays_VectKernel ( ciErr |= clEnqueueWriteBuffer( cqCommandQueue, ocl_arrs.ro_scals, CL_TRUE, 0, cur_size, &ro_scals, 0, NULL, NULL); } +#endif { // 2. SOBOL DIR VECTOR const SobolArrays& cpu_arrs = sob_arrs; @@ -454,7 +463,7 @@ oclAllocArrays_VectKernel ( cur_size = 3*ro_scals.num_dates*sizeof(UINT); CREATE_AND_ENQUEUE_RO_CL_BUFFER(bb_inds); - cur_size = 3*ro_scals.num_dates*sizeof(REAL); + cur_size = 3*ro_scals.num_dates*sizeof(real_t); CREATE_AND_ENQUEUE_RO_CL_BUFFER(bb_data); } @@ -463,7 +472,7 @@ oclAllocArrays_VectKernel ( cur_size = ro_scals.num_under * ( ro_scals.num_under + 2*ro_scals.num_dates + 1); cur_size += ro_scals.num_cash_flows + ro_scals.num_det_pricers; - cur_size *= ro_scals.num_models * sizeof(REAL); + cur_size *= ro_scals.num_models * sizeof(real_t); CREATE_AND_ENQUEUE_RO_CL_BUFFER(md_c); } @@ -472,7 +481,7 @@ oclAllocArrays_VectKernel ( // md_z is filled up by Brownian Bridge & used in trajectory.. cur_size = getWorkSize( ro_scals.num_gpuits, ro_scals.chunk, ro_scals.BLOCK ) * ro_scals.num_models * ro_scals.num_under * ro_scals.num_dates * - ro_scals.chunk * sizeof(REAL); + ro_scals.chunk * sizeof(real_t); ocl_arrs.md_zd = clCreateBuffer(cxGPUContext, CL_MEM_READ_WRITE, cur_size, NULL, &ciErr2 ); @@ -487,9 +496,9 @@ oclAllocArrays_VectKernel ( { // 7. FINALLY, GLOBAL VHAT WO cur_size = getWorkSize( ro_scals.num_gpuits, ro_scals.chunk, ro_scals.BLOCK ); - cur_size*= ro_scals.num_models * sizeof(REAL); + cur_size*= ro_scals.num_models * sizeof(real_t); - glb_vhat = (REAL*)malloc( cur_size ); + glb_vhat = (real_t*)malloc( cur_size ); ocl_arrs.model_vhat = clCreateBuffer( cxGPUContext, CL_MEM_WRITE_ONLY | CL_MEM_USE_HOST_PTR, @@ -504,7 +513,7 @@ oclAllocArrays_VectKernel ( void runGPU_VECT( const LoopROScalars& ro_scals, - REAL* glb_vhat, + real_t* glb_vhat, oclLoopArrays& dev_arr, cl_command_queue& cqCommandQueue, cl_program& cpProgram, @@ -579,7 +588,7 @@ void runGPU_VECT( #ifdef _OPTIMIZATION_MEM_COALES_ON if( optim_kernel ) { assert( ( 2*ro_scals.num_under <= TILE) && "Illegal dataset: num_under > 4" ); - UINT priv_sz = TILE * ro_scals.BLOCK * sizeof(REAL); + UINT priv_sz = TILE * ro_scals.BLOCK * sizeof(real_t); ciErr1 |= clSetKernelArg(ckGenPricing_traj, counter++, priv_sz, NULL); // local_space! } #endif @@ -607,7 +616,7 @@ void runGPU_VECT( ciErr1 |= clSetKernelArg(ckGenPricing_finred, counter++, sizeof(cl_mem), (void*)&dev_arr.model_vhat ); assert( (ro_scals.num_models <= TILE) && "Illegal dataset: num_models > 8" ); - UINT priv_sz = TILE * ro_scals.BLOCK * sizeof(REAL); + UINT priv_sz = TILE * ro_scals.BLOCK * sizeof(real_t); ciErr1 |= clSetKernelArg(ckGenPricing_finred, counter++, priv_sz, NULL); // local_space! ciErr1 |= clEnqueueNDRangeKernel( cqCommandQueue, ckGenPricing_finred, 1, NULL, @@ -615,7 +624,7 @@ void runGPU_VECT( oclCheckError(ciErr1, CL_SUCCESS); ciErr1 |= clEnqueueReadBuffer( cqCommandQueue, dev_arr.model_vhat, CL_TRUE, 0, - globalWorkSize[0] * ro_scals.num_models * sizeof(REAL), + globalWorkSize[0] * ro_scals.num_models * sizeof(real_t), glb_vhat, 0, NULL, NULL); oclCheckError(ciErr1, CL_SUCCESS); } diff --git a/benchmarks/OptionPricing/implementations/cpp_opencl/static_configuration_template.json b/benchmarks/OptionPricing/implementations/cpp_opencl/static_configuration_template.json new file mode 100644 index 0000000..13d98fe --- /dev/null +++ b/benchmarks/OptionPricing/implementations/cpp_opencl/static_configuration_template.json @@ -0,0 +1,6 @@ +{ + "REAL_TYPE" : ["float"], + "STRENGTH_REDUCTION" : ["on", "off"], + "VECTORIZATION" : ["on", "off"], + "MEM_COALESCING" : ["on", "off"] +} diff --git a/benchmarks/OptionPricing/implementations/cpp_openmp/.gitignore b/benchmarks/OptionPricing/implementations/cpp_openmp/.gitignore new file mode 100644 index 0000000..cf8c610 --- /dev/null +++ b/benchmarks/OptionPricing/implementations/cpp_openmp/.gitignore @@ -0,0 +1 @@ +GenPricing \ No newline at end of file diff --git a/OptionPricing/CppOpenMP/GenPricing.cpp b/benchmarks/OptionPricing/implementations/cpp_openmp/GenPricing.cpp similarity index 79% rename from OptionPricing/CppOpenMP/GenPricing.cpp rename to benchmarks/OptionPricing/implementations/cpp_openmp/GenPricing.cpp index 74a7b27..cd155a0 100644 --- a/OptionPricing/CppOpenMP/GenPricing.cpp +++ b/benchmarks/OptionPricing/implementations/cpp_openmp/GenPricing.cpp @@ -1,5 +1,10 @@ #define FAST_BB +#define _OPTIMIZATION_SOBOL_STRENGTH_RED_RECURR + +#include +#include + #include "ParseInput.h" #include "SobolGaussBB.h" #include "Contracts.h" @@ -18,8 +23,8 @@ double* run_CPUkernel( const int& Ps, // allocate for Ps threads const UINT Sd = do_padding( sob_dim ); UINT* sob_glb_vct = static_cast( malloc( Ps * Sd * sizeof(UINT)) ); - REAL* md_glb_vct = static_cast( malloc( Ps * Sd * sizeof(REAL)) ); - REAL* trj_glb_vct = static_cast( malloc( Ps * Sd * sizeof(REAL)) ); + real_t* md_glb_vct = static_cast( malloc( Ps * Sd * sizeof(real_t)) ); + real_t* trj_glb_vct = static_cast( malloc( Ps * Sd * sizeof(real_t)) ); const UINT Sv = do_padding( scals.num_models ); double* vhat_glb = static_cast( malloc( Ps * Sv * sizeof(double)) ); @@ -28,8 +33,8 @@ double* run_CPUkernel( const int& Ps, { UINT th_id = omp_get_thread_num(); UINT* sob_vct = sob_glb_vct + ( th_id * Sd ); - REAL* md_vct = md_glb_vct + ( th_id * Sd ); - REAL* trj_vct = trj_glb_vct + ( th_id * Sd ); + real_t* md_vct = md_glb_vct + ( th_id * Sd ); + real_t* trj_vct = trj_glb_vct + ( th_id * Sd ); double* vhat = vhat_glb + ( th_id * Sv ); for(int i = 0; i < scals.num_models; i ++) @@ -73,28 +78,28 @@ double* run_CPUkernel( const int& Ps, md_vct, trj_vct ); #ifdef FAST_BB - REAL* traj = md_vct; + real_t* traj = md_vct; #else - REAL* traj = trj_vct; //md_vct; + real_t* traj = trj_vct; //md_vct; #endif // compute trajectory for ( int m = 0; m < scals.num_models; m ++ ) { - REAL* md_c = md_arrs.md_c + ( m * num_under_sq ); - REAL* md_vols = md_arrs.md_vols + ( m * sob_dim ); - REAL* md_drifts = md_arrs.md_drifts + ( m * sob_dim ); - REAL* md_starts = md_arrs.md_starts + ( m * scals.num_under ); + real_t* md_c = md_arrs.md_c + ( m * num_under_sq ); + real_t* md_vols = md_arrs.md_vols + ( m * sob_dim ); + real_t* md_drifts = md_arrs.md_drifts + ( m * sob_dim ); + real_t* md_starts = md_arrs.md_starts + ( m * scals.num_under ); for( int i = 0; i < scals.num_dates; i ++ ) { for( int j = 0; j < scals.num_under; j ++ ) { - REAL temp = 0.0; + real_t temp = 0.0; int k = i*scals.num_under + j; for ( int l = 0; l <= j; l ++ ) { #ifdef FAST_BB - REAL md_val = trj_vct[i*scals.num_under + l]; + real_t md_val = trj_vct[i*scals.num_under + l]; #else - REAL md_val = md_vct [i*scals.num_under + l]; + real_t md_val = md_vct [i*scals.num_under + l]; #endif temp += md_c[j*scals.num_under + l] * md_val; } @@ -152,7 +157,7 @@ int main() { const int Ps = get_CPU_num_threads(); double* prices; - unsigned long int elapsed; + unsigned long int elapsed_usec; { // run kernel struct timeval t_start, t_end, t_diff; gettimeofday(&t_start, NULL); @@ -164,21 +169,22 @@ int main() { gettimeofday(&t_end, NULL); timeval_subtract(&t_diff, &t_end, &t_start); - elapsed = t_diff.tv_sec*1e6+t_diff.tv_usec; + elapsed_usec = t_diff.tv_sec*1e6+t_diff.tv_usec; + { + FILE* runtime = fopen(getenv("HIPERMARK_RUNTIME"), "w"); + FILE* result = fopen(getenv("HIPERMARK_RESULT"), "w"); + fprintf(runtime, "%d\n", elapsed_usec); + fclose(runtime); + write_1Darr(result, prices, scals.num_models); + fclose(result); + } md_arrs .cleanup(); bb_arrs .cleanup(); sob_arrs.cleanup(); } - { // validation and writeback of the result - bool is_valid = validate ( scals.num_models, prices ); - writeStatsAndResult( is_valid, scals.num_models, prices, false, Ps, elapsed ); - free(prices); - } + free(prices); - return 0; // XXX this was "1" before, why? + return 0; } - - -// cat ../Data/Medium/input.data ../Data/Medium/output.data | ./GenPricing 2> Debug.txt diff --git a/benchmarks/OptionPricing/implementations/cpp_openmp/Makefile b/benchmarks/OptionPricing/implementations/cpp_openmp/Makefile new file mode 100644 index 0000000..b0e249b --- /dev/null +++ b/benchmarks/OptionPricing/implementations/cpp_openmp/Makefile @@ -0,0 +1,33 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +# Default to double if nothing else defined. +HIPERMARK_CONFIG_REAL_TYPE ?= double + +include $(HIPERMARK_LIB_DIR)/setup.mk +include $(HIPERMARK_LIB_DIR)/setup_real_type.mk + +INCLUDES += -I$(HIPERMARK_BENCHMARK_LIB_DIR)/include +INCLUDES += -I$(HIPERMARK_LIB_DIR)/include + +SOURCES_CPP =GenPricing.cpp +HELPERS =$(HIPERMARK_BENCHMARK_LIB_DIR)/include/ParseInput.h +OBJECTS =GenPricing.o +EXECUTABLE =GenPricing + +default: $(EXECUTABLE) + +%.o: $(HIPERMARK_IMPLEMENTATION_DIR)/%.cpp $(HELPERS) + $(CXX) $(CXXFLAGS) $(INCLUDES) -c -o $@ $< + +$(EXECUTABLE): $(OBJECTS) + $(CXX) $(CXXFLAGS) $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) + +clean: + rm -f $(EXECUTABLE) $(OBJECTS) + +HIPERMARK_DATA_FIELDS=contract_number monte_carlo_iterations num_path_dates num_underlyings num_models num_bits dir_vs md_c md_vols md_drifts md_starts md_deterministic_values md_discounts bb_inds bb_data +ifdef HIPERMARK_CONFIG_NUM_THREADS + HIPERMARK_RUN_ENVIRONMENT=OMP_NUM_THREADS=$(HIPERMARK_CONFIG_NUM_THREADS) +endif +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/benchmarks/OptionPricing/implementations/cpp_openmp/dynamic_configuration_template.json b/benchmarks/OptionPricing/implementations/cpp_openmp/dynamic_configuration_template.json new file mode 100644 index 0000000..8276926 --- /dev/null +++ b/benchmarks/OptionPricing/implementations/cpp_openmp/dynamic_configuration_template.json @@ -0,0 +1 @@ +{ "NUM_THREADS": ["4", "8", "12", "16", "32"] } diff --git a/benchmarks/OptionPricing/implementations/cpp_openmp/static_configuration_template.json b/benchmarks/OptionPricing/implementations/cpp_openmp/static_configuration_template.json new file mode 100644 index 0000000..7742ccc --- /dev/null +++ b/benchmarks/OptionPricing/implementations/cpp_openmp/static_configuration_template.json @@ -0,0 +1,4 @@ +{ + "REAL_TYPE" : ["float", "double"] +} + diff --git a/benchmarks/OptionPricing/implementations/cpp_sequential/.gitignore b/benchmarks/OptionPricing/implementations/cpp_sequential/.gitignore new file mode 100644 index 0000000..cf8c610 --- /dev/null +++ b/benchmarks/OptionPricing/implementations/cpp_sequential/.gitignore @@ -0,0 +1 @@ +GenPricing \ No newline at end of file diff --git a/OptionPricing/OrigCpp/GenPricing.cpp b/benchmarks/OptionPricing/implementations/cpp_sequential/GenPricing.cpp similarity index 78% rename from OptionPricing/OrigCpp/GenPricing.cpp rename to benchmarks/OptionPricing/implementations/cpp_sequential/GenPricing.cpp index d7af8c8..d3bca2e 100644 --- a/OptionPricing/OrigCpp/GenPricing.cpp +++ b/benchmarks/OptionPricing/implementations/cpp_sequential/GenPricing.cpp @@ -16,8 +16,8 @@ double* run_CPUkernel( const LoopROScalars & scals, // allocate for Ps threads const UINT Sd = do_padding( sob_dim ); UINT* sob_vct = static_cast( malloc( Sd * sizeof(UINT)) ); - REAL* md_vct = static_cast( malloc( Sd * sizeof(REAL)) ); - REAL* trj_vct = static_cast( malloc( Sd * sizeof(REAL)) ); + real_t* md_vct = static_cast( malloc( Sd * sizeof(real_t)) ); + real_t* trj_vct = static_cast( malloc( Sd * sizeof(real_t)) ); const UINT Sv = do_padding( scals.num_models ); double* vhat = static_cast( malloc( Sv * sizeof(double)) ); @@ -46,28 +46,28 @@ double* run_CPUkernel( const LoopROScalars & scals, md_vct, trj_vct ); #ifdef FAST_BB - REAL* traj = md_vct; + real_t* traj = md_vct; #else - REAL* traj = trj_vct; //md_vct; + real_t* traj = trj_vct; //md_vct; #endif // compute trajectory for ( int m = 0; m < scals.num_models; m ++ ) { - REAL* md_c = md_arrs.md_c + ( m * num_under_sq ); - REAL* md_vols = md_arrs.md_vols + ( m * sob_dim ); - REAL* md_drifts = md_arrs.md_drifts + ( m * sob_dim ); - REAL* md_starts = md_arrs.md_starts + ( m * scals.num_under ); + real_t* md_c = md_arrs.md_c + ( m * num_under_sq ); + real_t* md_vols = md_arrs.md_vols + ( m * sob_dim ); + real_t* md_drifts = md_arrs.md_drifts + ( m * sob_dim ); + real_t* md_starts = md_arrs.md_starts + ( m * scals.num_under ); for( int i = 0; i < scals.num_dates; i ++ ) { for( int j = 0; j < scals.num_under; j ++ ) { - REAL temp = 0.0; + real_t temp = 0.0; int k = i*scals.num_under + j; for ( int l = 0; l <= j; l ++ ) { #ifdef FAST_BB - REAL md_val = trj_vct[i*scals.num_under + l]; + real_t md_val = trj_vct[i*scals.num_under + l]; #else - REAL md_val = md_vct [i*scals.num_under + l]; + real_t md_val = md_vct [i*scals.num_under + l]; #endif temp += md_c[j*scals.num_under + l] * md_val; } @@ -118,7 +118,7 @@ int main() { scals.contract, scals.num_mcits, scals.num_under, scals.num_dates, scals.chunk ); double* prices; - unsigned long int elapsed; + unsigned long int elapsed_usec; { // run kernel struct timeval t_start, t_end, t_diff; gettimeofday(&t_start, NULL); @@ -130,17 +130,20 @@ int main() { gettimeofday(&t_end, NULL); timeval_subtract(&t_diff, &t_end, &t_start); - elapsed = t_diff.tv_sec*1e6+t_diff.tv_usec; + elapsed_usec = t_diff.tv_sec*1e6+t_diff.tv_usec; md_arrs .cleanup(); bb_arrs .cleanup(); sob_arrs.cleanup(); } - { // validation and writeback of the result - bool is_valid = validate ( scals.num_models, prices ); - writeStatsAndResult( is_valid, scals.num_models, prices, false, 1, elapsed ); - free(prices); + { + FILE* runtime = fopen(getenv("HIPERMARK_RUNTIME"), "w"); + FILE* result = fopen(getenv("HIPERMARK_RESULT"), "w"); + fprintf(runtime, "%d\n", elapsed_usec); + fclose(runtime); + write_1Darr(result, prices, scals.num_models); + fclose(result); } return 0; diff --git a/benchmarks/OptionPricing/implementations/cpp_sequential/Makefile b/benchmarks/OptionPricing/implementations/cpp_sequential/Makefile new file mode 100644 index 0000000..bfe027c --- /dev/null +++ b/benchmarks/OptionPricing/implementations/cpp_sequential/Makefile @@ -0,0 +1,31 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +# Default to double if nothing else defined. +HIPERMARK_CONFIG_REAL_TYPE ?= double + +include $(HIPERMARK_LIB_DIR)/setup.mk +include $(HIPERMARK_LIB_DIR)/setup_real_type.mk + +INCLUDES += -I$(HIPERMARK_BENCHMARK_LIB_DIR)/include +INCLUDES += -I$(HIPERMARK_LIB_DIR)/include + +SOURCES_CPP =GenPricing.cpp +HELPERS =$(HIPERMARK_BENCHMARK_LIB_DIR)/include/ParseInput.h +OBJECTS =GenPricing.o +EXECUTABLE =GenPricing + +default: $(EXECUTABLE) + +%.o: $(HIPERMARK_IMPLEMENTATION_DIR)/%.cpp $(HELPERS) + $(CXX) $(CXXFLAGS) -g $(INCLUDES) -c -o $@ $< + +$(EXECUTABLE): $(OBJECTS) + $(CXX) $(CXXFLAGS) -g $(INCLUDES) -o $(EXECUTABLE) $(OBJECTS) + +clean: + rm -f $(EXECUTABLE) $(OBJECTS) + +HIPERMARK_DATA_FIELDS=contract_number monte_carlo_iterations num_path_dates num_underlyings num_models num_bits dir_vs md_c md_vols md_drifts md_starts md_deterministic_values md_discounts bb_inds bb_data +HIPERMARK_RUN_ENVIRONMENT= +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/benchmarks/OptionPricing/implementations/cpp_sequential/static_configuration_template.json b/benchmarks/OptionPricing/implementations/cpp_sequential/static_configuration_template.json new file mode 100644 index 0000000..7742ccc --- /dev/null +++ b/benchmarks/OptionPricing/implementations/cpp_sequential/static_configuration_template.json @@ -0,0 +1,4 @@ +{ + "REAL_TYPE" : ["float", "double"] +} + diff --git a/benchmarks/OptionPricing/implementations/haskell_lh/.gitignore b/benchmarks/OptionPricing/implementations/haskell_lh/.gitignore new file mode 100644 index 0000000..cf8c610 --- /dev/null +++ b/benchmarks/OptionPricing/implementations/haskell_lh/.gitignore @@ -0,0 +1 @@ +GenPricing \ No newline at end of file diff --git a/OptionPricing/HaskellLH/GenPricing.hs b/benchmarks/OptionPricing/implementations/haskell_lh/GenPricing.hs similarity index 96% rename from OptionPricing/HaskellLH/GenPricing.hs rename to benchmarks/OptionPricing/implementations/haskell_lh/GenPricing.hs index c347e07..3d52d4c 100644 --- a/OptionPricing/HaskellLH/GenPricing.hs +++ b/benchmarks/OptionPricing/implementations/haskell_lh/GenPricing.hs @@ -4,6 +4,8 @@ import qualified Data.List import Control.Applicative import Control.Monad import Data.Maybe +import System.Environment +import System.CPUTime ------------------------------------ --- Requires the installation of --- @@ -31,6 +33,9 @@ import qualified Data.Vector.Unboxed as V signed :: Parser String -> Parser String signed p = (char '-' >> (('-':) <$> p)) <|> p +exponented :: Parser String -> Parser String +exponented p = (++) <$> p <*> (((:) <$> oneOf "eE" <*> signed (many1 digit)) <|> pure "") + whitespace :: Parser () whitespace = spaces <* optional (string "//" >> manyTill anyChar (char '\n') >> whitespace) @@ -44,7 +49,7 @@ readInt :: Parser Int readInt = lexeme $ read <$> signed (many1 digit) readDouble :: Parser Double -readDouble = lexeme $ read <$> signed (s2 <|> s1) +readDouble = lexeme $ read <$> exponented (signed $ s2 <|> s1) where s1 = do bef <- many1 digit aft <- fromMaybe "" <$> optional ((:) <$> char '.' <*> many1 digit) return $ bef ++ aft @@ -438,14 +443,13 @@ main :: IO () main = do s <- getContents case parse run "input" s of Left e -> error $ show e - Right (p,pr,i) -> do let msg_lst = validate pr p i - putStrLn (msg_lst !! 0) - putStrLn (msg_lst !! 1) - putStrLn (msg_lst !! 2) - putStrLn (msg_lst !! 3) - putStrLn (msg_lst !! 4) - putStrLn (msg_lst !! 5) - -- print $ validate pr p i + Right m -> do + (v, runtime) <- m + result <- getEnv "HIPERMARK_RESULT" + writeFile result $ show v + runtime_file <- getEnv "HIPERMARK_RUNTIME" + writeFile runtime_file $ show runtime + -- either (error . show) print $ parse run "input" s where run = do contract <- readInt num_mc_it <- readInt @@ -478,8 +482,11 @@ main = do s <- getContents sob_dirvs md_cs md_vols md_drifts md_starts md_detvals md_discts bb_inds bb_data - r <- readDouble1d - return (v, r, (contract,num_mc_it, num_dates, num_under)) + return $ do + start <- getCPUTime -- In picoseconds; 1 microsecond == 10^6 picoseconds. + end <- v `deepseq` getCPUTime + return (v, (end - start) `div` 1000000) + readInt2d = readArray $ readArray readInt readDouble1d = readArray readDouble diff --git a/benchmarks/OptionPricing/implementations/haskell_lh/Makefile b/benchmarks/OptionPricing/implementations/haskell_lh/Makefile new file mode 100644 index 0000000..9f88571 --- /dev/null +++ b/benchmarks/OptionPricing/implementations/haskell_lh/Makefile @@ -0,0 +1,22 @@ +# Permit standalone compilation. +HIPERMARK_LIB_DIR ?= ../../../../lib/ + +include $(HIPERMARK_LIB_DIR)/setup.mk + +SOURCES = GenPricing.hs +EXECUTABLE = GenPricing +OBJECTS = GenPricing.hi GenPricing.o + +GHC_FLAGS = -Wall -O2 -msse2 -rtsopts -i$(HIPERMARK_IMPLEMENTATION) + +default: $(EXECUTABLE) + +$(EXECUTABLE): $(HIPERMARK_IMPLEMENTATION_DIR)/$(SOURCES) + ghc $(HIPERMARK_IMPLEMENTATION_DIR)/$(SOURCES) $(GHC_FLAGS) -o $(EXECUTABLE) + +clean: + rm -f Debug.txt $(EXECUTABLE) $(OBJECTS) + +HIPERMARK_DATA_FIELDS=contract_number monte_carlo_iterations num_path_dates num_underlyings num_models num_bits dir_vs md_c md_vols md_drifts md_starts md_deterministic_values md_discounts bb_inds bb_data +HIPERMARK_RUN_ENVIRONMENT= +include $(HIPERMARK_LIB_DIR)/flat_data_helper.mk diff --git a/OptionPricing/HaskellLH/Payoff3Cond.hs b/benchmarks/OptionPricing/implementations/haskell_lh/Payoff3Cond.hs similarity index 100% rename from OptionPricing/HaskellLH/Payoff3Cond.hs rename to benchmarks/OptionPricing/implementations/haskell_lh/Payoff3Cond.hs diff --git a/OptionPricing/includeC/Constants.h b/benchmarks/OptionPricing/lib/include/Constants.h similarity index 82% rename from OptionPricing/includeC/Constants.h rename to benchmarks/OptionPricing/lib/include/Constants.h index b5e21ab..444a5bf 100644 --- a/OptionPricing/includeC/Constants.h +++ b/benchmarks/OptionPricing/lib/include/Constants.h @@ -1,19 +1,12 @@ #ifndef CONSTANTS_H #define CONSTANTS_H +#include "real.h" #include "Optimizations.h" #define WARP (1<num_contracts * ro_scal->inst_num; + UINT index = model_num*ro_scal->num_contracts + contract_number; + index += cur_iter*prod; +#endif + UINT ind = disct_index + model_ind*num_cash_flows; + vhat[model_ind] += (amount * md_discts[ind]); + + //printf("Updating vhat with: %f %f \n", amount, md_discts[ind] ); + + //instance *inst = (instance*) model->model_data; + //inst->vhat[contract_number] += amount * inst->discounts[date_index]; +} + +inline +void trajectory_contract1( // SIMPLE + const UINT& model_num, // the index of the current model + const UINT& num_under, // the number of underlyings + const UINT& num_cash_flows, + const UINT& num_pricers,// the number of deterministic procers + const real_t* md_discts, // [num_models][num_cash_flows] discounts + const real_t* md_detvals, // [num_models, num_det_pricers] pricers + const real_t* inst_traj, // [num_dates, num_under] current trajectory + double* vhat // [model_num] Accumulated per-model price + +) { + real_t amount = ((underlyings(0,0)) - 4000.0) * md_detvals[model_num*num_pricers]; + amount = fmax(0.0, amount); + trajectory_inner( num_cash_flows, model_num, 0, amount, md_discts, vhat ); +} + +inline +void trajectory_contract2( // WORST OFF + const UINT& model_num, // the index of the current model + const UINT& num_under, // the number of underlyings + const UINT& num_cash_flows, + const UINT& num_pricers,// the number of deterministic procers + const real_t* md_discts, // [num_models][num_cash_flows] discounts + const real_t* md_detvals, // [num_models, num_det_pricers] pricers + const real_t* inst_traj, // [num_dates, num_under] current trajectory + double* vhat // [model_num] Accumulated per-model price +) { + double x50; + + if ((1. <= fmin((underlyings(0,1) / 11840.), fmin((underlyings(0,2) / 1200.), (underlyings(0,0) / 3758.05))))) goto L21; + if ((1. <= fmin((underlyings(1,1) / 11840.), fmin((underlyings(1,2) / 1200.), (underlyings(1,0) / 3758.05))))) goto L22; + if ((1. <= fmin((underlyings(2,1) / 11840.), fmin((underlyings(2,2) / 1200.), (underlyings(2,0) / 3758.05))))) goto L23; + if ((1. <= fmin((underlyings(3,1) / 11840.), fmin((underlyings(3,2) / 1200.), (underlyings(3,0) / 3758.05))))) goto L24; + x50=fmin((underlyings(4,1) / 11840.), fmin((underlyings(4,2) / 1200.), (underlyings(4,0) / 3758.05))); + + //model->notify_cash_flow(model, 0, 1000., 4 /*2017-02-03, 2017-01-27, EUR*/); + trajectory_inner( num_cash_flows, model_num, 4, 1000., md_discts, vhat ); + + if ((1. <= x50)) goto L25; + if ((0.75 < x50)) return; + + //model->notify_cash_flow(model, 0, (-(1000. * (1. - x50))), 4 /*2017-02-03, 2017-01-27, EUR*/); return; + trajectory_inner( num_cash_flows, model_num, 4, (-(1000. * (1. - x50))), md_discts, vhat ); return; +L25: + //model->notify_cash_flow(model, 0, 750., 4 /*2017-02-03, 2017-01-27, EUR*/); return; + trajectory_inner( num_cash_flows, model_num, 4, 750., md_discts, vhat ); return; +L24: + //model->notify_cash_flow(model, 0, 1600., 3 /*2016-02-03, 2016-01-27, EUR*/); return; + trajectory_inner( num_cash_flows, model_num, 3, 1600., md_discts, vhat ); return; +L23: + //model->notify_cash_flow(model, 0, 1450., 2 /*2015-02-03, 2015-01-27, EUR*/); return; + trajectory_inner( num_cash_flows, model_num, 2, 1450., md_discts, vhat ); return; +L22: + //model->notify_cash_flow(model, 0, 1300., 1 /*2014-02-03, 2014-01-27, EUR*/); return; + trajectory_inner( num_cash_flows, model_num, 1, 1300., md_discts, vhat ); return; +L21: + //model->notify_cash_flow(model, 0, 1150., 0 /*2013-02-01, 2013-01-27, EUR*/); return; + trajectory_inner( num_cash_flows, model_num, 0, 1150., md_discts, vhat ); return; +} + + + + +// LENGTHY CONTRACT + +inline +void trajectory_contract3( // BARRIER + const UINT& model_num, // the index of the current model + const UINT& num_under, // the number of underlyings + const UINT& num_cash_flows, + const UINT& num_pricers,// the number of deterministic procers + const real_t* md_discts, // [num_models][num_scash_flow] discounts + const real_t* md_detvals, // [num_models, num_det_pricers] pricers + const real_t* inst_traj, // [num_dates, num_under] current trajectory + double* vhat // [model_num] Accumulated per-model price +) { + //assert(model_num==0 && "NUM MODELS > 1"); + UINT x3309; + + if ((underlyings(0,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(0,2) <= 840.)) goto L50; + if ((underlyings(0,1) <= 8288.)) goto L50; + if ((underlyings(1,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(1,2) <= 840.)) goto L50; + if ((underlyings(1,1) <= 8288.)) goto L50; + if ((underlyings(2,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(2,2) <= 840.)) goto L50; + if ((underlyings(2,1) <= 8288.)) goto L50; + if ((underlyings(3,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(3,2) <= 840.)) goto L50; + if ((underlyings(3,1) <= 8288.)) goto L50; + if ((underlyings(4,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(4,2) <= 840.)) goto L50; + if ((underlyings(4,1) <= 8288.)) goto L50; + if ((underlyings(5,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(5,2) <= 840.)) goto L50; + if ((underlyings(5,1) <= 8288.)) goto L50; + if ((underlyings(6,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(6,2) <= 840.)) goto L50; + if ((underlyings(6,1) <= 8288.)) goto L50; + if ((underlyings(7,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(7,2) <= 840.)) goto L50; + if ((underlyings(7,1) <= 8288.)) goto L50; + if ((underlyings(8,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(8,2) <= 840.)) goto L50; + if ((underlyings(8,1) <= 8288.)) goto L50; + if ((underlyings(9,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(9,2) <= 840.)) goto L50; + if ((underlyings(9,1) <= 8288.)) goto L50; + if ((underlyings(10,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(10,2) <= 840.)) goto L50; + if ((underlyings(10,1) <= 8288.)) goto L50; + if ((underlyings(11,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(11,2) <= 840.)) goto L50; + if ((underlyings(11,1) <= 8288.)) goto L50; + if ((underlyings(12,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(12,2) <= 840.)) goto L50; + if ((underlyings(12,1) <= 8288.)) goto L50; + if ((underlyings(13,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(13,2) <= 840.)) goto L50; + if ((underlyings(13,1) <= 8288.)) goto L50; + if ((underlyings(14,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(14,2) <= 840.)) goto L50; + if ((underlyings(14,1) <= 8288.)) goto L50; + if ((underlyings(15,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(15,2) <= 840.)) goto L50; + if ((underlyings(15,1) <= 8288.)) goto L50; + if ((underlyings(16,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(16,2) <= 840.)) goto L50; + if ((underlyings(16,1) <= 8288.)) goto L50; + if ((underlyings(17,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(17,2) <= 840.)) goto L50; + if ((underlyings(17,1) <= 8288.)) goto L50; + if ((underlyings(18,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(18,2) <= 840.)) goto L50; + if ((underlyings(18,1) <= 8288.)) goto L50; + if ((underlyings(19,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(19,2) <= 840.)) goto L50; + if ((underlyings(19,1) <= 8288.)) goto L50; + if ((underlyings(20,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(20,2) <= 840.)) goto L50; + if ((underlyings(20,1) <= 8288.)) goto L50; + if ((underlyings(21,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(21,2) <= 840.)) goto L50; + if ((underlyings(21,1) <= 8288.)) goto L50; + if ((underlyings(22,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(22,2) <= 840.)) goto L50; + if ((underlyings(22,1) <= 8288.)) goto L50; + if ((underlyings(23,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(23,2) <= 840.)) goto L50; + if ((underlyings(23,1) <= 8288.)) goto L50; + if ((underlyings(24,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(24,2) <= 840.)) goto L50; + if ((underlyings(24,1) <= 8288.)) goto L50; + if ((underlyings(25,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(25,2) <= 840.)) goto L50; + if ((underlyings(25,1) <= 8288.)) goto L50; + if ((underlyings(26,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(26,2) <= 840.)) goto L50; + if ((underlyings(26,1) <= 8288.)) goto L50; + if ((underlyings(27,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(27,2) <= 840.)) goto L50; + if ((underlyings(27,1) <= 8288.)) goto L50; + if ((underlyings(28,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(28,2) <= 840.)) goto L50; + if ((underlyings(28,1) <= 8288.)) goto L50; + if ((underlyings(29,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(29,2) <= 840.)) goto L50; + if ((underlyings(29,1) <= 8288.)) goto L50; + if ((underlyings(30,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(30,2) <= 840.)) goto L50; + if ((underlyings(30,1) <= 8288.)) goto L50; + if ((underlyings(31,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(31,2) <= 840.)) goto L50; + if ((underlyings(31,1) <= 8288.)) goto L50; + if ((underlyings(32,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(32,2) <= 840.)) goto L50; + if ((underlyings(32,1) <= 8288.)) goto L50; + if ((underlyings(33,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(33,2) <= 840.)) goto L50; + if ((underlyings(33,1) <= 8288.)) goto L50; + if ((underlyings(34,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(34,2) <= 840.)) goto L50; + if ((underlyings(34,1) <= 8288.)) goto L50; + if ((underlyings(35,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(35,2) <= 840.)) goto L50; + if ((underlyings(35,1) <= 8288.)) goto L50; + if ((underlyings(36,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(36,2) <= 840.)) goto L50; + if ((underlyings(36,1) <= 8288.)) goto L50; + if ((underlyings(37,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(37,2) <= 840.)) goto L50; + if ((underlyings(37,1) <= 8288.)) goto L50; + if ((underlyings(38,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(38,2) <= 840.)) goto L50; + if ((underlyings(38,1) <= 8288.)) goto L50; + if ((underlyings(39,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(39,2) <= 840.)) goto L50; + if ((underlyings(39,1) <= 8288.)) goto L50; + if ((underlyings(40,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(40,2) <= 840.)) goto L50; + if ((underlyings(40,1) <= 8288.)) goto L50; + if ((underlyings(41,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(41,2) <= 840.)) goto L50; + if ((underlyings(41,1) <= 8288.)) goto L50; + if ((underlyings(42,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(42,2) <= 840.)) goto L50; + if ((underlyings(42,1) <= 8288.)) goto L50; + if ((underlyings(43,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(43,2) <= 840.)) goto L50; + if ((underlyings(43,1) <= 8288.)) goto L50; + if ((underlyings(44,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(44,2) <= 840.)) goto L50; + if ((underlyings(44,1) <= 8288.)) goto L50; + if ((underlyings(45,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(45,2) <= 840.)) goto L50; + if ((underlyings(45,1) <= 8288.)) goto L50; + if ((underlyings(46,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(46,2) <= 840.)) goto L50; + if ((underlyings(46,1) <= 8288.)) goto L50; + if ((underlyings(47,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(47,2) <= 840.)) goto L50; + if ((underlyings(47,1) <= 8288.)) goto L50; + if ((underlyings(48,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(48,2) <= 840.)) goto L50; + if ((underlyings(48,1) <= 8288.)) goto L50; + if ((underlyings(49,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(49,2) <= 840.)) goto L50; + if ((underlyings(49,1) <= 8288.)) goto L50; + if ((underlyings(50,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(50,2) <= 840.)) goto L50; + if ((underlyings(50,1) <= 8288.)) goto L50; + if ((underlyings(51,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(51,2) <= 840.)) goto L50; + if ((underlyings(51,1) <= 8288.)) goto L50; + if ((underlyings(52,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(52,2) <= 840.)) goto L50; + if ((underlyings(52,1) <= 8288.)) goto L50; + if ((underlyings(53,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(53,2) <= 840.)) goto L50; + if ((underlyings(53,1) <= 8288.)) goto L50; + if ((underlyings(54,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(54,2) <= 840.)) goto L50; + if ((underlyings(54,1) <= 8288.)) goto L50; + if ((underlyings(55,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(55,2) <= 840.)) goto L50; + if ((underlyings(55,1) <= 8288.)) goto L50; + if ((underlyings(56,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(56,2) <= 840.)) goto L50; + if ((underlyings(56,1) <= 8288.)) goto L50; + if ((underlyings(57,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(57,2) <= 840.)) goto L50; + if ((underlyings(57,1) <= 8288.)) goto L50; + if ((underlyings(58,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(58,2) <= 840.)) goto L50; + if ((underlyings(58,1) <= 8288.)) goto L50; + if ((underlyings(59,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(59,2) <= 840.)) goto L50; + if ((underlyings(59,1) <= 8288.)) goto L50; + if ((underlyings(60,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(60,2) <= 840.)) goto L50; + if ((underlyings(60,1) <= 8288.)) goto L50; + if ((underlyings(61,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(61,2) <= 840.)) goto L50; + if ((underlyings(61,1) <= 8288.)) goto L50; + if ((underlyings(62,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(62,2) <= 840.)) goto L50; + if ((underlyings(62,1) <= 8288.)) goto L50; + if ((underlyings(63,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(63,2) <= 840.)) goto L50; + if ((underlyings(63,1) <= 8288.)) goto L50; + if ((underlyings(64,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(64,2) <= 840.)) goto L50; + if ((underlyings(64,1) <= 8288.)) goto L50; + if ((underlyings(65,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(65,2) <= 840.)) goto L50; + if ((underlyings(65,1) <= 8288.)) goto L50; + if ((underlyings(66,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(66,2) <= 840.)) goto L50; + if ((underlyings(66,1) <= 8288.)) goto L50; + if ((underlyings(67,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(67,2) <= 840.)) goto L50; + if ((underlyings(67,1) <= 8288.)) goto L50; + if ((underlyings(68,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(68,2) <= 840.)) goto L50; + if ((underlyings(68,1) <= 8288.)) goto L50; + if ((underlyings(69,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(69,2) <= 840.)) goto L50; + if ((underlyings(69,1) <= 8288.)) goto L50; + if ((underlyings(70,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(70,2) <= 840.)) goto L50; + if ((underlyings(70,1) <= 8288.)) goto L50; + if ((underlyings(71,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(71,2) <= 840.)) goto L50; + if ((underlyings(71,1) <= 8288.)) goto L50; + if ((underlyings(72,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(72,2) <= 840.)) goto L50; + if ((underlyings(72,1) <= 8288.)) goto L50; + if ((underlyings(73,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(73,2) <= 840.)) goto L50; + if ((underlyings(73,1) <= 8288.)) goto L50; + if ((underlyings(74,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(74,2) <= 840.)) goto L50; + if ((underlyings(74,1) <= 8288.)) goto L50; + if ((underlyings(75,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(75,2) <= 840.)) goto L50; + if ((underlyings(75,1) <= 8288.)) goto L50; + if ((underlyings(76,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(76,2) <= 840.)) goto L50; + if ((underlyings(76,1) <= 8288.)) goto L50; + if ((underlyings(77,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(77,2) <= 840.)) goto L50; + if ((underlyings(77,1) <= 8288.)) goto L50; + if ((underlyings(78,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(78,2) <= 840.)) goto L50; + if ((underlyings(78,1) <= 8288.)) goto L50; + if ((underlyings(79,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(79,2) <= 840.)) goto L50; + if ((underlyings(79,1) <= 8288.)) goto L50; + if ((underlyings(80,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(80,2) <= 840.)) goto L50; + if ((underlyings(80,1) <= 8288.)) goto L50; + if ((underlyings(81,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(81,2) <= 840.)) goto L50; + if ((underlyings(81,1) <= 8288.)) goto L50; + if ((underlyings(82,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(82,2) <= 840.)) goto L50; + if ((underlyings(82,1) <= 8288.)) goto L50; + if ((underlyings(83,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(83,2) <= 840.)) goto L50; + if ((underlyings(83,1) <= 8288.)) goto L50; + if ((underlyings(84,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(84,2) <= 840.)) goto L50; + if ((underlyings(84,1) <= 8288.)) goto L50; + if ((underlyings(85,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(85,2) <= 840.)) goto L50; + if ((underlyings(85,1) <= 8288.)) goto L50; + if ((underlyings(86,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(86,2) <= 840.)) goto L50; + if ((underlyings(86,1) <= 8288.)) goto L50; + if ((underlyings(87,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(87,2) <= 840.)) goto L50; + if ((underlyings(87,1) <= 8288.)) goto L50; + if ((underlyings(88,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(88,2) <= 840.)) goto L50; + if ((underlyings(88,1) <= 8288.)) goto L50; + if ((underlyings(89,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(89,2) <= 840.)) goto L50; + if ((underlyings(89,1) <= 8288.)) goto L50; + if ((underlyings(90,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(90,2) <= 840.)) goto L50; + if ((underlyings(90,1) <= 8288.)) goto L50; + if ((underlyings(91,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(91,2) <= 840.)) goto L50; + if ((underlyings(91,1) <= 8288.)) goto L50; + if ((underlyings(92,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(92,2) <= 840.)) goto L50; + if ((underlyings(92,1) <= 8288.)) goto L50; + if ((underlyings(93,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(93,2) <= 840.)) goto L50; + if ((underlyings(93,1) <= 8288.)) goto L50; + if ((underlyings(94,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(94,2) <= 840.)) goto L50; + if ((underlyings(94,1) <= 8288.)) goto L50; + if ((underlyings(95,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(95,2) <= 840.)) goto L50; + if ((underlyings(95,1) <= 8288.)) goto L50; + if ((underlyings(96,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(96,2) <= 840.)) goto L50; + if ((underlyings(96,1) <= 8288.)) goto L50; + if ((underlyings(97,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(97,2) <= 840.)) goto L50; + if ((underlyings(97,1) <= 8288.)) goto L50; + if ((underlyings(98,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(98,2) <= 840.)) goto L50; + if ((underlyings(98,1) <= 8288.)) goto L50; + if ((underlyings(99,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(99,2) <= 840.)) goto L50; + if ((underlyings(99,1) <= 8288.)) goto L50; + if ((underlyings(100,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(100,2) <= 840.)) goto L50; + if ((underlyings(100,1) <= 8288.)) goto L50; + if ((underlyings(101,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(101,2) <= 840.)) goto L50; + if ((underlyings(101,1) <= 8288.)) goto L50; + if ((underlyings(102,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(102,2) <= 840.)) goto L50; + if ((underlyings(102,1) <= 8288.)) goto L50; + if ((underlyings(103,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(103,2) <= 840.)) goto L50; + if ((underlyings(103,1) <= 8288.)) goto L50; + if ((underlyings(104,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(104,2) <= 840.)) goto L50; + if ((underlyings(104,1) <= 8288.)) goto L50; + if ((underlyings(105,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(105,2) <= 840.)) goto L50; + if ((underlyings(105,1) <= 8288.)) goto L50; + if ((underlyings(106,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(106,2) <= 840.)) goto L50; + if ((underlyings(106,1) <= 8288.)) goto L50; + if ((underlyings(107,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(107,2) <= 840.)) goto L50; + if ((underlyings(107,1) <= 8288.)) goto L50; + if ((underlyings(108,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(108,2) <= 840.)) goto L50; + if ((underlyings(108,1) <= 8288.)) goto L50; + if ((underlyings(109,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(109,2) <= 840.)) goto L50; + if ((underlyings(109,1) <= 8288.)) goto L50; + if ((underlyings(110,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(110,2) <= 840.)) goto L50; + if ((underlyings(110,1) <= 8288.)) goto L50; + if ((underlyings(111,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(111,2) <= 840.)) goto L50; + if ((underlyings(111,1) <= 8288.)) goto L50; + if ((underlyings(112,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(112,2) <= 840.)) goto L50; + if ((underlyings(112,1) <= 8288.)) goto L50; + if ((underlyings(113,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(113,2) <= 840.)) goto L50; + if ((underlyings(113,1) <= 8288.)) goto L50; + if ((underlyings(114,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(114,2) <= 840.)) goto L50; + if ((underlyings(114,1) <= 8288.)) goto L50; + if ((underlyings(115,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(115,2) <= 840.)) goto L50; + if ((underlyings(115,1) <= 8288.)) goto L50; + if ((underlyings(116,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(116,2) <= 840.)) goto L50; + if ((underlyings(116,1) <= 8288.)) goto L50; + if ((underlyings(117,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(117,2) <= 840.)) goto L50; + if ((underlyings(117,1) <= 8288.)) goto L50; + if ((underlyings(118,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(118,2) <= 840.)) goto L50; + if ((underlyings(118,1) <= 8288.)) goto L50; + if ((underlyings(119,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(119,2) <= 840.)) goto L50; + if ((underlyings(119,1) <= 8288.)) goto L50; + if ((underlyings(120,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(120,2) <= 840.)) goto L50; + if ((underlyings(120,1) <= 8288.)) goto L50; + if ((underlyings(121,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(121,2) <= 840.)) goto L50; + if ((underlyings(121,1) <= 8288.)) goto L50; + if ((underlyings(122,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(122,2) <= 840.)) goto L50; + if ((underlyings(122,1) <= 8288.)) goto L50; + if ((underlyings(123,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(123,2) <= 840.)) goto L50; + if ((underlyings(123,1) <= 8288.)) goto L50; + if ((underlyings(124,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(124,2) <= 840.)) goto L50; + if ((underlyings(124,1) <= 8288.)) goto L50; + if ((underlyings(125,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(125,2) <= 840.)) goto L50; + if ((underlyings(125,1) <= 8288.)) goto L50; + if ((underlyings(126,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(126,2) <= 840.)) goto L50; + if ((underlyings(126,1) <= 8288.)) goto L50; + if ((underlyings(127,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(127,2) <= 840.)) goto L50; + if ((underlyings(127,1) <= 8288.)) goto L50; + if ((underlyings(128,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(128,2) <= 840.)) goto L50; + if ((underlyings(128,1) <= 8288.)) goto L50; + if ((underlyings(129,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(129,2) <= 840.)) goto L50; + if ((underlyings(129,1) <= 8288.)) goto L50; + if ((underlyings(130,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(130,2) <= 840.)) goto L50; + if ((underlyings(130,1) <= 8288.)) goto L50; + if ((underlyings(131,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(131,2) <= 840.)) goto L50; + if ((underlyings(131,1) <= 8288.)) goto L50; + if ((underlyings(132,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(132,2) <= 840.)) goto L50; + if ((underlyings(132,1) <= 8288.)) goto L50; + if ((underlyings(133,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(133,2) <= 840.)) goto L50; + if ((underlyings(133,1) <= 8288.)) goto L50; + if ((underlyings(134,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(134,2) <= 840.)) goto L50; + if ((underlyings(134,1) <= 8288.)) goto L50; + if ((underlyings(135,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(135,2) <= 840.)) goto L50; + if ((underlyings(135,1) <= 8288.)) goto L50; + if ((underlyings(136,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(136,2) <= 840.)) goto L50; + if ((underlyings(136,1) <= 8288.)) goto L50; + if ((underlyings(137,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(137,2) <= 840.)) goto L50; + if ((underlyings(137,1) <= 8288.)) goto L50; + if ((underlyings(138,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(138,2) <= 840.)) goto L50; + if ((underlyings(138,1) <= 8288.)) goto L50; + if ((underlyings(139,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(139,2) <= 840.)) goto L50; + if ((underlyings(139,1) <= 8288.)) goto L50; + if ((underlyings(140,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(140,2) <= 840.)) goto L50; + if ((underlyings(140,1) <= 8288.)) goto L50; + if ((underlyings(141,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(141,2) <= 840.)) goto L50; + if ((underlyings(141,1) <= 8288.)) goto L50; + if ((underlyings(142,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(142,2) <= 840.)) goto L50; + if ((underlyings(142,1) <= 8288.)) goto L50; + if ((underlyings(143,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(143,2) <= 840.)) goto L50; + if ((underlyings(143,1) <= 8288.)) goto L50; + if ((underlyings(144,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(144,2) <= 840.)) goto L50; + if ((underlyings(144,1) <= 8288.)) goto L50; + if ((underlyings(145,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(145,2) <= 840.)) goto L50; + if ((underlyings(145,1) <= 8288.)) goto L50; + if ((underlyings(146,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(146,2) <= 840.)) goto L50; + if ((underlyings(146,1) <= 8288.)) goto L50; + if ((underlyings(147,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(147,2) <= 840.)) goto L50; + if ((underlyings(147,1) <= 8288.)) goto L50; + if ((underlyings(148,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(148,2) <= 840.)) goto L50; + if ((underlyings(148,1) <= 8288.)) goto L50; + if ((underlyings(149,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(149,2) <= 840.)) goto L50; + if ((underlyings(149,1) <= 8288.)) goto L50; + if ((underlyings(150,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(150,2) <= 840.)) goto L50; + if ((underlyings(150,1) <= 8288.)) goto L50; + if ((underlyings(151,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(151,2) <= 840.)) goto L50; + if ((underlyings(151,1) <= 8288.)) goto L50; + if ((underlyings(152,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(152,2) <= 840.)) goto L50; + if ((underlyings(152,1) <= 8288.)) goto L50; + if ((underlyings(153,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(153,2) <= 840.)) goto L50; + if ((underlyings(153,1) <= 8288.)) goto L50; + if ((underlyings(154,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(154,2) <= 840.)) goto L50; + if ((underlyings(154,1) <= 8288.)) goto L50; + if ((underlyings(155,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(155,2) <= 840.)) goto L50; + if ((underlyings(155,1) <= 8288.)) goto L50; + if ((underlyings(156,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(156,2) <= 840.)) goto L50; + if ((underlyings(156,1) <= 8288.)) goto L50; + if ((underlyings(157,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(157,2) <= 840.)) goto L50; + if ((underlyings(157,1) <= 8288.)) goto L50; + if ((underlyings(158,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(158,2) <= 840.)) goto L50; + if ((underlyings(158,1) <= 8288.)) goto L50; + if ((underlyings(159,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(159,2) <= 840.)) goto L50; + if ((underlyings(159,1) <= 8288.)) goto L50; + if ((underlyings(160,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(160,2) <= 840.)) goto L50; + if ((underlyings(160,1) <= 8288.)) goto L50; + if ((underlyings(161,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(161,2) <= 840.)) goto L50; + if ((underlyings(161,1) <= 8288.)) goto L50; + if ((underlyings(162,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(162,2) <= 840.)) goto L50; + if ((underlyings(162,1) <= 8288.)) goto L50; + if ((underlyings(163,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(163,2) <= 840.)) goto L50; + if ((underlyings(163,1) <= 8288.)) goto L50; + if ((underlyings(164,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(164,2) <= 840.)) goto L50; + if ((underlyings(164,1) <= 8288.)) goto L50; + if ((underlyings(165,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(165,2) <= 840.)) goto L50; + if ((underlyings(165,1) <= 8288.)) goto L50; + if ((underlyings(166,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(166,2) <= 840.)) goto L50; + if ((underlyings(166,1) <= 8288.)) goto L50; + if ((underlyings(167,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(167,2) <= 840.)) goto L50; + if ((underlyings(167,1) <= 8288.)) goto L50; + if ((underlyings(168,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(168,2) <= 840.)) goto L50; + if ((underlyings(168,1) <= 8288.)) goto L50; + if ((underlyings(169,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(169,2) <= 840.)) goto L50; + if ((underlyings(169,1) <= 8288.)) goto L50; + if ((underlyings(170,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(170,2) <= 840.)) goto L50; + if ((underlyings(170,1) <= 8288.)) goto L50; + if ((underlyings(171,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(171,2) <= 840.)) goto L50; + if ((underlyings(171,1) <= 8288.)) goto L50; + if ((underlyings(172,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(172,2) <= 840.)) goto L50; + if ((underlyings(172,1) <= 8288.)) goto L50; + if ((underlyings(173,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(173,2) <= 840.)) goto L50; + if ((underlyings(173,1) <= 8288.)) goto L50; + if ((underlyings(174,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(174,2) <= 840.)) goto L50; + if ((underlyings(174,1) <= 8288.)) goto L50; + if ((underlyings(175,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(175,2) <= 840.)) goto L50; + if ((underlyings(175,1) <= 8288.)) goto L50; + if ((underlyings(176,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(176,2) <= 840.)) goto L50; + if ((underlyings(176,1) <= 8288.)) goto L50; + if ((underlyings(177,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(177,2) <= 840.)) goto L50; + if ((underlyings(177,1) <= 8288.)) goto L50; + if ((underlyings(178,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(178,2) <= 840.)) goto L50; + if ((underlyings(178,1) <= 8288.)) goto L50; + if ((underlyings(179,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(179,2) <= 840.)) goto L50; + if ((underlyings(179,1) <= 8288.)) goto L50; + if ((underlyings(180,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(180,2) <= 840.)) goto L50; + if ((underlyings(180,1) <= 8288.)) goto L50; + if ((underlyings(181,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(181,2) <= 840.)) goto L50; + if ((underlyings(181,1) <= 8288.)) goto L50; + if ((underlyings(182,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(182,2) <= 840.)) goto L50; + if ((underlyings(182,1) <= 8288.)) goto L50; + if ((underlyings(183,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(183,2) <= 840.)) goto L50; + if ((underlyings(183,1) <= 8288.)) goto L50; + if ((underlyings(184,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(184,2) <= 840.)) goto L50; + if ((underlyings(184,1) <= 8288.)) goto L50; + if ((underlyings(185,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(185,2) <= 840.)) goto L50; + if ((underlyings(185,1) <= 8288.)) goto L50; + if ((underlyings(186,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(186,2) <= 840.)) goto L50; + if ((underlyings(186,1) <= 8288.)) goto L50; + if ((underlyings(187,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(187,2) <= 840.)) goto L50; + if ((underlyings(187,1) <= 8288.)) goto L50; + if ((underlyings(188,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(188,2) <= 840.)) goto L50; + if ((underlyings(188,1) <= 8288.)) goto L50; + if ((underlyings(189,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(189,2) <= 840.)) goto L50; + if ((underlyings(189,1) <= 8288.)) goto L50; + if ((underlyings(190,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(190,2) <= 840.)) goto L50; + if ((underlyings(190,1) <= 8288.)) goto L50; + if ((underlyings(191,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(191,2) <= 840.)) goto L50; + if ((underlyings(191,1) <= 8288.)) goto L50; + if ((underlyings(192,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(192,2) <= 840.)) goto L50; + if ((underlyings(192,1) <= 8288.)) goto L50; + if ((underlyings(193,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(193,2) <= 840.)) goto L50; + if ((underlyings(193,1) <= 8288.)) goto L50; + if ((underlyings(194,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(194,2) <= 840.)) goto L50; + if ((underlyings(194,1) <= 8288.)) goto L50; + if ((underlyings(195,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(195,2) <= 840.)) goto L50; + if ((underlyings(195,1) <= 8288.)) goto L50; + if ((underlyings(196,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(196,2) <= 840.)) goto L50; + if ((underlyings(196,1) <= 8288.)) goto L50; + if ((underlyings(197,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(197,2) <= 840.)) goto L50; + if ((underlyings(197,1) <= 8288.)) goto L50; + if ((underlyings(198,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(198,2) <= 840.)) goto L50; + if ((underlyings(198,1) <= 8288.)) goto L50; + if ((underlyings(199,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(199,2) <= 840.)) goto L50; + if ((underlyings(199,1) <= 8288.)) goto L50; + if ((underlyings(200,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(200,2) <= 840.)) goto L50; + if ((underlyings(200,1) <= 8288.)) goto L50; + if ((underlyings(201,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(201,2) <= 840.)) goto L50; + if ((underlyings(201,1) <= 8288.)) goto L50; + if ((underlyings(202,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(202,2) <= 840.)) goto L50; + if ((underlyings(202,1) <= 8288.)) goto L50; + if ((underlyings(203,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(203,2) <= 840.)) goto L50; + if ((underlyings(203,1) <= 8288.)) goto L50; + if ((underlyings(204,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(204,2) <= 840.)) goto L50; + if ((underlyings(204,1) <= 8288.)) goto L50; + if ((underlyings(205,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(205,2) <= 840.)) goto L50; + if ((underlyings(205,1) <= 8288.)) goto L50; + if ((underlyings(206,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(206,2) <= 840.)) goto L50; + if ((underlyings(206,1) <= 8288.)) goto L50; + if ((underlyings(207,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(207,2) <= 840.)) goto L50; + if ((underlyings(207,1) <= 8288.)) goto L50; + if ((underlyings(208,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(208,2) <= 840.)) goto L50; + if ((underlyings(208,1) <= 8288.)) goto L50; + if ((underlyings(209,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(209,2) <= 840.)) goto L50; + if ((underlyings(209,1) <= 8288.)) goto L50; + if ((underlyings(210,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(210,2) <= 840.)) goto L50; + if ((underlyings(210,1) <= 8288.)) goto L50; + if ((underlyings(211,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(211,2) <= 840.)) goto L50; + if ((underlyings(211,1) <= 8288.)) goto L50; + if ((underlyings(212,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(212,2) <= 840.)) goto L50; + if ((underlyings(212,1) <= 8288.)) goto L50; + if ((underlyings(213,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(213,2) <= 840.)) goto L50; + if ((underlyings(213,1) <= 8288.)) goto L50; + if ((underlyings(214,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(214,2) <= 840.)) goto L50; + if ((underlyings(214,1) <= 8288.)) goto L50; + if ((underlyings(215,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(215,2) <= 840.)) goto L50; + if ((underlyings(215,1) <= 8288.)) goto L50; + if ((underlyings(216,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(216,2) <= 840.)) goto L50; + if ((underlyings(216,1) <= 8288.)) goto L50; + if ((underlyings(217,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(217,2) <= 840.)) goto L50; + if ((underlyings(217,1) <= 8288.)) goto L50; + if ((underlyings(218,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(218,2) <= 840.)) goto L50; + if ((underlyings(218,1) <= 8288.)) goto L50; + if ((underlyings(219,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(219,2) <= 840.)) goto L50; + if ((underlyings(219,1) <= 8288.)) goto L50; + if ((underlyings(220,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(220,2) <= 840.)) goto L50; + if ((underlyings(220,1) <= 8288.)) goto L50; + if ((underlyings(221,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(221,2) <= 840.)) goto L50; + if ((underlyings(221,1) <= 8288.)) goto L50; + if ((underlyings(222,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(222,2) <= 840.)) goto L50; + if ((underlyings(222,1) <= 8288.)) goto L50; + if ((underlyings(223,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(223,2) <= 840.)) goto L50; + if ((underlyings(223,1) <= 8288.)) goto L50; + if ((underlyings(224,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(224,2) <= 840.)) goto L50; + if ((underlyings(224,1) <= 8288.)) goto L50; + if ((underlyings(225,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(225,2) <= 840.)) goto L50; + if ((underlyings(225,1) <= 8288.)) goto L50; + if ((underlyings(226,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(226,2) <= 840.)) goto L50; + if ((underlyings(226,1) <= 8288.)) goto L50; + if ((underlyings(227,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(227,2) <= 840.)) goto L50; + if ((underlyings(227,1) <= 8288.)) goto L50; + if ((underlyings(228,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(228,2) <= 840.)) goto L50; + if ((underlyings(228,1) <= 8288.)) goto L50; + if ((underlyings(229,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(229,2) <= 840.)) goto L50; + if ((underlyings(229,1) <= 8288.)) goto L50; + if ((underlyings(230,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(230,2) <= 840.)) goto L50; + if ((underlyings(230,1) <= 8288.)) goto L50; + if ((underlyings(231,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(231,2) <= 840.)) goto L50; + if ((underlyings(231,1) <= 8288.)) goto L50; + if ((underlyings(232,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(232,2) <= 840.)) goto L50; + if ((underlyings(232,1) <= 8288.)) goto L50; + if ((underlyings(233,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(233,2) <= 840.)) goto L50; + if ((underlyings(233,1) <= 8288.)) goto L50; + if ((underlyings(234,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(234,2) <= 840.)) goto L50; + if ((underlyings(234,1) <= 8288.)) goto L50; + if ((underlyings(235,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(235,2) <= 840.)) goto L50; + if ((underlyings(235,1) <= 8288.)) goto L50; + if ((underlyings(236,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(236,2) <= 840.)) goto L50; + if ((underlyings(236,1) <= 8288.)) goto L50; + if ((underlyings(237,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(237,2) <= 840.)) goto L50; + if ((underlyings(237,1) <= 8288.)) goto L50; + if ((underlyings(238,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(238,2) <= 840.)) goto L50; + if ((underlyings(238,1) <= 8288.)) goto L50; + if ((underlyings(239,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(239,2) <= 840.)) goto L50; + if ((underlyings(239,1) <= 8288.)) goto L50; + if ((underlyings(240,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(240,2) <= 840.)) goto L50; + if ((underlyings(240,1) <= 8288.)) goto L50; + if ((underlyings(241,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(241,2) <= 840.)) goto L50; + if ((underlyings(241,1) <= 8288.)) goto L50; + if ((underlyings(242,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(242,2) <= 840.)) goto L50; + if ((underlyings(242,1) <= 8288.)) goto L50; + if ((underlyings(243,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(243,2) <= 840.)) goto L50; + if ((underlyings(243,1) <= 8288.)) goto L50; + if ((underlyings(244,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(244,2) <= 840.)) goto L50; + if ((underlyings(244,1) <= 8288.)) goto L50; + if ((underlyings(245,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(245,2) <= 840.)) goto L50; + if ((underlyings(245,1) <= 8288.)) goto L50; + if ((underlyings(246,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(246,2) <= 840.)) goto L50; + if ((underlyings(246,1) <= 8288.)) goto L50; + if ((underlyings(247,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(247,2) <= 840.)) goto L50; + if ((underlyings(247,1) <= 8288.)) goto L50; + if ((underlyings(248,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(248,2) <= 840.)) goto L50; + if ((underlyings(248,1) <= 8288.)) goto L50; + if ((underlyings(249,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(249,2) <= 840.)) goto L50; + if ((underlyings(249,1) <= 8288.)) goto L50; + if ((underlyings(250,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(250,2) <= 840.)) goto L50; + if ((underlyings(250,1) <= 8288.)) goto L50; + if ((underlyings(251,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(251,2) <= 840.)) goto L50; + if ((underlyings(251,1) <= 8288.)) goto L50; + if ((underlyings(252,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(252,2) <= 840.)) goto L50; + if ((underlyings(252,1) <= 8288.)) goto L50; + if ((underlyings(253,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(253,2) <= 840.)) goto L50; + if ((underlyings(253,1) <= 8288.)) goto L50; + if ((underlyings(254,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(254,2) <= 840.)) goto L50; + if ((underlyings(254,1) <= 8288.)) goto L50; + if ((underlyings(255,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(255,2) <= 840.)) goto L50; + if ((underlyings(255,1) <= 8288.)) goto L50; + if ((underlyings(256,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(256,2) <= 840.)) goto L50; + if ((underlyings(256,1) <= 8288.)) goto L50; + if ((underlyings(257,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(257,2) <= 840.)) goto L50; + if ((underlyings(257,1) <= 8288.)) goto L50; + if ((underlyings(258,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(258,2) <= 840.)) goto L50; + if ((underlyings(258,1) <= 8288.)) goto L50; + if ((underlyings(259,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(259,2) <= 840.)) goto L50; + if ((underlyings(259,1) <= 8288.)) goto L50; + if ((underlyings(260,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(260,2) <= 840.)) goto L50; + if ((underlyings(260,1) <= 8288.)) goto L50; + if ((underlyings(261,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(261,2) <= 840.)) goto L50; + if ((underlyings(261,1) <= 8288.)) goto L50; + if ((underlyings(262,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(262,2) <= 840.)) goto L50; + if ((underlyings(262,1) <= 8288.)) goto L50; + if ((underlyings(263,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(263,2) <= 840.)) goto L50; + if ((underlyings(263,1) <= 8288.)) goto L50; + if ((underlyings(264,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(264,2) <= 840.)) goto L50; + if ((underlyings(264,1) <= 8288.)) goto L50; + if ((underlyings(265,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(265,2) <= 840.)) goto L50; + if ((underlyings(265,1) <= 8288.)) goto L50; + if ((underlyings(266,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(266,2) <= 840.)) goto L50; + if ((underlyings(266,1) <= 8288.)) goto L50; + if ((underlyings(267,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(267,2) <= 840.)) goto L50; + if ((underlyings(267,1) <= 8288.)) goto L50; + if ((underlyings(268,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(268,2) <= 840.)) goto L50; + if ((underlyings(268,1) <= 8288.)) goto L50; + if ((underlyings(269,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(269,2) <= 840.)) goto L50; + if ((underlyings(269,1) <= 8288.)) goto L50; + if ((underlyings(270,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(270,2) <= 840.)) goto L50; + if ((underlyings(270,1) <= 8288.)) goto L50; + if ((underlyings(271,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(271,2) <= 840.)) goto L50; + if ((underlyings(271,1) <= 8288.)) goto L50; + if ((underlyings(272,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(272,2) <= 840.)) goto L50; + if ((underlyings(272,1) <= 8288.)) goto L50; + if ((underlyings(273,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(273,2) <= 840.)) goto L50; + if ((underlyings(273,1) <= 8288.)) goto L50; + if ((underlyings(274,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(274,2) <= 840.)) goto L50; + if ((underlyings(274,1) <= 8288.)) goto L50; + if ((underlyings(275,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(275,2) <= 840.)) goto L50; + if ((underlyings(275,1) <= 8288.)) goto L50; + if ((underlyings(276,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(276,2) <= 840.)) goto L50; + if ((underlyings(276,1) <= 8288.)) goto L50; + if ((underlyings(277,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(277,2) <= 840.)) goto L50; + if ((underlyings(277,1) <= 8288.)) goto L50; + if ((underlyings(278,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(278,2) <= 840.)) goto L50; + if ((underlyings(278,1) <= 8288.)) goto L50; + if ((underlyings(279,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(279,2) <= 840.)) goto L50; + if ((underlyings(279,1) <= 8288.)) goto L50; + if ((underlyings(280,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(280,2) <= 840.)) goto L50; + if ((underlyings(280,1) <= 8288.)) goto L50; + if ((underlyings(281,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(281,2) <= 840.)) goto L50; + if ((underlyings(281,1) <= 8288.)) goto L50; + if ((underlyings(282,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(282,2) <= 840.)) goto L50; + if ((underlyings(282,1) <= 8288.)) goto L50; + if ((underlyings(283,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(283,2) <= 840.)) goto L50; + if ((underlyings(283,1) <= 8288.)) goto L50; + if ((underlyings(284,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(284,2) <= 840.)) goto L50; + if ((underlyings(284,1) <= 8288.)) goto L50; + if ((underlyings(285,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(285,2) <= 840.)) goto L50; + if ((underlyings(285,1) <= 8288.)) goto L50; + if ((underlyings(286,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(286,2) <= 840.)) goto L50; + if ((underlyings(286,1) <= 8288.)) goto L50; + if ((underlyings(287,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(287,2) <= 840.)) goto L50; + if ((underlyings(287,1) <= 8288.)) goto L50; + if ((underlyings(288,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(288,2) <= 840.)) goto L50; + if ((underlyings(288,1) <= 8288.)) goto L50; + if ((underlyings(289,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(289,2) <= 840.)) goto L50; + if ((underlyings(289,1) <= 8288.)) goto L50; + if ((underlyings(290,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(290,2) <= 840.)) goto L50; + if ((underlyings(290,1) <= 8288.)) goto L50; + if ((underlyings(291,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(291,2) <= 840.)) goto L50; + if ((underlyings(291,1) <= 8288.)) goto L50; + if ((underlyings(292,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(292,2) <= 840.)) goto L50; + if ((underlyings(292,1) <= 8288.)) goto L50; + if ((underlyings(293,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(293,2) <= 840.)) goto L50; + if ((underlyings(293,1) <= 8288.)) goto L50; + if ((underlyings(294,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(294,2) <= 840.)) goto L50; + if ((underlyings(294,1) <= 8288.)) goto L50; + if ((underlyings(295,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(295,2) <= 840.)) goto L50; + if ((underlyings(295,1) <= 8288.)) goto L50; + if ((underlyings(296,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(296,2) <= 840.)) goto L50; + if ((underlyings(296,1) <= 8288.)) goto L50; + if ((underlyings(297,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(297,2) <= 840.)) goto L50; + if ((underlyings(297,1) <= 8288.)) goto L50; + if ((underlyings(298,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(298,2) <= 840.)) goto L50; + if ((underlyings(298,1) <= 8288.)) goto L50; + if ((underlyings(299,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(299,2) <= 840.)) goto L50; + if ((underlyings(299,1) <= 8288.)) goto L50; + if ((underlyings(300,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(300,2) <= 840.)) goto L50; + if ((underlyings(300,1) <= 8288.)) goto L50; + if ((underlyings(301,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(301,2) <= 840.)) goto L50; + if ((underlyings(301,1) <= 8288.)) goto L50; + if ((underlyings(302,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(302,2) <= 840.)) goto L50; + if ((underlyings(302,1) <= 8288.)) goto L50; + if ((underlyings(303,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(303,2) <= 840.)) goto L50; + if ((underlyings(303,1) <= 8288.)) goto L50; + if ((underlyings(304,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(304,2) <= 840.)) goto L50; + if ((underlyings(304,1) <= 8288.)) goto L50; + if ((underlyings(305,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(305,2) <= 840.)) goto L50; + if ((underlyings(305,1) <= 8288.)) goto L50; + if ((underlyings(306,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(306,2) <= 840.)) goto L50; + if ((underlyings(306,1) <= 8288.)) goto L50; + if ((underlyings(307,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(307,2) <= 840.)) goto L50; + if ((underlyings(307,1) <= 8288.)) goto L50; + if ((underlyings(308,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(308,2) <= 840.)) goto L50; + if ((underlyings(308,1) <= 8288.)) goto L50; + if ((underlyings(309,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(309,2) <= 840.)) goto L50; + if ((underlyings(309,1) <= 8288.)) goto L50; + if ((underlyings(310,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(310,2) <= 840.)) goto L50; + if ((underlyings(310,1) <= 8288.)) goto L50; + if ((underlyings(311,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(311,2) <= 840.)) goto L50; + if ((underlyings(311,1) <= 8288.)) goto L50; + if ((underlyings(312,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(312,2) <= 840.)) goto L50; + if ((underlyings(312,1) <= 8288.)) goto L50; + if ((underlyings(313,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(313,2) <= 840.)) goto L50; + if ((underlyings(313,1) <= 8288.)) goto L50; + if ((underlyings(314,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(314,2) <= 840.)) goto L50; + if ((underlyings(314,1) <= 8288.)) goto L50; + if ((underlyings(315,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(315,2) <= 840.)) goto L50; + if ((underlyings(315,1) <= 8288.)) goto L50; + if ((underlyings(316,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(316,2) <= 840.)) goto L50; + if ((underlyings(316,1) <= 8288.)) goto L50; + if ((underlyings(317,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(317,2) <= 840.)) goto L50; + if ((underlyings(317,1) <= 8288.)) goto L50; + if ((underlyings(318,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(318,2) <= 840.)) goto L50; + if ((underlyings(318,1) <= 8288.)) goto L50; + if ((underlyings(319,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(319,2) <= 840.)) goto L50; + if ((underlyings(319,1) <= 8288.)) goto L50; + if ((underlyings(320,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(320,2) <= 840.)) goto L50; + if ((underlyings(320,1) <= 8288.)) goto L50; + if ((underlyings(321,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(321,2) <= 840.)) goto L50; + if ((underlyings(321,1) <= 8288.)) goto L50; + if ((underlyings(322,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(322,2) <= 840.)) goto L50; + if ((underlyings(322,1) <= 8288.)) goto L50; + if ((underlyings(323,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(323,2) <= 840.)) goto L50; + if ((underlyings(323,1) <= 8288.)) goto L50; + if ((underlyings(324,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(324,2) <= 840.)) goto L50; + if ((underlyings(324,1) <= 8288.)) goto L50; + if ((underlyings(325,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(325,2) <= 840.)) goto L50; + if ((underlyings(325,1) <= 8288.)) goto L50; + if ((underlyings(326,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(326,2) <= 840.)) goto L50; + if ((underlyings(326,1) <= 8288.)) goto L50; + if ((underlyings(327,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(327,2) <= 840.)) goto L50; + if ((underlyings(327,1) <= 8288.)) goto L50; + if ((underlyings(328,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(328,2) <= 840.)) goto L50; + if ((underlyings(328,1) <= 8288.)) goto L50; + if ((underlyings(329,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(329,2) <= 840.)) goto L50; + if ((underlyings(329,1) <= 8288.)) goto L50; + if ((underlyings(330,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(330,2) <= 840.)) goto L50; + if ((underlyings(330,1) <= 8288.)) goto L50; + if ((underlyings(331,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(331,2) <= 840.)) goto L50; + if ((underlyings(331,1) <= 8288.)) goto L50; + if ((underlyings(332,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(332,2) <= 840.)) goto L50; + if ((underlyings(332,1) <= 8288.)) goto L50; + if ((underlyings(333,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(333,2) <= 840.)) goto L50; + if ((underlyings(333,1) <= 8288.)) goto L50; + if ((underlyings(334,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(334,2) <= 840.)) goto L50; + if ((underlyings(334,1) <= 8288.)) goto L50; + if ((underlyings(335,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(335,2) <= 840.)) goto L50; + if ((underlyings(335,1) <= 8288.)) goto L50; + if ((underlyings(336,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(336,2) <= 840.)) goto L50; + if ((underlyings(336,1) <= 8288.)) goto L50; + if ((underlyings(337,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(337,2) <= 840.)) goto L50; + if ((underlyings(337,1) <= 8288.)) goto L50; + if ((underlyings(338,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(338,2) <= 840.)) goto L50; + if ((underlyings(338,1) <= 8288.)) goto L50; + if ((underlyings(339,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(339,2) <= 840.)) goto L50; + if ((underlyings(339,1) <= 8288.)) goto L50; + if ((underlyings(340,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(340,2) <= 840.)) goto L50; + if ((underlyings(340,1) <= 8288.)) goto L50; + if ((underlyings(341,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(341,2) <= 840.)) goto L50; + if ((underlyings(341,1) <= 8288.)) goto L50; + if ((underlyings(342,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(342,2) <= 840.)) goto L50; + if ((underlyings(342,1) <= 8288.)) goto L50; + if ((underlyings(343,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(343,2) <= 840.)) goto L50; + if ((underlyings(343,1) <= 8288.)) goto L50; + if ((underlyings(344,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(344,2) <= 840.)) goto L50; + if ((underlyings(344,1) <= 8288.)) goto L50; + if ((underlyings(345,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(345,2) <= 840.)) goto L50; + if ((underlyings(345,1) <= 8288.)) goto L50; + if ((underlyings(346,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(346,2) <= 840.)) goto L50; + if ((underlyings(346,1) <= 8288.)) goto L50; + if ((underlyings(347,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(347,2) <= 840.)) goto L50; + if ((underlyings(347,1) <= 8288.)) goto L50; + if ((underlyings(348,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(348,2) <= 840.)) goto L50; + if ((underlyings(348,1) <= 8288.)) goto L50; + if ((underlyings(349,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(349,2) <= 840.)) goto L50; + if ((underlyings(349,1) <= 8288.)) goto L50; + if ((underlyings(350,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(350,2) <= 840.)) goto L50; + if ((underlyings(350,1) <= 8288.)) goto L50; + if ((underlyings(351,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(351,2) <= 840.)) goto L50; + if ((underlyings(351,1) <= 8288.)) goto L50; + if ((underlyings(352,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(352,2) <= 840.)) goto L50; + if ((underlyings(352,1) <= 8288.)) goto L50; + if ((underlyings(353,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(353,2) <= 840.)) goto L50; + if ((underlyings(353,1) <= 8288.)) goto L50; + if ((underlyings(354,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(354,2) <= 840.)) goto L50; + if ((underlyings(354,1) <= 8288.)) goto L50; + if ((underlyings(355,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(355,2) <= 840.)) goto L50; + if ((underlyings(355,1) <= 8288.)) goto L50; + if ((underlyings(356,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(356,2) <= 840.)) goto L50; + if ((underlyings(356,1) <= 8288.)) goto L50; + if ((underlyings(357,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(357,2) <= 840.)) goto L50; + if ((underlyings(357,1) <= 8288.)) goto L50; + if ((underlyings(358,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(358,2) <= 840.)) goto L50; + if ((underlyings(358,1) <= 8288.)) goto L50; + if ((underlyings(359,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(359,2) <= 840.)) goto L50; + if ((underlyings(359,1) <= 8288.)) goto L50; + if ((underlyings(360,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(360,2) <= 840.)) goto L50; + if ((underlyings(360,1) <= 8288.)) goto L50; + if ((underlyings(361,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(361,2) <= 840.)) goto L50; + if ((underlyings(361,1) <= 8288.)) goto L50; + if ((underlyings(362,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(362,2) <= 840.)) goto L50; + if ((underlyings(362,1) <= 8288.)) goto L50; + if ((underlyings(363,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(363,2) <= 840.)) goto L50; + if ((underlyings(363,1) <= 8288.)) goto L50; + if ((underlyings(364,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(364,2) <= 840.)) goto L50; + if ((underlyings(364,1) <= 8288.)) goto L50; + if ((underlyings(365,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(365,2) <= 840.)) goto L50; + if ((underlyings(365,1) <= 8288.)) goto L50; + if ((underlyings(366,0) <= 2630.6349999999998)) goto L50; + if ((underlyings(366,2) <= 840.)) goto L50; + x3309=(underlyings(366,1) <= 8288.); + goto L48; + +L50: + x3309=1; + +L48: + //model->notify_cash_flow(model, 0, 100., 0 /*2013-01-27, 1980-01-01, EUR*/); + trajectory_inner( num_cash_flows, model_num, 0, 100., md_discts, vhat ); + + if (((underlyings(366,0) < 3758.05) && x3309)) goto L40; + if (((underlyings(366,2) < 1200.) && x3309)) goto L40; + if (((underlyings(366,1) < 11840.) && x3309)) goto L40; + + //model->notify_cash_flow(model, 0, 1000., 1 /*2013-01-27, 2013-01-27, EUR*/); return; + trajectory_inner( num_cash_flows, model_num, 1, 1000., md_discts, vhat ); return; + +L40: + //model->notify_cash_flow(model, 0, (1000. * (1. + fmin(((underlyings(366,1) / 11840.) - 1.), fmin(((underlyings(366,2) / 1200.) - 1.), ((underlyings(366,0) / 3758.05) - 1.))))), 1 /*2013-01-27, 2013-01-27, EUR*/); + const real_t amount = (1000. * (1. + fmin(((underlyings(366,1) / 11840.) - 1.), fmin(((underlyings(366,2) / 1200.) - 1.), ((underlyings(366,0) / 3758.05) - 1.))))); + trajectory_inner( num_cash_flows, model_num, 1, amount, md_discts, vhat ); + + return; +} + +#define CONTRACT_NUM 2 + +inline +void aggregDiscountedPayoff( + const UINT& model_num, // the index of the current model + const UINT& contr_num, + const UINT& num_under, // the number of underlyings + const UINT& num_cash_flows, + const UINT& num_pricers,// the number of deterministic procers + const real_t* md_discts, // [num_models][num_scash_flow] discounts + const real_t* md_detvals, // [num_models, num_det_pricers] pricers + const real_t* inst_traj, // [num_dates, num_under] current trajectory + double* vhat // [model_num] Accumulated per-model price +) { + if (contr_num == 1) { +//#if (CONTRACT_NUM == 1) + trajectory_contract1(model_num, num_under, num_cash_flows, num_pricers, md_discts, md_detvals, inst_traj, vhat); + } else if (contr_num == 2) { +//#elif (CONTRACT_NUM == 2) + trajectory_contract2(model_num, num_under, num_cash_flows, num_pricers, md_discts, md_detvals, inst_traj, vhat); + } else if (contr_num == 3) { +//#elif (CONTRACT_NUM == 3) + trajectory_contract3(model_num, num_under, num_cash_flows, num_pricers, md_discts, md_detvals, inst_traj, vhat); + } else { +//#else + trajectory_contract1(model_num, num_under, num_cash_flows, num_pricers, md_discts, md_detvals, inst_traj, vhat); + } +//#endif + +} + +#endif //CONTRACTS_CODE + diff --git a/benchmarks/OptionPricing/lib/include/Optimizations.h b/benchmarks/OptionPricing/lib/include/Optimizations.h new file mode 100644 index 0000000..db6369f --- /dev/null +++ b/benchmarks/OptionPricing/lib/include/Optimizations.h @@ -0,0 +1,7 @@ +#ifndef OPTIMISATIONS +#define OPTIMISATIONS + +//#define _OPTIMIZATION_MEM_COALES_ON + +#endif // OPTIMISATIONS + diff --git a/OptionPricing/includeC/ParseInput.h b/benchmarks/OptionPricing/lib/include/ParseInput.h similarity index 76% rename from OptionPricing/includeC/ParseInput.h rename to benchmarks/OptionPricing/lib/include/ParseInput.h index 23da794..f7ec5f6 100644 --- a/OptionPricing/includeC/ParseInput.h +++ b/benchmarks/OptionPricing/lib/include/ParseInput.h @@ -14,7 +14,7 @@ /*******************************/ #define EPS 0.0005 -#if _OPTIMIZATION_USE_FLOATS +#if REAL_IS_FLOAT #define read_real read_float #else #define read_real read_double @@ -37,7 +37,7 @@ typedef struct { typedef struct { int * bb_inds; // [3, num_dates], i.e., bi, li, ri - REAL* bb_data; // [3, num_dates], i.e., sd, lw, rw + real_t* bb_data; // [3, num_dates], i.e., sd, lw, rw void cleanup() { free(bb_inds); free(bb_data); @@ -46,12 +46,12 @@ typedef struct { typedef struct { - REAL* md_c; // [num_models, num_under, num_under] - REAL* md_vols; // [num_models, num_dates, num_under] - REAL* md_drifts; // [num_models, num_dates, num_under] - REAL* md_starts; // [num_models, num_under] - REAL* md_discts; // [num_models, num_cash_flows] - REAL* md_detvals; // [num_models, num_det_pricers] + real_t* md_c; // [num_models, num_under, num_under] + real_t* md_vols; // [num_models, num_dates, num_under] + real_t* md_drifts; // [num_models, num_dates, num_under] + real_t* md_starts; // [num_models, num_under] + real_t* md_discts; // [num_models, num_cash_flows] + real_t* md_detvals; // [num_models, num_det_pricers] void cleanup() { free(md_c); // all allocated together, hence free the first one @@ -79,7 +79,7 @@ void computeSobolFixIndex( SobolArrays& sob_arrs, const UINT& chunk ) { // Given `chunk', the most-significant zero of iterations // {1 .. chunk-1} mod chunk is the same. - for( UINT k = 1; k < chunk-1; k ++ ) { + for( int k = 1; k < chunk-1; k ++ ) { UINT gs = k; UINT ell = 0; while(gs & 1) { @@ -128,7 +128,7 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, int sob_dim = scals.num_under * scals.num_dates; int alloc_size = do_padding ( (sob_dim * scals.sobol_bits) + (1 << logMAX_CHUNK) ); sob_arrs.sobol_dirvcts = static_cast ( malloc( do_padding( alloc_size ) * sizeof(int) ) ); - for( UINT j = 0; j < scals.sobol_bits; j++ ) { + for( int j = 0; j < scals.sobol_bits; j++ ) { for( int i = 0; i< sob_dim; i++ ) { sob_arrs.sobol_dirvcts[j*sob_dim + i] = sob_mat[i*scals.sobol_bits + j]; } @@ -142,7 +142,7 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, bool ok; // md_c - if (read_array(sizeof(REAL), read_real, (void**)&md_arrs.md_c, shape, 3) ) { + if (read_array(sizeof(real_t), read_real, (void**)&md_arrs.md_c, shape, 3) ) { fprintf(stderr, "Syntax error when reading md_c [%d,%d,%d].\n", scals.num_models, scals.num_under, scals.num_under); exit(1); @@ -153,7 +153,7 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, assert(ok && "Incorrect shape of md_c!"); // md_vols (volatility) - if (read_array(sizeof(REAL), read_real, (void**)&md_arrs.md_vols, shape, 3) ) { + if (read_array(sizeof(real_t), read_real, (void**)&md_arrs.md_vols, shape, 3) ) { fprintf(stderr, "Syntax error when reading md_vols [%d,%d,%d].\n", scals.num_models, scals.num_dates, scals.num_under); exit(1); @@ -164,7 +164,7 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, assert(ok && "Incorrect shape of md_vols!"); // md_drifts - if (read_array(sizeof(REAL), read_real, (void**)&md_arrs.md_drifts, shape, 3) ) { + if (read_array(sizeof(real_t), read_real, (void**)&md_arrs.md_drifts, shape, 3) ) { fprintf(stderr, "Syntax error when reading md_drifts [%d,%d,%d].\n", scals.num_models, scals.num_dates, scals.num_under); exit(1); @@ -175,7 +175,7 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, assert(ok && "Incorrect shape of md_drifts!"); // md_starts - if (read_array(sizeof(REAL), read_real, (void**)&md_arrs.md_starts, shape, 2) ) { + if (read_array(sizeof(real_t), read_real, (void**)&md_arrs.md_starts, shape, 2) ) { fprintf(stderr, "Syntax error when reading md_drifts [%d,%d].\n", scals.num_models, scals.num_under); exit(1); @@ -185,7 +185,7 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, assert(ok && "Incorrect shape of md_starts!"); // md_detvals (Model deterministic values) - if (read_array(sizeof(REAL), read_real, (void**)&md_arrs.md_detvals, shape, 2) ) { + if (read_array(sizeof(real_t), read_real, (void**)&md_arrs.md_detvals, shape, 2) ) { fprintf(stderr, "Syntax error when reading md_detvals [%d,..].\n", scals.num_models); exit(1); @@ -195,7 +195,7 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, scals.num_det_pricers = shape[1]; // md_discts (Model discounts) - if (read_array(sizeof(REAL), read_real, (void**)&md_arrs.md_discts, shape, 2) ) { + if (read_array(sizeof(real_t), read_real, (void**)&md_arrs.md_discts, shape, 2) ) { fprintf(stderr, "Syntax error when reading md_discts [%d,..].\n", scals.num_models); exit(1); @@ -206,13 +206,13 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, { // put all of them in a contiguous memory: int alloc_size, offset; - REAL* flat_arr; + real_t* flat_arr; alloc_size = scals.num_under * ( scals.num_under + 2*scals.num_dates + 1); alloc_size += scals.num_cash_flows + scals.num_det_pricers; alloc_size *= scals.num_models; alloc_size = do_padding( alloc_size ); - flat_arr = static_cast ( malloc( alloc_size * sizeof(REAL) ) ); + flat_arr = static_cast ( malloc( alloc_size * sizeof(real_t) ) ); // copy md_c offset = 0; @@ -268,7 +268,7 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, assert(ok && "Incorrect shape of bb_inds (brownian bridge indirect arrays)!"); // md_starts - if (read_array(sizeof(REAL), read_real, (void**)&bb_arrs.bb_data, shape, 2) ) { + if (read_array(sizeof(real_t), read_real, (void**)&bb_arrs.bb_data, shape, 2) ) { fprintf(stderr, "Syntax error when reading md_drifts [3,%d].\n", scals.num_dates ); exit(1); @@ -278,52 +278,4 @@ void readDataSet( LoopROScalars& scals, SobolArrays& sob_arrs, } } -/****************************************/ -/*** Validate w.r.t. Reference Result ***/ -/****************************************/ -bool validate( const int num_models, const double* prices ) { - bool is_valid = true; - double* std_prices; - int64_t shape[3]; - - if (read_array(sizeof(double), read_double, (void**)&std_prices, shape, 1) ) { - fprintf(stderr, "Syntax error when reading reference prices.\n"); - exit(1); - } - assert( (shape[0] == num_models) && "Incorrect shape of reference-price array!"); - - double err = 0.0; - for( int i = 0; i < num_models; i++ ) { - err = std::max( err, fabs(std_prices[i] - prices[i]) ); - if ( isnan(prices[i]) || isinf(prices[i]) ) err = 1000000.0; - } - - if ( err > EPS ) { - is_valid = false; - fprintf(stderr, "Error = %f, EPS = %f!\n", err, EPS); - } - - free(std_prices); - return is_valid; -} - -/**************************************/ -/*** Format the Result & Other Info ***/ -/**************************************/ -void writeStatsAndResult( const bool& valid, const int & num_models, - const double* prices, const bool& is_gpu, - const int& P, const unsigned long int& elapsed -) { - if(valid) { fprintf(stdout, "1\t\t// VALID Result,\n"); } - else { fprintf(stdout, "0\t\t// INVALID Result,\n"); } - - fprintf(stdout, "%ld\t\t// Runtime in micro seconds,\n", elapsed); - if(is_gpu) fprintf(stdout, "%d\t\t// GPU Threads,\n", P); - else fprintf(stdout, "%d\t\t// CPU Threads,\n", P); - - // write the result - write_1Darr( prices, num_models, "Generic Pricing Result." ); - //write_scal(&price, "Generic Pricing Result."); -} - #endif // PARSE_INPUT diff --git a/OptionPricing/includeC/SobolGaussBB.h b/benchmarks/OptionPricing/lib/include/SobolGaussBB.h similarity index 88% rename from OptionPricing/includeC/SobolGaussBB.h rename to benchmarks/OptionPricing/lib/include/SobolGaussBB.h index d6ae829..0b45daa 100644 --- a/OptionPricing/includeC/SobolGaussBB.h +++ b/benchmarks/OptionPricing/lib/include/SobolGaussBB.h @@ -85,8 +85,8 @@ sobolRecOpt( const int& sobol_dim, // size of the quasi-random vector (x*(x*(x*(x*(x*(x*(x*a7+a6)+a5)+a4)+a3)+a2)+a1)+a0)/ \ (x*(x*(x*(x*(x*(x*(x*b7+b6)+b5)+b4)+b3)+b2)+b1)+b0) -inline static REAL small_case(const REAL& q) { - REAL x = 0.180625 - q * q; +inline static real_t small_case(const real_t& q) { + real_t x = 0.180625 - q * q; return q * rat_eval( 3.387132872796366608, 133.14166789178437745, @@ -107,8 +107,8 @@ inline static REAL small_case(const REAL& q) { 5226.495278852854561); } -inline static REAL intermediate(const REAL& r) { - REAL x = r - 1.6; +inline static real_t intermediate(const real_t& r) { + real_t x = r - 1.6; return rat_eval( 1.42343711074968357734, 4.6303378461565452959, @@ -129,8 +129,8 @@ inline static REAL intermediate(const REAL& r) { 1.05075007164441684324e-9); } -inline static REAL tail(const REAL& r) { - REAL x = r - 5.0; +inline static real_t tail(const real_t& r) { + real_t x = r - 5.0; return rat_eval( 6.6579046435011037772, 5.4637849111641143699, @@ -156,23 +156,23 @@ inline static REAL tail(const REAL& r) { * to a gaussian distribution, uniformely distributed in [-inf, +inf]. */ inline -void uGaussian( const REAL& fract, // 2 ^ sobol_bits +void uGaussian( const real_t& fract, // 2 ^ sobol_bits const UINT& dim, // size of the Sobol quasi-random vector const UINT* sob_vct, // [dim] Sobol quasi-random (int) vector - REAL* gauss_vct // result + real_t* gauss_vct // result ) { for ( int i = 0; i < dim; i ++ ) { // sobol int number -> sobol real number in [0,1) - REAL sob_real = static_cast(sob_vct[i]) * fract; + real_t sob_real = static_cast(sob_vct[i]) * fract; // sobol real number [0,1) -> gaussian number in (-inf, +inf) - REAL dp = sob_real - 0.5; + real_t dp = sob_real - 0.5; if ( fabs(dp) <= 0.425 ) { gauss_vct[i]= small_case(dp); } else { - REAL pp = (dp < 0.0) ? (0.5 + dp) : (0.5 - dp); - REAL r = sqrt (- log(pp)); - REAL x = (r <= 5.0) ? intermediate(r) : tail(r); + real_t pp = (dp < 0.0) ? (0.5 + dp) : (0.5 - dp); + real_t r = sqrt (- log(pp)); + real_t x = (r <= 5.0) ? intermediate(r) : tail(r); gauss_vct[i]= (dp < 0.0) ? (0.0 - x) : x; } } @@ -190,17 +190,17 @@ void brownianBridge( const UINT& num_under, const UINT& num_dates, const int* bb_inds, // [3, num_dates] Brownian Bridge's indirect indexing - const REAL* bb_data, // [3, num_dates] Brownian Bridge's data - REAL* md_zd, // [num_dates, num_under] the gaussian vector + const real_t* bb_data, // [3, num_dates] Brownian Bridge's data + real_t* md_zd, // [num_dates, num_under] the gaussian vector // also holds the result! - REAL* res // [num_dates, num_under] temporary array + real_t* res // [num_dates, num_under] temporary array ) { const int * bb_bi = bb_inds; const int * bb_li = bb_inds + num_dates; const int * bb_ri = bb_inds + 2*num_dates; - const REAL* bb_sd = bb_data; - const REAL* bb_lw = bb_data + num_dates; - const REAL* bb_rw = bb_data + 2*num_dates; + const real_t* bb_sd = bb_data; + const real_t* bb_lw = bb_data + num_dates; + const real_t* bb_rw = bb_data + 2*num_dates; for ( int m = 0; m < num_under; m ++ ) { res[ (bb_bi[0]-1) * num_under + m ] = bb_sd[0] * md_zd[m]; diff --git a/OptionPricing/includeC/TimeHelper.h b/benchmarks/OptionPricing/lib/include/TimeHelper.h similarity index 100% rename from OptionPricing/includeC/TimeHelper.h rename to benchmarks/OptionPricing/lib/include/TimeHelper.h diff --git a/config/platform_example.json b/config/platform_example.json new file mode 100644 index 0000000..6fb8fc4 --- /dev/null +++ b/config/platform_example.json @@ -0,0 +1,14 @@ +{ + "gpu" : { + "device_id" : 0, + "warp_size" : 32, + "local_memory" : 48, + "constant_memory" : 64, + "register_memory" : 64, + "device_memory" : 2097152, + "local_memory_per_thread" : 8, + "num_cores" : 192 + }, + "num_cores" : 4, + "main_memory" : 4194304 +} diff --git a/hipermark b/hipermark new file mode 160000 index 0000000..a5ffd5f --- /dev/null +++ b/hipermark @@ -0,0 +1 @@ +Subproject commit a5ffd5fde3ad5ee43556f36ac0749c8c75cb2d00 diff --git a/hiperpret_figure_configuration_graph_OptionPricing_runtimes.json b/hiperpret_figure_configuration_graph_OptionPricing_runtimes.json new file mode 100644 index 0000000..e3c4e95 --- /dev/null +++ b/hiperpret_figure_configuration_graph_OptionPricing_runtimes.json @@ -0,0 +1,50 @@ +[ + { + "type": "graph", + "dependent variable": "mean runtime", + "get normalized performance": "False", + "free_var": "NUM_THREADS", + "legend": "OptionPricing, cpp_openmp, small dataset, double precision", + "locked variables": { + "benchmark_name": "OptionPricing", + "implementation_name": "cpp_openmp", + "dataset_name": "small", + "REAL_TYPE": "double"} + }, + { + "type": "graph", + "dependent variable": "mean runtime", + "get normalized performance": "False", + "free_var": "NUM_THREADS", + "legend": "OptionPricing, cpp_openmp, small dataset, float precision", + "locked variables": { + "benchmark_name": "OptionPricing", + "implementation_name": "cpp_openmp", + "dataset_name": "small", + "REAL_TYPE": "float"} + }, + { + "type": "graph", + "dependent variable": "mean runtime", + "get normalized performance": "False", + "free_var": "NUM_THREADS", + "legend": "OptionPricing, cpp_openmp, medium dataset, double precision", + "locked variables": { + "benchmark_name": "OptionPricing", + "implementation_name": "cpp_openmp", + "dataset_name": "medium", + "REAL_TYPE": "double"} + }, + { + "type": "graph", + "dependent variable": "mean runtime", + "get normalized performance": "False", + "free_var": "NUM_THREADS", + "legend": "OptionPricing, cpp_openmp, medium dataset, float precision", + "locked variables": { + "benchmark_name": "OptionPricing", + "implementation_name": "cpp_openmp", + "dataset_name": "medium", + "REAL_TYPE": "float"} + } +] diff --git a/hiperpret_figure_configuration_graph_OptionPricing_speedup.json b/hiperpret_figure_configuration_graph_OptionPricing_speedup.json new file mode 100644 index 0000000..c22070e --- /dev/null +++ b/hiperpret_figure_configuration_graph_OptionPricing_speedup.json @@ -0,0 +1,51 @@ +[ + { + "type": "graph", + "dependent variable": "mean runtime", + "get normalized performance": "True", + "free_var": "NUM_THREADS", + "legend": "OptionPricing, cpp_openmp, small dataset, double precision", + "locked variables": { + "benchmark_name": "OptionPricing", + "implementation_name": "cpp_openmp", + "dataset_name": "small", + "REAL_TYPE": "double"} + }, + { + "type": "graph", + "dependent variable": "mean runtime", + "get normalized performance": "True", + "free_var": "NUM_THREADS", + "legend": "OptionPricing, cpp_openmp, small dataset, float precision", + "locked variables": { + "benchmark_name": "OptionPricing", + "implementation_name": "cpp_openmp", + "dataset_name": "small", + "REAL_TYPE": "float"} + }, + { + "type": "graph", + "dependent variable": "mean runtime", + "get normalized performance": "True", + "free_var": "NUM_THREADS", + "legend": "OptionPricing, cpp_openmp, medium dataset, double precision", + "locked variables": { + "benchmark_name": "OptionPricing", + "implementation_name": "cpp_openmp", + "dataset_name": "medium", + "REAL_TYPE": "double"} + }, + { + "type": "graph", + "dependent variable": "mean runtime", + "get normalized performance": "True", + "free_var": "NUM_THREADS", + "legend": "OptionPricing, cpp_openmp, medium dataset, float precision", + "locked variables": { + "benchmark_name": "OptionPricing", + "implementation_name": "cpp_openmp", + "dataset_name": "medium", + "REAL_TYPE": "float"} + } + +] diff --git a/hiperpret_figure_configuration_runtimes_InterestCalib.json b/hiperpret_figure_configuration_runtimes_InterestCalib.json new file mode 100644 index 0000000..11dfca9 --- /dev/null +++ b/hiperpret_figure_configuration_runtimes_InterestCalib.json @@ -0,0 +1,10 @@ +[ + { + "type": "runtimes", + "dependent variable": "mean runtime", + "locked variables": { + "benchmark_name": "InterestCalib", + "dataset_name": "small" + } + } +] diff --git a/hiperpret_figure_configuration_runtimes_OptionPricing_both.json b/hiperpret_figure_configuration_runtimes_OptionPricing_both.json new file mode 100644 index 0000000..c152338 --- /dev/null +++ b/hiperpret_figure_configuration_runtimes_OptionPricing_both.json @@ -0,0 +1,9 @@ +[ + { + "type": "runtimes", + "dependent variable": "mean runtime", + "locked variables": { + "benchmark_name": "OptionPricing" + } + } +] diff --git a/hiperpret_figure_configuration_runtimes_OptionPricing_large.json b/hiperpret_figure_configuration_runtimes_OptionPricing_large.json new file mode 100644 index 0000000..e5bc955 --- /dev/null +++ b/hiperpret_figure_configuration_runtimes_OptionPricing_large.json @@ -0,0 +1,10 @@ +[ + { + "type": "runtimes", + "dependent variable": "mean runtime", + "locked variables": { + "benchmark_name": "OptionPricing", + "dataset_name": "large" + } + } +] diff --git a/hiperpret_figure_configuration_runtimes_OptionPricing_medium.json b/hiperpret_figure_configuration_runtimes_OptionPricing_medium.json new file mode 100644 index 0000000..1492ae5 --- /dev/null +++ b/hiperpret_figure_configuration_runtimes_OptionPricing_medium.json @@ -0,0 +1,10 @@ +[ + { + "type": "runtimes", + "dependent variable": "mean runtime", + "locked variables": { + "benchmark_name": "OptionPricing", + "dataset_name": "medium" + } + } +] diff --git a/hiperpret_figure_configuration_runtimes_OptionPricing_small.json b/hiperpret_figure_configuration_runtimes_OptionPricing_small.json new file mode 100644 index 0000000..0d94aa9 --- /dev/null +++ b/hiperpret_figure_configuration_runtimes_OptionPricing_small.json @@ -0,0 +1,10 @@ +[ + { + "type": "runtimes", + "dependent variable": "mean runtime", + "locked variables": { + "benchmark_name": "OptionPricing", + "dataset_name": "small" + } + } +] diff --git a/lib/flat_data_helper.mk b/lib/flat_data_helper.mk new file mode 100644 index 0000000..e2d461e --- /dev/null +++ b/lib/flat_data_helper.mk @@ -0,0 +1,16 @@ +# Utility makefile definitions for conveniently defining run targets +# (with some assumptions). + +AD_HOC_RUNTIME_FILE=runtime.txt +AD_HOC_RESULT_FILE=result.json + +AD_HOC_RUN_FLAGS=HIPERMARK_RUNTIME=$(AD_HOC_RUNTIME_FILE) HIPERMARK_RESULT=$(AD_HOC_RESULT_FILE) + +run_%: $(EXECUTABLE) + $(HIPERMARK_LIB_DIR)/linearise_data.py ../../datasets/$(subst run_,,$@)/input.json $(HIPERMARK_DATA_FIELDS) | $(AD_HOC_RUN_FLAGS) ./$(EXECUTABLE) + @echo "Result: `cat result.json`" + @echo "Runtime: `cat runtime.txt`ms" + +run: $(EXECUTABLE) + $(HIPERMARK_LIB_DIR)/linearise_data.py $(HIPERMARK_INPUT_FILE) $(HIPERMARK_DATA_FIELDS) | \ + $(HIPERMARK_RUN_ENVIRONMENT) ./$(EXECUTABLE) diff --git a/lib/generate_platform_mk.py b/lib/generate_platform_mk.py new file mode 100755 index 0000000..9ec1ada --- /dev/null +++ b/lib/generate_platform_mk.py @@ -0,0 +1,36 @@ +#!/usr/bin/env python + +import json +import sys +import math + +def read_json_file(filename): + with open(filename, "r") as file: + return json.loads(file.read()) + +def generate_platform_mk(data): + if "gpu" in data: + gpu=data["gpu"] + print("HAVE_GPU = 1") + print("GPU_DEVICE_ID = %d" % gpu["device_id"]) + print("GPU_WARP = %d" % gpu["warp_size"]) + print("GPU_LG_WARP = %d" % math.log(gpu["warp_size"],2)) + print("GPU_LOCAL_MEM = %d" % gpu["local_memory"]) + print("GPU_CONST_MEM = %d" % gpu["constant_memory"]) + print("GPU_REGISTER_MEM = %d" % gpu["register_memory"]) + print("GPU_DEVICE_MEM = %d" % (gpu["device_memory"]/(1024*1024))) + print("GPU_LOCAL_MEM_PER_TH = %d" % gpu["local_memory_per_thread"]) + print("GPU_NUM_CORES = %d" % gpu["num_cores"]) + else: + print("HAVE_GPU = 0") + print("NCORES = %d" % data["num_cores"]) + print("MEMORY = %d" % data["main_memory"]) + print("export") + +if __name__ == '__main__': + if len(sys.argv) != 2: + exit("Usage: %s " % sys.argv[0]) + else: + data = read_json_file(sys.argv[1]) + generate_platform_mk(data) + diff --git a/include/ParserC.h b/lib/include/ParserC.h similarity index 82% rename from include/ParserC.h rename to lib/include/ParserC.h index ed3b2c4..a870d14 100644 --- a/include/ParserC.h +++ b/lib/include/ParserC.h @@ -7,7 +7,6 @@ #include #include - struct array_reader { char* elems; int64_t n_elems_space; @@ -216,41 +215,36 @@ int read_double(void* dest) { /////////////////////// /// Writing Dataset /// /////////////////////// -void write_scal( const int * i, const char* msg ) { - fprintf(stdout, "%d ", *i); - if( msg ) fprintf(stdout, "\t// %s\n", msg); +void write_scal( FILE* out, const int * i ) { + fprintf(out, "%d ", *i); } -void write_scal( const double* r, const char* msg ) { - fprintf(stdout, "%lf ", *r); - if( msg ) fprintf(stdout, "\t// %s\n", msg); +void write_scal( FILE* out, const double* r ) { + fprintf(out, "%lf ", *r); } -void write_scal( const float * r, const char* msg ) { - fprintf(stdout, "%f ", *r); - if( msg ) fprintf(stdout, "\t// %s\n", msg); +void write_scal( FILE* out, const float * r ) { + fprintf(out, "%f ", *r); } template -void write_1Darr( const T* ptr, const int& N, const char* msg ) { - fprintf(stdout, "\n [ "); +void write_1Darr( FILE* out, const T* ptr, const int& N ) { + fprintf(out, "\n [ "); for( int i = 0; i < N-1; i ++ ) { - write_scal(&ptr[i], NULL); - fprintf(stdout, ", "); + write_scal(out, &ptr[i]); + fprintf(out, ", "); } - write_scal(&ptr[N-1], NULL); - if (msg) fprintf(stdout, " ]\t//%s\n\n", msg); - else fprintf(stdout, " ]"); + write_scal(out, &ptr[N-1]); + fprintf(out, " ]"); } template -void write_2Darr( const T* ptr, const int& Nouter, const int& Ninner, const char* msg ) { - fprintf(stdout, "\n[ "); +void write_2Darr( FILE* out, const T* ptr, const int& Nouter, const int& Ninner ) { + fprintf(out, "\n[ "); for( int i = 0; i < Nouter-1; i ++ ) { - write_1Darr( ptr + i*Ninner, Ninner, NULL ); - fprintf(stdout, ","); + write_1Darr( out, ptr + i*Ninner, Ninner ); + fprintf(out, ","); } - write_1Darr( ptr + (Nouter-1)*Ninner, Ninner, NULL ); - if (msg) fprintf(stdout, "\n]\t//%s\n\n", msg); - else fprintf(stdout, "\n]\n"); + write_1Darr( out, ptr + (Nouter-1)*Ninner, Ninner ); + fprintf(out, "\n]\n"); } #endif // DATASET_PARSER diff --git a/include/SDK_stub.h b/lib/include/SDK_stub.h similarity index 92% rename from include/SDK_stub.h rename to lib/include/SDK_stub.h index 4abce96..a058e40 100644 --- a/include/SDK_stub.h +++ b/lib/include/SDK_stub.h @@ -1,6 +1,7 @@ #ifndef SDK_INTERNALS #define SDK_INTERNALS +#include #include #include @@ -129,7 +130,83 @@ const char* oclErrorString(unsigned int err) #define oclCheckErrorEX(a, b, c) __oclCheckErrorEX(a, b, c, __FILE__ , __LINE__) #define oclCheckError(a, b) oclCheckErrorEX(a, b, 0) - void __oclCheckErrorEX(cl_int iSample, cl_int iReference, void (*pCleanup)(int), const char* cFile, const int iLine) +// Helper function to get OpenCL error string from constant +// ********************************************************************* +const char* oclErrorString(cl_int error) +{ + static const char* errorString[] = { + "CL_SUCCESS", + "CL_DEVICE_NOT_FOUND", + "CL_DEVICE_NOT_AVAILABLE", + "CL_COMPILER_NOT_AVAILABLE", + "CL_MEM_OBJECT_ALLOCATION_FAILURE", + "CL_OUT_OF_RESOURCES", + "CL_OUT_OF_HOST_MEMORY", + "CL_PROFILING_INFO_NOT_AVAILABLE", + "CL_MEM_COPY_OVERLAP", + "CL_IMAGE_FORMAT_MISMATCH", + "CL_IMAGE_FORMAT_NOT_SUPPORTED", + "CL_BUILD_PROGRAM_FAILURE", + "CL_MAP_FAILURE", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "CL_INVALID_VALUE", + "CL_INVALID_DEVICE_TYPE", + "CL_INVALID_PLATFORM", + "CL_INVALID_DEVICE", + "CL_INVALID_CONTEXT", + "CL_INVALID_QUEUE_PROPERTIES", + "CL_INVALID_COMMAND_QUEUE", + "CL_INVALID_HOST_PTR", + "CL_INVALID_MEM_OBJECT", + "CL_INVALID_IMAGE_FORMAT_DESCRIPTOR", + "CL_INVALID_IMAGE_SIZE", + "CL_INVALID_SAMPLER", + "CL_INVALID_BINARY", + "CL_INVALID_BUILD_OPTIONS", + "CL_INVALID_PROGRAM", + "CL_INVALID_PROGRAM_EXECUTABLE", + "CL_INVALID_KERNEL_NAME", + "CL_INVALID_KERNEL_DEFINITION", + "CL_INVALID_KERNEL", + "CL_INVALID_ARG_INDEX", + "CL_INVALID_ARG_VALUE", + "CL_INVALID_ARG_SIZE", + "CL_INVALID_KERNEL_ARGS", + "CL_INVALID_WORK_DIMENSION", + "CL_INVALID_WORK_GROUP_SIZE", + "CL_INVALID_WORK_ITEM_SIZE", + "CL_INVALID_GLOBAL_OFFSET", + "CL_INVALID_EVENT_WAIT_LIST", + "CL_INVALID_EVENT", + "CL_INVALID_OPERATION", + "CL_INVALID_GL_OBJECT", + "CL_INVALID_BUFFER_SIZE", + "CL_INVALID_MIP_LEVEL", + "CL_INVALID_GLOBAL_WORK_SIZE", + }; + const int errorCount = sizeof(errorString) / sizeof(errorString[0]); + const int index = -error; + return (index >= 0 && index < errorCount) ? errorString[index] : "Unspecified Error"; +} + + + inline void __oclCheckErrorEX(cl_int iSample, cl_int iReference, void (*pCleanup)(int), const char* cFile, const int iLine) { // An error condition is defined by the sample/test value not equal to the reference if (iReference != iSample) @@ -720,28 +797,40 @@ void build_for_GPU( //shrLog(stdlog, "Before building error: %d, code: %d, success: %d, num_dev: %d\n\n", // ciErr1, CL_BUILD_PROGRAM_FAILURE, CL_SUCCESS, nDevice); -#ifdef CURR_DIR_PATH - { // create new string that concatenates the current compileOptions and "-I VAR" - char newCompileOptions [2048]; - sprintf(newCompileOptions, "%s%s%s", compileOptions, " -I ", CURR_DIR_PATH); - ciErr1 = clBuildProgram(cpProgram, 1, cdDevices+dev_id, newCompileOptions, NULL, NULL); - shrLog(stdlog, "CURR_DIR_PATH SET. Compile options: %s\n", newCompileOptions); - } -#else ciErr1 = clBuildProgram(cpProgram, 1, cdDevices+dev_id, compileOptions, NULL, NULL); -#endif //CURR_DIR_PATH shrLog(stdlog, "Program built 1...\n"); // 7. check errors! + int failed = 0; + cl_build_status status; + if (ciErr1 != CL_SUCCESS) { + failed = 1; + } else { + /* clBuildProgram may return CL_SUCCESS just because the + build was started - it may yet not finish succesfully. */ + do { + sleep(1); + clGetProgramBuildInfo(cpProgram, cdDevices[dev_id], + CL_PROGRAM_BUILD_STATUS, sizeof(status), + &status, NULL); + fprintf(stderr, "status: %d (%d?)\n", status, CL_BUILD_SUCCESS); + } while (status == CL_BUILD_IN_PROGRESS); + + if (status != CL_BUILD_SUCCESS) { + failed = 1; + } + } + + if (true || failed) { // write out standard error, Build Log and PTX, then cleanup and exit shrLog(stdlog, "BUILDING ERROR: %d: %s\n", ciErr1, oclErrorString(ciErr1)); //oclLogBuildInfo(cpProgram, cdDevices[dev_id]); //oclLogPtx(cpProgram, cdDevices[dev_id], ptx_name.c_str()); - if (ciErr1 == CL_BUILD_PROGRAM_FAILURE) { + if (true || ciErr1 == CL_BUILD_PROGRAM_FAILURE) { // Determine the size of the log size_t log_size; clGetProgramBuildInfo(cpProgram, cdDevices[dev_id], CL_PROGRAM_BUILD_LOG, 0, NULL, &log_size); diff --git a/include/Util.h b/lib/include/Util.h similarity index 98% rename from include/Util.h rename to lib/include/Util.h index 495ca75..9f15844 100644 --- a/include/Util.h +++ b/lib/include/Util.h @@ -15,7 +15,7 @@ #include #endif - +#define STRINGIFY(x) #x #define TIME_RESOLUTION_MICROSECOND #ifdef TIME_RESOLUTION_MICROSECOND diff --git a/include/Utilities.cl b/lib/include/Utilities.cl similarity index 96% rename from include/Utilities.cl rename to lib/include/Utilities.cl index 28fbd06..dff4d53 100644 --- a/include/Utilities.cl +++ b/lib/include/Utilities.cl @@ -125,7 +125,7 @@ TYPE segm_scan_reg_warp( **/ inline void segm_scan_reg_block ( - __local volatile REAL* sh_data, + __local volatile real_t* sh_data, uint sh_size, uint sgm_size ) { @@ -235,8 +235,8 @@ void segm_red_reg_block_K ( * ASSERTS: * 1. ptr & hd are adjusted for each warp */ -inline REAL segm_scan_warp( - __local volatile REAL* ptr, +inline real_t segm_scan_warp( + __local volatile real_t* ptr, __local volatile FLAG* hd ) { const uint th_id = TH_ID & (WARP-1); @@ -265,8 +265,8 @@ inline REAL segm_scan_warp( return ptr[th_id]; } -inline REAL segm_scan_block( - __local volatile REAL *ptr, +inline real_t segm_scan_block( + __local volatile real_t *ptr, __local volatile FLAG *hd ) { // 1a: record whether this warp begins @@ -276,10 +276,10 @@ inline REAL segm_scan_block( barrier(CLK_LOCAL_MEM_FENCE); // 1b: intra-warp segmented scan for each warp - REAL val = segm_scan_warp( ptr + WARP_FST, hd + WARP_FST ); + real_t val = segm_scan_warp( ptr + WARP_FST, hd + WARP_FST ); // 2a: the last value is the correct partial result - REAL warp_total = ptr[WARP_LST]; + real_t warp_total = ptr[WARP_LST]; // 2b: warp_flag is the OR-reduction of the flags // in a warp, and is computed indirectly from @@ -330,7 +330,7 @@ inline REAL segm_scan_block( * 2. size of ptr and hd is [K * local_group_size(0)] */ inline void segm_scan_block_K( - __local volatile REAL *ptr, + __local volatile real_t *ptr, __local volatile FLAG *hd , uint K , bool warp_level @@ -339,7 +339,7 @@ inline void segm_scan_block_K( segm_scan_block(ptr, hd); } else { uint th_idmK = TH_ID * K; - REAL reg_ptr[SEQ_ELMS]; + real_t reg_ptr[SEQ_ELMS]; bool reg_hd [SEQ_ELMS]; { // 1) each threads copies its elems in regs @@ -351,7 +351,7 @@ inline void segm_scan_block_K( { // 2) now write to shared memory local_group_size(0) elements FLAG flag; - REAL data; + real_t data; data = reg_ptr[K-1]; if ( reg_hd[K-1] == 0 ) { // the sum of the last segm @@ -375,7 +375,7 @@ inline void segm_scan_block_K( } { // 3) perform the segmented scan for get_local_size(0) elements - REAL accum; + real_t accum; if(warp_level) { segm_scan_warp ( ptr + WARP_FST, hd + WARP_FST ); @@ -410,15 +410,15 @@ inline void segm_scan_block_K( inline void ComparatorPrivate( uint *keyA, - REAL *valA, + real_t *valA, uint *keyB, - REAL *valB, + real_t *valB, uint arrowDir ){ if( (*keyA > *keyB) == arrowDir ){ uint t; t = *keyA; *keyA = *keyB; *keyB = t; - REAL r; + real_t r; r = *valA; *valA = *valB; *valB = r; } } @@ -426,15 +426,15 @@ inline void ComparatorPrivate( // volatile inline void ComparatorLocal( __local uint *keyA, - __local REAL *valA, + __local real_t *valA, __local uint *keyB, - __local REAL *valB, + __local real_t *valB, uint arrowDir ){ if( (*keyA > *keyB) == arrowDir ){ uint t; t = *keyA; *keyA = *keyB; *keyB = t; - REAL r; + real_t r; r = *valA; *valA = *valB; *valB = r; } } @@ -445,7 +445,7 @@ inline void ComparatorLocal( */ void bitonicSortLocal( __local volatile uint *l_key, - __local volatile REAL *l_val, + __local volatile real_t *l_val, uint arrayLength, uint sort_len //uint sortDir diff --git a/lib/include/real.h b/lib/include/real.h new file mode 100644 index 0000000..197b505 --- /dev/null +++ b/lib/include/real.h @@ -0,0 +1,38 @@ +#ifndef FINPAR_REAL_H +#define FINPAR_REAL_H + +#ifdef REAL_IS_DOUBLE + +/* Some OpenCL implementations require us to define a pragma if we + want to use double-precision numbers. */ +#ifdef __OPENCL_VERSION__ +#pragma OPENCL EXTENSION cl_khr_fp64 : enable +#endif + +typedef double real_t; +#define REAL_FLAG "REAL_IS_DOUBLE" + +#ifdef __OPENCL_VERSION__ +#define real4_t double4 +#define real3_t double3 +#define real2_t double2 +#endif + +#elif REAL_IS_FLOAT + +typedef float real_t; +#define REAL_FLAG "REAL_IS_FLOAT" + +#ifdef __OPENCL_VERSION__ +#define real4_t float4 +#define real3_t float3 +#define real2_t float2 +#endif + +#else + +#error "Must set REAL_IS_DOUBLE or REAL_IS_FLOAT." + +#endif + +#endif diff --git a/lib/json_get.py b/lib/json_get.py new file mode 100755 index 0000000..cca3191 --- /dev/null +++ b/lib/json_get.py @@ -0,0 +1,16 @@ +#!/usr/bin/env python + +import json +import sys +import math + +def read_json_file(filename): + with open(filename, "r") as file: + return json.loads(file.read()) + +if __name__ == '__main__': + if len(sys.argv) != 3: + exit("Usage: %s " % sys.argv[0]) + else: + data = read_json_file(sys.argv[1]) + print(data[sys.argv[2]]) diff --git a/lib/linearise_data.py b/lib/linearise_data.py new file mode 100755 index 0000000..18bc33d --- /dev/null +++ b/lib/linearise_data.py @@ -0,0 +1,19 @@ +#!/usr/bin/env python + +import json +import sys + +def read_json_file(filename): + with open(filename, "r") as file: + return json.loads(file.read()) + +if __name__ == '__main__': + if len(sys.argv) < 3: + exit("Usage: %s [fields...]" % sys.argv[0]) + else: + data = read_json_file(sys.argv[1]) + for field in sys.argv[2:]: + try: + print(data[field]) + except KeyError: + exit("Key %s not found in JSON file." % field) diff --git a/platform.macbookpro.intel.mk b/lib/platform.macbookpro.intel.mk similarity index 100% rename from platform.macbookpro.intel.mk rename to lib/platform.macbookpro.intel.mk diff --git a/platform.macbookpro.mk b/lib/platform.macbookpro.mk similarity index 100% rename from platform.macbookpro.mk rename to lib/platform.macbookpro.mk diff --git a/platform.mk b/lib/platform.mk similarity index 100% rename from platform.mk rename to lib/platform.mk diff --git a/lib/setup.mk b/lib/setup.mk new file mode 100644 index 0000000..18b3012 --- /dev/null +++ b/lib/setup.mk @@ -0,0 +1,30 @@ +# If we are run from outside Hipermark itself, a number of environment +# variables will be missing. Set these to hopefully-working values to +# support standalone compilation. Users should not need to modify this. +HIPERMARK_BENCHMARK_LIB_DIR ?= ../../lib/ +HIPERMARK_IMPLEMENTATION_DIR ?= . + +OS=$(shell uname -s) + +ifeq ($(OS),Darwin) + # OpenMP is not supported by clang and gcc-4.9 does not work + # well with OpenCL on Mac, thus, we don't define ENABLE_OPENMP + CXX = clang++ + CXXFLAGS = -Wall -W -O3 + LIB = -framework OpenCL + INCLUDES = -I. -I../../include +else + ENABLE_OPENMP = 1 + OPENCL_ROOTDIR ?= /usr/local/cuda + OPENCL_LIBDIR ?= $(OPENCL_ROOTDIR)/lib64 + OPENCL_INCDIR ?= $(OPENCL_ROOTDIR)/include + CXX = g++ + LIB = -L$(OPENCL_LIBDIR) -lOpenCL + CXXFLAGS = -DENABLE_OPENMP -fopenmp -O3 + INCLUDES = -I$(OPENCL_INCDIR) -I. -I../../include +endif + +# Users should not modify this. +CXXFLAGS += -DHIPERMARK_IMPLEMENTATION_DIR='"$(HIPERMARK_IMPLEMENTATION_DIR)"' +CXXFLAGS += -DHIPERMARK_BENCHMARK_LIB_DIR='"$(HIPERMARK_BENCHMARK_LIB_DIR)"' +CXXFLAGS += -DHIPERMARK_LIB_DIR='"$(HIPERMARK_LIB_DIR)"' diff --git a/lib/setup_real_type.mk b/lib/setup_real_type.mk new file mode 100644 index 0000000..fef7d3c --- /dev/null +++ b/lib/setup_real_type.mk @@ -0,0 +1,16 @@ +# This makefile provides utility definitions for having either +# REAL_IS_FLOAT or REAL_IS_DOUBLE defined during compilation. This is +# based on the environment variable HIPERMARK_CONFIG_REAL_TYPE, which +# must be defined as a static configuration option. If +# HIPERMARK_CONFIG_REAL_TYPE is not set at all, it will be assumed to +# be 'double' +# +# This makefile fragment appends to CXXFLAGS. + +ifeq ($(HIPERMARK_CONFIG_REAL_TYPE),float) + CXXFLAGS += -DREAL_IS_FLOAT +else ifeq ($(HIPERMARK_CONFIG_REAL_TYPE),double) + CXXFLAGS += -DREAL_IS_DOUBLE +else + CXXFLAGS += -DREAL_IS_DOUBLE +endif diff --git a/run_hipermark_InterestCalib b/run_hipermark_InterestCalib new file mode 100755 index 0000000..37aea67 --- /dev/null +++ b/run_hipermark_InterestCalib @@ -0,0 +1,9 @@ +#!/bin/bash + +clear +echo Deleting all files in instantiations/InterestCalib +echo Running hipermark InterestCalib cpp_openmp small dataset, 2 times. +echo Storing all results in instantiations/ + +rm -rf instantiations/InterestCalib +../hipermark/hipermark -o instantiations/ -n 2 -b benchmarks/InterestCalib -m cpp_openmp -d small diff --git a/run_hipermark_LocVolCalib b/run_hipermark_LocVolCalib new file mode 100755 index 0000000..e23fef6 --- /dev/null +++ b/run_hipermark_LocVolCalib @@ -0,0 +1,9 @@ +#!/bin/bash + +clear +echo Deleting all files in instantiations/LocVolCalib +echo Running hipermark LocVolCalib cpp_openmp_naive + cpp_sequential medium dataset, two times. +echo Storing all results in instantiations/ + +rm -rf instantiations/LocVolCalib +../hipermark/hipermark -o instantiations/ -n 2 -b benchmarks/LocVolCalib -m cpp_openmp_naive -m cpp_sequential -d medium diff --git a/run_hipermark_OptionPricing_cpp_opencl b/run_hipermark_OptionPricing_cpp_opencl new file mode 100755 index 0000000..4dd7d65 --- /dev/null +++ b/run_hipermark_OptionPricing_cpp_opencl @@ -0,0 +1,9 @@ +#!/bin/bash + +clear +echo Deleting all files in instantiations/OptionPricing/ +echo Running hipermark OptionPricing cpp_sequential and cpp_opencl small dataset, 4 times. +echo Storing all results in instantiations/ + +rm -rf instantiations/OptionPricing/ +../hipermark/hipermark -o instantiations/ -n 30 -b benchmarks/OptionPricing -m cpp_opencl -m cpp_sequential -m cpp_openmp -d small -d medium -d large diff --git a/run_hipermark_OptionPricing_cpp_openmp_cpp_sequential b/run_hipermark_OptionPricing_cpp_openmp_cpp_sequential new file mode 100755 index 0000000..0684ef1 --- /dev/null +++ b/run_hipermark_OptionPricing_cpp_openmp_cpp_sequential @@ -0,0 +1,9 @@ +#!/bin/bash + +clear +echo Deleting all files in instantiations/OptionPricing/ +echo Running hipermark OptionPricing cpp_sequential and cpp_openmp small dataset, 10 times. +echo Storing all results in instantiations/ + +rm -rf instantiations/OptionPricing/ +../hipermark/hipermark -o instantiations/ -n 10 -b benchmarks/OptionPricing -m cpp_sequential -m cpp_openmp -d small -d medium diff --git a/run_hiperpret_InterestCalib_cpp_openmp b/run_hiperpret_InterestCalib_cpp_openmp new file mode 100755 index 0000000..6d0b50d --- /dev/null +++ b/run_hiperpret_InterestCalib_cpp_openmp @@ -0,0 +1,10 @@ +#!/bin/bash + +clear +echo Deleting all files in ./hiperpret +echo Running Hiperpret analysis, assuming that hiperMARK output data is present in ./instantiations. +echo Storing analysis results in ./hiperpret +echo Expecting one figure configs JSONs in this folder. + +rm -rf hiperpret/ +../hipermark/hiperpret -i ./instantiations/ -f hiperpret_figure_configuration_runtimes_InterestCalib.json -o ./hiperpret diff --git a/run_hiperpret_OptionPricing b/run_hiperpret_OptionPricing new file mode 100755 index 0000000..944e760 --- /dev/null +++ b/run_hiperpret_OptionPricing @@ -0,0 +1,10 @@ +#!/bin/bash + +clear +echo Deleting all files in ./hiperpret +echo Running Hiperpret analysis, assuming that hiperMARK output data is present in ./instantiations. +echo Storing analysis results in ./hiperpret +echo Expecting one figure configs JSONs in this folder. + +rm -rf hiperpret/ +../hipermark/hiperpret -i ./instantiations/ -f hiperpret_figure_configuration_runtimes_OptionPricing_small.json -f hiperpret_figure_configuration_runtimes_OptionPricing_both.json -f hiperpret_figure_configuration_graph_OptionPricing_speedup.json -f hiperpret_figure_configuration_graph_OptionPricing_runtimes.json -o ./hiperpret diff --git a/run_hiperpret_OptionPricing_cpp_opencl b/run_hiperpret_OptionPricing_cpp_opencl new file mode 100755 index 0000000..c972bea --- /dev/null +++ b/run_hiperpret_OptionPricing_cpp_opencl @@ -0,0 +1,10 @@ +#!/bin/bash + +clear +echo Deleting all files in ./hiperpret +echo Running Hiperpret analysis, assuming that hiperMARK output data is present in ./instantiations. +echo Storing analysis results in ./hiperpret +echo Expecting one figure configs JSONs in this folder. + +rm -rf hiperpret/ +../hipermark/hiperpret -i ./instantiations/ -o ./hiperpret diff --git a/setup.mk b/setup.mk deleted file mode 100644 index 92a7239..0000000 --- a/setup.mk +++ /dev/null @@ -1,20 +0,0 @@ -OS=$(shell uname -s) - -ifeq ($(OS),Darwin) - # OpenMP is not supported by clang and gcc-4.9 does not work - # well with OpenCL on Mac, thus, we don't define ENABLE_OPENMP - CXX = clang++ - CXXFLAGS = -Wall -W -O3 - LIB = -framework OpenCL - INCLUDES = -I. -I../../include -else - ENABLE_OPENMP = 1 - OPENCL_ROOTDIR ?= /usr/local/cuda - OPENCL_LIBDIR := $(OPENCL_ROOTDIR)/lib64 - OPENCL_INCDIR ?= $(OPENCL_ROOTDIR)/include - CXX = g++ - LIB = -L$(OPENCL_LIBDIR) -lOpenCL - CXXFLAGS = -DENABLE_OPENMP -fopenmp -O3 - INCLUDES = -I$(OPENCL_INCDIR) -I. -I../../include -endif -