Current task: —

E-021-sinf-sf-curve.py

Experiments: E-021 · script updated 08-19-2026

E-021-sinf-sf-curve.csv — 299.9 KB, updated 08-19-2026

← prev page 7 of 10 · 500/page · 5000 rows next →
# nS_infS_flambda_nabs_Sf
3002 3001 8621.68217174 2.43136223925 8620.2508095 2.43136223925
3003 3002 8625.05527476 2.77050621247 8623.28476855 2.77050621247
3004 3003 8628.42854434 3.10649609319 8626.32204824 3.10649609319
3005 3004 8631.80198042 3.43838030783 8629.36360011 3.43838030783
3006 3005 8635.17558294 3.7652234383 8632.4103595 3.7652234383
3007 3006 8638.54935185 4.0861100233 8635.46324183 4.0861100233
3008 3007 8641.9232871 4.40014826432 8638.52313884 4.40014826432
3009 3008 8645.29738863 4.70647361941 8641.59091501 4.70647361941
3010 3009 8648.67165637 5.00425226775 8644.66740411 5.00425226775
3011 3010 8652.04609029 5.29268442941 8647.75340586 5.29268442941
3012 3011 8655.42069032 5.57100752478 8650.8496828 5.57100752478
3013 3012 8658.79545641 5.83849915929 8653.95695725 5.83849915929
3014 3013 8662.1703885 6.09447991979 8657.07590858 6.09447991979
3015 3014 8665.54548654 6.33831596981 8660.20717057 6.33831596981
3016 3015 8668.92075047 6.56942143204 8663.35132904 6.56942143204
3017 3016 8672.29618024 6.78726054726 8666.50891969 6.78726054726
3018 3017 8675.67177579 6.99134960011 8669.68042619 6.99134960011
3019 3018 8679.04753706 7.18125860328 8672.86627846 7.18125860328
3020 3019 8682.42346401 7.35661273272 8676.06685128 7.35661273272
3021 3020 8685.79955658 7.51709350778 8679.28246308 7.51709350778
3022 3021 8689.17581471 7.66243971141 8682.513375 7.66243971141
3023 3022 8692.55223835 7.79244804687 8685.75979031 7.79244804687
3024 3023 8695.92882745 7.90697352844 8689.02185392 7.90697352844
3025 3024 8699.30558194 8.00592960527 8692.29965233 8.00592960527
3026 3025 8702.68250177 8.08928801839 8695.59321376 8.08928801839
3027 3026 8706.0595869 8.15707839255 8698.90250851 8.15707839255
3028 3027 8709.43683726 8.20938756557 8702.22744969 8.20938756557
3029 3028 8712.8142528 8.24635865931 8705.56789414 8.24635865931
3030 3029 8716.19183346 8.26818989746 8708.92364356 8.26818989746
3031 3030 8719.5695792 8.27513317673 8712.29444602 8.27513317673
3032 3031 8722.94748995 8.26749239901 8715.67999755 8.26749239901
3033 3032 8726.32556566 8.24562157338 8719.07994409 8.24562157338
3034 3033 8729.70380629 8.20992269783 8722.49388359 8.20992269783
3035 3034 8733.08221176 8.16084343164 8725.92136833 8.16084343164
3036 3035 8736.46078203 8.09887457033 8729.36190746 8.09887457033
3037 3036 8739.83951705 8.02454733602 8732.81496972 8.02454733602
3038 3037 8743.21841676 7.93843049704 8736.27998627 7.93843049704
3039 3038 8746.59748111 7.84112733102 8739.75635378 7.84112733102
3040 3039 8749.97671004 7.7332724471 8743.24343759 7.7332724471
3041 3040 8753.35610349 7.61552848268 8746.74057501 7.61552848268
3042 3041 8756.73566142 7.48858269158 8750.24707873 7.48858269158
3043 3042 8760.11538377 7.35314344019 8753.76224033 7.35314344019
3044 3043 8763.49527048 7.20993662918 8757.28533385 7.20993662918
3045 3044 8766.87532151 7.05970205834 8760.81561945 7.05970205834
3046 3045 8770.25553679 6.90318975227 8764.35234704 6.90318975227
3047 3046 8773.63591628 6.74115626527 8767.89476001 6.74115626527
3048 3047 8777.01645991 6.57436098307 8771.44209893 6.57436098307
3049 3048 8780.39716765 6.40356243982 8774.99360521 6.40356243982
3050 3049 8783.77803942 6.22951466792 8778.54852475 6.22951466792
3051 3050 8787.15907518 6.05296359852 8782.10611158 6.05296359852
3052 3051 8790.54027488 5.87464353004 8785.66563135 5.87464353004
3053 3052 8793.92163846 5.6952736817 8789.22636477 5.6952736817
3054 3053 8797.30316586 5.51555484852 8792.78761101 5.51555484852
3055 3054 8800.68485704 5.33616617378 8796.34869086 5.33616617378
3056 3055 8804.06671194 5.15776205432 8799.90894988 5.15776205432
3057 3056 8807.4487305 4.98096919315 8803.46776131 4.98096919315
3058 3057 8810.83091268 4.80638381346 8807.02452886 4.80638381346
3059 3058 8814.21325841 4.63456904679 8810.57868936 4.63456904679
3060 3059 8817.59576765 4.46605250758 8814.12971514 4.46605250758
3061 3060 8820.97844034 4.30132406526 8817.67711628 4.30132406526
3062 3061 8824.36127644 4.14083382391 8821.22044261 4.14083382391
3063 3062 8827.74427587 3.9849903186 8824.75928555 3.9849903186
3064 3063 8831.1274386 3.83415893638 8828.29327967 3.83415893638
3065 3064 8834.51076457 3.68866056857 8831.822104 3.68866056857
3066 3065 8837.89425372 3.54877050023 8835.34548322 3.54877050023
3067 3066 8841.27790601 3.41471754097 8838.86318847 3.41471754097
3068 3067 8844.66172137 3.28668340046 8842.37503797 3.28668340046
3069 3068 8848.04569976 3.16480231049 8845.88089745 3.16480231049
3070 3069 8851.42984112 3.04916089451 8849.38068023 3.04916089451
3071 3070 8854.81414541 2.93979828379 8852.87434712 2.93979828379
3072 3071 8858.19861255 2.83670647881 8856.36190608 2.83670647881
3073 3072 8861.58324252 2.7398309526 8859.84341156 2.7398309526
3074 3073 8864.96803524 2.64907149207 8863.31896375 2.64907149207
3075 3074 8868.35299067 2.56428327173 8866.7887074 2.56428327173
3076 3075 8871.73810875 2.48527815349 8870.2528306 2.48527815349
3077 3076 8875.12338944 2.41182620473 8873.71156323 2.41182620473
3078 3077 8878.50883267 2.343657426 8877.16517525 2.343657426
3079 3078 8881.8944384 2.2804636785 8880.61397472 2.2804636785
3080 3079 8885.28020658 2.22190080072 8884.05830578 2.22190080072
3081 3080 8888.66613714 2.1675909025 8887.49854624 2.1675909025
3082 3081 8892.05223004 2.11712482394 8890.93510522 2.11712482394
3083 3082 8895.43848523 2.07006474596 8894.36842048 2.07006474596
3084 3083 8898.82490265 2.02594693831 8897.79895571 2.02594693831
3085 3084 8902.21148225 1.98428463043 8901.22719762 1.98428463043
3086 3085 8905.59822397 1.94457098976 8904.65365298 1.94457098976
3087 3086 8908.98512777 1.90628219185 8908.07884558 1.90628219185
3088 3087 8912.37219359 1.86888056583 8911.50331303 1.86888056583
3089 3088 8915.75942139 1.83181779895 8914.92760359 1.83181779895
3090 3089 8919.1468111 1.7945381831 8918.35227291 1.7945381831
3091 3090 8922.53436267 1.7564818866 8921.77788078 1.7564818866
3092 3091 8925.92207605 1.71708823397 8925.20498782 1.71708823397
3093 3092 8929.3099512 1.67579897673 8928.63415222 1.67579897673
3094 3093 8932.69798805 1.63206153834 8932.06592652 1.63206153834
3095 3094 8936.08618656 1.58533221629 8935.50085435 1.58533221629
3096 3095 8939.47454668 1.53507932503 8938.93946735 1.53507932503
3097 3096 8942.86306834 1.48078626343 8942.38228207 1.48078626343
3098 3097 8946.2517515 1.42195449108 8945.82979701 1.42195449108
3099 3098 8949.64059611 1.35810639817 8949.28248971 1.35810639817
3100 3099 8953.02960211 1.28878805431 8952.74081406 1.28878805431
3101 3100 8956.41876946 1.2135718223 8956.20519763 1.2135718223
3102 3101 8959.80809809 1.13205882355 8959.67603927 1.13205882355
3103 3102 8963.19758796 1.04388124274 8963.15370672 1.04388124274
3104 3103 8966.58723902 0.94870446007 8966.63853456 0.94870446007
3105 3104 8969.97705122 0.846229000415 8970.13082222 0.846229000415
3106 3105 8973.3670245 0.736192289651 8973.63083221 0.736192289651
3107 3106 8976.7571588 0.618370209484 8977.13878859 0.618370209484
3108 3107 8980.14745409 0.4925784431 8980.65487565 0.4925784431
3109 3108 8983.5379103 0.358673605114 8984.1792367 0.358673605114
3110 3109 8986.92852739 0.216554150399 8987.71197324 0.216554150399
3111 3110 8990.3193053 0.0661610575351 8991.25314424 0.0661610575351
3112 3111 8993.71024399 -0.0925217161883 8994.8027657 0.0925217161883
3113 3112 8997.10134339 -0.259467010107 8998.3608104 0.259467010107
3114 3113 9000.49260346 -0.43460446654 9001.92720793 0.43460446654
3115 3114 9003.88402415 -0.617820767651 9005.50184492 0.617820767651
3116 3115 9007.2756054 -0.808960101097 9009.0845655 0.808960101097
3117 3116 9010.66734717 -1.00782485155 9012.67517202 1.00782485155
3118 3117 9014.0592494 -1.21417651405 9016.27342591 1.21417651405
3119 3118 9017.45131204 -1.42773682388 9019.87904886 1.42773682388
3120 3119 9020.84353504 -1.64818909673 9023.49172414 1.64818909673
3121 3120 9024.23591835 -1.87517977163 9027.11109812 1.87517977163
3122 3121 9027.62846191 -2.10832014814 9030.73678206 2.10832014814
3123 3122 9031.02116568 -2.34718830841 9034.36835399 2.34718830841
3124 3123 9034.4140296 -2.59133121362 9038.00536081 2.59133121362
3125 3124 9037.80705363 -2.8402669633 9041.64732059 2.8402669633
3126 3125 9041.2002377 -3.09348720569 9045.29372491 3.09348720569
3127 3126 9044.59358178 -3.35045968577 9048.94404146 3.35045968577
3128 3127 9047.9870858 -3.6106309176 9052.59771672 3.6106309176
3129 3128 9051.38074973 -3.87342896646 9056.25417869 3.87342896646
3130 3129 9054.77457349 -4.13826632606 9059.91283982 4.13826632606
3131 3130 9058.16855706 -4.40454287528 9063.57309993 4.40454287528
3132 3131 9061.56270037 -4.67164889883 9067.23434927 4.67164889883
3133 3132 9064.95700337 -4.93896815565 9070.89597153 4.93896815565
3134 3133 9068.35146602 -5.20588097863 9074.55734699 5.20588097863
3135 3134 9071.74608825 -5.47176738936 9078.21785564 5.47176738936
3136 3135 9075.14087003 -5.73601021106 9081.87688024 5.73601021106
3137 3136 9078.53581129 -5.99799816331 9085.53380946 5.99799816331
3138 3137 9081.930912 -6.25712892214 9089.18804092 6.25712892214
3139 3138 9085.32617209 -6.51281212894 9092.83898422 6.51281212894
3140 3139 9088.72159152 -6.76447233252 9096.48606386 6.76447233252
3141 3140 9092.11717024 -7.0115518484 9100.12872209 7.0115518484
3142 3141 9095.51290819 -7.25351352016 9103.76642171 7.25351352016
3143 3142 9098.90880533 -7.48984336819 9107.3986487 7.48984336819
3144 3143 9102.3048616 -7.72005311166 9111.02491471 7.72005311166
3145 3144 9105.70107696 -7.94368255016 9114.64475951 7.94368255016
3146 3145 9109.09745134 -8.16030179241 9118.25775314 8.16030179241
3147 3146 9112.49398472 -8.36951331996 9121.86349804 8.36951331996
3148 3147 9115.89067702 -8.57095387489 9125.46163089 8.57095387489
3149 3148 9119.2875282 -8.76429616124 9129.05182436 8.76429616124
3150 3149 9122.68453822 -8.94925035103 9132.63378857 8.94925035103
3151 3150 9126.08170701 -9.12556538668 9136.2072724 9.12556538668
3152 3151 9129.47903454 -9.29303007272 9139.77206461 9.29303007272
3153 3152 9132.87652075 -9.45147395069 9143.3279947 9.45147395069
3154 3153 9136.27416558 -9.60076795239 9146.87493353 9.60076795239
3155 3154 9139.671969 -9.74082482784 9150.41279382 9.74082482784
3156 3155 9143.06993094 -9.87159934516 9153.94153028 9.87159934516
3157 3156 9146.46805136 -9.99308826127 9157.46113962 9.99308826127
3158 3157 9149.86633021 -10.105330063 9160.97166027 10.105330063
3159 3158 9153.26476744 -10.2084044801 9164.47317192 10.2084044801
3160 3159 9156.663363 -10.3024317712 9167.96579477 10.3024317712
3161 3160 9160.06211683 -10.3875717886 9171.44968862 10.3875717886
3162 3161 9163.46102889 -10.4640228228 9174.92505171 10.4640228228
3163 3162 9166.86009913 -10.5320202368 9178.39211937 10.5320202368
3164 3163 9170.2593275 -10.5918348932 9181.85116239 10.5918348932
3165 3164 9173.65871395 -10.6437713848 9185.30248533 10.6437713848
3166 3165 9177.05825842 -10.6881660761 9188.7464245 10.6881660761
3167 3166 9180.45796087 -10.7253849663 9192.18334584 10.7253849663
3168 3167 9183.85782125 -10.7558213855 9195.61364264 10.7558213855
3169 3168 9187.25783951 -10.7798935341 9199.03773304 10.7798935341
3170 3169 9190.65801559 -10.7980418805 9202.45605747 10.7980418805
3171 3170 9194.05834946 -10.8107264282 9205.86907589 10.8107264282
3172 3171 9197.45884105 -10.8184238686 9209.27726492 10.8184238686
3173 3172 9200.85949032 -10.821624633 9212.68111495 10.821624633
3174 3173 9204.26029722 -10.8208298596 9216.08112708 10.8208298596
3175 3174 9207.6612617 -10.816548292 9219.47781 10.816548292
3176 3175 9211.06238371 -10.8092931238 9222.87167684 10.8092931238
3177 3176 9214.46366321 -10.7995788083 9226.26324201 10.7995788083
3178 3177 9217.86510013 -10.787917848 9229.65301797 10.787917848
3179 3178 9221.26669443 -10.7748175824 9233.04151201 10.7748175824
3180 3179 9224.66844606 -10.7607769904 9236.42922305 10.7607769904
3181 3180 9228.07035498 -10.746283524 9239.8166385 10.746283524
3182 3181 9231.47242113 -10.7318099921 9243.20423112 10.7318099921
3183 3182 9234.87464446 -10.7178115083 9246.59245597 10.7178115083
3184 3183 9238.27702493 -10.7047225218 9249.98174745 10.7047225218
3185 3184 9241.67956248 -10.6929539459 9253.37251643 10.6929539459
3186 3185 9245.08225707 -10.6828904005 9256.76514747 10.6828904005
3187 3186 9248.48510864 -10.6748875831 9260.15999622 10.6748875831
3188 3187 9251.88811715 -10.6692697837 9263.55738693 10.6692697837
3189 3188 9255.29128254 -10.6663275564 9266.9576101 10.6663275564
3190 3189 9258.69460478 -10.6663155617 9270.36092034 10.6663155617
3191 3190 9262.0980838 -10.6694505909 9273.76753439 10.6694505909
3192 3191 9265.50171956 -10.6759097848 9277.17762935 10.6759097848
3193 3192 9268.90551202 -10.6858290566 9280.59134107 10.6858290566
3194 3193 9272.30946111 -10.6993017281 9284.00876284 10.6993017281
3195 3194 9275.7135668 -10.716377389 9287.42994419 10.716377389
3196 3195 9279.11782903 -10.7370609838 9290.85489002 10.7370609838
3197 3196 9282.52224776 -10.7613121364 9294.28355989 10.7613121364
3198 3197 9285.92682293 -10.7890447129 9297.71586764 10.7890447129
3199 3198 9289.3315545 -10.8201266301 9301.15168113 10.8201266301
3200 3199 9292.73644241 -10.85437991 9304.59082232 10.85437991
3201 3200 9296.14148663 -10.8915809824 9308.03306761 10.8915809824
3202 3201 9299.54668709 -10.9314612357 9311.47814833 10.9314612357
3203 3202 9302.95204376 -10.9737078137 9314.92575157 10.9737078137
3204 3203 9306.35755658 -11.0179646581 9318.37552123 11.0179646581
3205 3204 9309.7632255 -11.0638337903 9321.82705929 11.0638337903
3206 3205 9313.16905047 -11.11087683 9325.2799273 11.11087683
3207 3206 9316.57503146 -11.1586167423 9328.7336482 11.1586167423
3208 3207 9319.9811684 -11.2065398079 9332.18770821 11.2065398079
3209 3208 9323.38746125 -11.254097807 9335.64155905 11.254097807
3210 3209 9326.79390996 -11.300710407 9339.09462036 11.300710407
3211 3210 9330.20051448 -11.3457677441 9342.54628222 11.3457677441
3212 3211 9333.60727476 -11.3886331872 9345.99590795 11.3886331872
3213 3212 9337.01419076 -11.428646271 9349.44283703 11.428646271
3214 3213 9340.42126243 -11.4651257844 9352.88638821 11.4651257844
3215 3214 9343.82848971 -11.4973730018 9356.32586271 11.4973730018
3216 3215 9347.23587257 -11.5246750399 9359.76054761 11.5246750399
3217 3216 9350.64341094 -11.5463083258 9363.18971927 11.5463083258
3218 3217 9354.05110479 -11.5615421591 9366.61264695 11.5615421591
3219 3218 9357.45895406 -11.5696423519 9370.02859641 11.5696423519
3220 3219 9360.8669587 -11.5698749289 9373.43683363 11.5698749289
3221 3220 9364.27511868 -11.5615098694 9376.83662855 11.5615098694
3222 3221 9367.68343393 -11.5438248739 9380.22725881 11.5438248739
3223 3222 9371.09190442 -11.5161091373 9383.60801356 11.5161091373
3224 3223 9374.50053009 -11.4776671092 9386.9781972 11.4776671092
3225 3224 9377.90931089 -11.4278222238 9390.33713312 11.4278222238
3226 3225 9381.31824678 -11.3659205816 9393.68416736 11.3659205816
3227 3226 9384.72733771 -11.2913345635 9397.01867227 11.2913345635
3228 3227 9388.13658363 -11.2034663606 9400.34004999 11.2034663606
3229 3228 9391.54598449 -11.1017514015 9403.6477359 11.1017514015
3230 3229 9394.95554025 -10.9856616604 9406.94120191 10.9856616604
3231 3230 9398.36525085 -10.8547088296 9410.21995968 10.8547088296
3232 3231 9401.77511626 -10.7084473394 9413.4835636 10.7084473394
3233 3232 9405.18513641 -10.5464772117 9416.73161362 10.5464772117
3234 3233 9408.59531127 -10.3684467315 9419.963758 10.3684467315
3235 3234 9412.00564078 -10.1740549228 9423.1796957 10.1740549228
3236 3235 9415.4161249 -9.96305381636 9426.37917871 9.96305381636
3237 3236 9418.82676358 -9.73525049786 9429.56201407 9.73525049786
3238 3237 9422.23755677 -9.49050892407 9432.72806569 9.49050892407
3239 3238 9425.64850442 -9.22875149897 9435.87725592 9.22875149897
3240 3239 9429.05960649 -8.94996040005 9439.00956689 8.94996040005
3241 3240 9432.47086293 -8.65417864771 9442.12504158 8.65417864771
3242 3241 9435.88227369 -8.34151091123 9445.2237846 8.34151091123
3243 3242 9439.29383872 -8.01212404651 9448.30596277 8.01212404651
3244 3243 9442.70555798 -7.66624736138 9451.37180535 7.66624736138
3245 3244 9446.11743142 -7.30417260634 9454.42160403 7.30417260634
3246 3245 9449.52945899 -6.92625368914 9457.45571268 6.92625368914
3247 3246 9452.94164064 -6.53290611356 9460.47454676 6.53290611356
3248 3247 9456.35397633 -6.12460614345 9463.47858247 6.12460614345
3249 3248 9459.766466 -5.70188969506 9466.4683557 5.70188969506
3250 3249 9463.17910962 -5.26535096126 9469.44446058 5.26535096126
3251 3250 9466.59190713 -4.81564077313 9472.4075479 4.81564077313
3252 3251 9470.00485849 -4.35346470532 9475.35832319 4.35346470532
3253 3252 9473.41796364 -3.87958093286 9478.29754457 3.87958093286
3254 3253 9476.83122255 -3.3947978483 9481.2260204 3.3947978483
3255 3254 9480.24463516 -2.89997144931 9484.14460661 2.89997144931
3256 3255 9483.65820143 -2.39600250772 9487.05420393 2.39600250772
3257 3256 9487.0719213 -1.88383353228 9489.95575484 1.88383353228
3258 3257 9490.48579474 -1.36444553821 9492.85024028 1.36444553821
3259 3258 9493.8998217 -0.838854637706 9495.73867634 0.838854637706
3260 3259 9497.31400212 -0.308108466262 9498.62211059 0.308108466262
3261 3260 9500.72833597 0.226717539444 9501.50161843 0.226717539444
3262 3261 9504.14282319 0.764523995654 9504.37829919 0.764523995654
3263 3262 9507.55746374 1.30419154058 9507.25327219 1.30419154058
3264 3263 9510.97225756 1.84458490078 9510.12767266 1.84458490078
3265 3264 9514.38720462 2.38455703675 9513.00264759 2.38455703675
3266 3265 9517.80230487 2.9229533493 9515.87935152 2.9229533493
3267 3266 9521.21755826 3.45861592795 9518.75894233 3.45861592795
3268 3267 9524.63296473 3.99038782233 9521.64257691 3.99038782233
3269 3268 9528.04852426 4.51711731764 9524.53140694 4.51711731764
3270 3269 9531.46423678 5.03766219485 9527.42657459 5.03766219485
3271 3270 9534.88010225 5.55089395691 9530.3292083 5.55089395691
3272 3271 9538.29612063 6.05570200179 9533.24041863 6.05570200179
3273 3272 9541.71229187 6.55099772397 9536.16129415 6.55099772397
3274 3273 9545.12861592 7.03571852603 9539.0928974 7.03571852603
3275 3274 9548.54509274 7.50883172239 9542.03626102 7.50883172239
3276 3275 9551.96172227 7.96933831803 9544.99238395 7.96933831803
3277 3276 9555.37850448 8.41627664533 9547.96222783 8.41627664533
3278 3277 9558.79543931 8.84872584301 9550.94671346 8.84872584301
3279 3278 9562.21252672 9.26580916177 9553.94671755 9.26580916177
3280 3279 9565.62976666 9.6666970823 9556.96306958 9.6666970823
3281 3280 9569.04715908 10.0506102319 9559.99654885 10.0506102319
3282 3281 9572.46470395 10.4168220869 9563.04788186 10.4168220869
3283 3282 9575.88240121 10.7646614501 9566.11773976 10.7646614501
3284 3283 9579.30025081 11.093514691 9569.20673612 11.093514691
3285 3284 9582.71825272 11.4028277414 9572.31542497 11.4028277414
3286 3285 9586.13640687 11.6921078366 9575.44429904 11.6921078366
3287 3286 9589.55471324 11.9609249952 9578.59378824 11.9609249952
3288 3287 9592.97317176 12.208913233 9581.76425853 12.208913233
3289 3288 9596.3917824 12.4357715048 9584.9560109 12.4357715048
3290 3289 9599.81054511 12.6412643713 9588.16928074 12.6412643713
3291 3290 9603.22945984 12.8252223899 9591.40423745 12.8252223899
3292 3291 9606.64852654 12.9875422274 9594.66098432 12.9875422274
3293 3292 9610.06774518 13.1281864959 9597.93955868 13.1281864959
3294 3293 9613.4871157 13.2471833142 9601.23993238 13.2471833142
3295 3294 9616.90663805 13.3446255964 9604.56201246 13.3446255964
3296 3295 9620.3263122 13.4206700739 9607.90564212 13.4206700739
3297 3296 9623.74613809 13.4755360557 9611.27060203 13.4755360557
3298 3297 9627.16611568 13.5095039328 9614.65661175 13.5095039328
3299 3298 9630.58624492 13.5229134371 9618.06333149 13.5229134371
3300 3299 9634.00652577 13.5161616617 9621.49036411 13.5161616617
3301 3300 9637.42695819 13.4897008551 9624.93725733 13.4897008551
3302 3301 9640.84754211 13.4440359977 9628.40350611 13.4440359977
3303 3302 9644.26827751 13.3797221764 9631.88855533 13.3797221764
3304 3303 9647.68916433 13.2973617679 9635.39180256 13.2973617679
3305 3304 9651.11020252 13.1976014455 9638.91260108 13.1976014455
3306 3305 9654.53139205 13.0811290248 9642.45026303 13.0811290248
3307 3306 9657.95273287 12.9486701634 9646.0040627 12.9486701634
3308 3307 9661.37422492 12.800984931 9649.57323999 12.800984931
3309 3308 9664.79586817 12.6388642659 9653.15700391 12.6388642659
3310 3309 9668.21766257 12.4631263361 9656.75453623 12.4631263361
3311 3310 9671.63960807 12.2746128228 9660.36499525 12.2746128228
3312 3311 9675.06170463 12.0741851421 9663.98751949 12.0741851421
3313 3312 9678.4839522 11.862720626 9667.62123157 11.862720626
3314 3313 9681.90635074 11.641108678 9671.26524206 11.641108678
3315 3314 9685.32890019 11.410246924 9674.91865327 11.410246924
3316 3315 9688.75160052 11.1710373747 9678.58056315 11.1710373747
3317 3316 9692.17445169 10.9243826188 9682.25006907 10.9243826188
3318 3317 9695.59745363 10.671182064 9685.92627157 10.671182064
3319 3318 9699.02060632 10.4123282438 9689.60827807 10.4123282438
3320 3319 9702.44390969 10.1487032067 9693.29520649 10.1487032067
3321 3320 9705.86736372 9.88117500457 9696.98618871 9.88117500457
3322 3321 9709.29096835 9.61059429638 9700.68037405 9.61059429638
3323 3322 9712.71472353 9.33779108171 9704.37693245 9.33779108171
3324 3323 9716.13862923 9.06357157993 9708.07505765 9.06357157993
3325 3324 9719.56268539 8.78871526776 9711.77397012 8.78871526776
3326 3325 9722.98689197 8.51397208876 9715.47291989 8.51397208876
3327 3326 9726.41124893 8.24005984654 9719.17118909 8.24005984654
3328 3327 9729.83575622 7.96766179278 9722.86809443 7.96766179278
3329 3328 9733.2604138 7.69742442009 9726.56298938 7.69742442009
3330 3329 9736.68522162 7.42995546864 9730.25526615 7.42995546864
3331 3330 9740.11017963 7.16582215442 9733.94435748 7.16582215442
3332 3331 9743.53528779 6.90554962577 9737.62973817 6.90554962577
3333 3332 9746.96054606 6.64961965364 9741.31092641 6.64961965364
3334 3333 9750.38595439 6.39846956008 9744.98748483 6.39846956008
3335 3334 9753.81151273 6.15249138769 9748.65902134 6.15249138769
3336 3335 9757.23722104 5.91203131228 9752.32518973 5.91203131228
3337 3336 9760.66307928 5.67738929893 9755.98568998 5.67738929893
3338 3337 9764.08908739 5.44881900126 9759.64026839 5.44881900126
3339 3338 9767.51524535 5.22652790164 9763.28871745 5.22652790164
3340 3339 9770.94155309 5.01067768959 9766.9308754 5.01067768959
3341 3340 9774.36801058 4.80138487395 9770.5666257 4.80138487395
3342 3341 9777.79461777 4.59872162343 9774.19589614 4.59872162343
3343 3342 9781.22137461 4.402716829 9777.81865778 4.402716829
3344 3343 9784.64828107 4.21335738038 9781.43492369 4.21335738038
3345 3344 9788.07533709 4.03058964806 9785.04474744 4.03058964806
3346 3345 9791.50254263 3.85432116088 9788.64822147 3.85432116088
3347 3346 9794.92989765 3.6844224688 9792.24547518 3.6844224688
3348 3347 9798.3574021 3.52072917894 9795.83667293 3.52072917894
3349 3348 9801.78505594 3.36304415277 9799.42201179 3.36304415277
3350 3349 9805.21285913 3.21113985104 9803.00171928 3.21113985104
3351 3350 9808.64081161 3.06476081269 9806.5760508 3.06476081269
3352 3351 9812.06891334 2.92362625317 9810.14528709 2.92362625317
3353 3352 9815.49716429 2.78743276708 9813.70973152 2.78743276708
3354 3353 9818.9255644 2.65585711976 9817.26970728 2.65585711976
3355 3354 9822.35411362 2.52855911157 9820.82555451 2.52855911157
3356 3355 9825.78281193 2.40518449905 9824.37762743 2.40518449905
3357 3356 9829.21165927 2.28536795609 9827.92629131 2.28536795609
3358 3357 9832.64065559 2.16873605889 9831.47191953 2.16873605889
3359 3358 9836.06980085 2.05491027778 9835.01489058 2.05491027778
3360 3359 9839.49909502 1.94350995944 9838.55558506 1.94350995944
3361 3360 9842.92853803 1.83415528305 9842.09438275 1.83415528305
3362 3361 9846.35812986 1.72647017401 9845.63165969 1.72647017401
3363 3362 9849.78787045 1.6200851593 9849.16778529 1.6200851593
3364 3363 9853.21775977 1.51464014885 9852.70311962 1.51464014885
3365 3364 9856.64779776 1.40978712781 9856.23801063 1.40978712781
3366 3365 9860.07798438 1.305192745 9859.77279163 1.305192745
3367 3366 9863.50831959 1.2005407836 9863.30777881 1.2005407836
3368 3367 9866.93880334 1.09553450073 9866.84326884 1.09553450073
3369 3368 9870.3694356 0.989898823268 9870.37953678 0.989898823268
3370 3369 9873.80021631 0.883382388184 9873.91683392 0.883382388184
3371 3370 9877.23114543 0.775759416474 9877.45538602 0.775759416474
3372 3371 9880.66222293 0.666831410651 9880.99539151 0.666831410651
3373 3372 9884.09344874 0.556428666848 9884.53702007 0.556428666848
3374 3373 9887.52482284 0.44441159351 9888.08041124 0.44441159351
3375 3374 9890.95634517 0.330671829768 9891.62567334 0.330671829768
3376 3375 9894.38801569 0.215133157656 9895.17288253 0.215133157656
3377 3376 9897.81983436 0.097752203493 9898.72208216 0.097752203493
3378 3377 9901.25180114 -0.0214810751355 9902.27328221 0.0214810751355
3379 3378 9904.68391597 -0.14254311917 9905.82645909 0.14254311917
3380 3379 9908.11617883 -0.265376715836 9909.38155554 0.265376715836
3381 3380 9911.54858965 -0.389891164397 9912.93848082 0.389891164397
3382 3381 9914.9811484 -0.515962658726 9916.49711106 0.515962658726
3383 3382 9918.41385504 -0.643434884349 9920.05728993 0.643434884349
3384 3383 9921.84670953 -0.772119826458 9923.61882935 0.772119826458
3385 3384 9925.2797118 -0.901798784238 9927.18151059 0.901798784238
3386 3385 9928.71286184 -1.03222358573 9930.74508542 1.03222358573
3387 3386 9932.14615958 -1.16311799638 9934.30927758 1.16311799638
3388 3387 9935.57960499 -1.29417931334 9937.8737843 1.29417931334
3389 3388 9939.01319803 -1.42508013659 9941.43827816 1.42508013659
3390 3389 9942.44693864 -1.55547030708 9945.00240895 1.55547030708
3391 3390 9945.88082679 -1.68497900088 9948.56580579 1.68497900088
3392 3391 9949.31486243 -1.81321696796 9952.1280794 1.81321696796
3393 3392 9952.74904552 -1.9397789029 9955.68882442 1.9397789029
3394 3393 9956.18337602 -2.06424593451 9959.24762195 2.06424593451
3395 3394 9959.61785388 -2.18618822036 9962.8040421 2.18618822036
3396 3395 9963.05247906 -2.30516763203 9966.35764669 2.30516763203
3397 3396 9966.48725151 -2.42074051586 9969.90799202 2.42074051586
3398 3397 9969.92217119 -2.53246051398 9973.45463171 2.53246051398
3399 3398 9973.35723807 -2.63988142991 9976.9971195 2.63988142991
3400 3399 9976.79245209 -2.7425601226 9980.53501221 2.7425601226
3401 3400 9980.22781321 -2.84005941282 9984.06787262 2.84005941282
3402 3401 9983.66332139 -2.93195098553 9987.59527237 2.93195098553
3403 3402 9987.09897659 -3.01781827201 9991.11679486 3.01781827201
3404 3403 9990.53477875 -3.09725929537 9994.63203805 3.09725929537
3405 3404 9993.97072785 -3.16988946345 9998.14061731 3.16988946345
3406 3405 9997.40682383 -3.2353442932 10001.6421681 3.2353442932
3407 3406 10000.8430667 -3.29328205095 10005.1363487 3.29328205095
3408 3407 10004.2794563 -3.3433862936 10008.6228426 3.3433862936
3409 3408 10007.7159927 -3.38536829584 10012.101361 3.38536829584
3410 3409 10011.1526758 -3.41896934944 10015.5716451 3.41896934944
3411 3410 10014.5895055 -3.44396292117 10019.0334685 3.44396292117
3412 3411 10018.0264819 -3.46015665646 10022.4866386 3.46015665646
3413 3412 10021.4636049 -3.46739421689 10025.9309991 3.46739421689
3414 3413 10024.9008744 -3.46555694041 10029.3664314 3.46555694041
3415 3414 10028.3382904 -3.45456531387 10032.7928558 3.45456531387
3416 3415 10031.7758529 -3.4343802487 10036.2102332 3.4343802487
3417 3416 10035.2135618 -3.40500415139 10039.618566 3.40500415139
3418 3417 10038.6514171 -3.36648178146 10043.0178989 3.36648178146
3419 3418 10042.0894187 -3.31890089088 10046.4083195 3.31890089088
3420 3419 10045.5275665 -3.26239263968 10049.7899592 3.26239263968
3421 3420 10048.9658606 -3.19713178407 10053.1629924 3.19713178407
3422 3421 10052.4043009 -3.12333663427 10056.5276376 3.12333663427
3423 3422 10055.8428874 -3.04126878038 10059.8841562 3.04126878038
3424 3423 10059.28162 -2.95123258622 10063.2328526 2.95123258622
3425 3424 10062.7204986 -2.8535744518 10066.5740731 2.8535744518
3426 3425 10066.1595233 -2.74868184656 10069.9082052 2.74868184656
3427 3426 10069.598694 -2.63698211676 10073.2356761 2.63698211676
3428 3427 10073.0380106 -2.51894107135 10076.5569517 2.51894107135
3429 3428 10076.4774731 -2.39506135199 10079.8725344 2.39506135199
3430 3429 10079.9170815 -2.26588059406 10083.1829621 2.26588059406
3431 3430 10083.3568356 -2.13196938647 10086.488805 2.13196938647
3432 3431 10086.7967356 -1.99392903923 10089.7906646 1.99392903923
3433 3432 10090.2367813 -1.85238916879 10093.0891704 1.85238916879
3434 3433 10093.6769726 -1.70800511211 10096.3849778 1.70800511211
3435 3434 10097.1173097 -1.5614551813 10099.6787648 1.5614551813
3436 3435 10100.5577923 -1.41343777171 10102.97123 1.41343777171
3437 3436 10103.9984205 -1.26466833685 10106.2630888 1.26466833685
3438 3437 10107.4391942 -1.11587624471 10109.5550704 1.11587624471
3439 3438 10110.8801133 -0.967801530229 10112.8479149 0.967801530229
3440 3439 10114.3211779 -0.821191559624 10116.1423695 0.821191559624
3441 3440 10117.7623879 -0.676797622675 10119.4391855 0.676797622675
3442 3441 10121.2037433 -0.535371469482 10122.7391147 0.535371469482
3443 3442 10124.6452439 -0.397661808627 10126.0429057 0.397661808627
3444 3443 10128.0868898 -0.26441078391 10129.3513006 0.26441078391
3445 3444 10131.528681 -0.136350447038 10132.6650314 0.136350447038
3446 3445 10134.9706173 -0.014199243746 10135.9848165 0.014199243746
3447 3446 10138.4126988 0.101341469169 10139.3113573 0.101341469169
3448 3447 10141.8549253 0.209590858472 10142.6453344 0.209590858472
3449 3448 10145.2972969 0.309891983515 10145.9874049 0.309891983515
3450 3449 10148.7398135 0.401615082654 10149.3381984 0.401615082654
3451 3450 10152.1824751 0.484160760381 10152.6983144 0.484160760381
3452 3451 10155.6252816 0.556963058888 10156.0683186 0.556963058888
3453 3452 10159.068233 0.619492398331 10159.4487406 0.619492398331
3454 3453 10162.5113293 0.671258370583 10162.8400709 0.671258370583
3455 3454 10165.9545703 0.711812371956 10166.2427579 0.711812371956
3456 3455 10169.3979561 0.740750061104 10169.6572061 0.740750061104
3457 3456 10172.8414866 0.757713629101 10173.083773 0.757713629101
3458 3457 10176.2851618 0.762393869573 10176.522768 0.762393869573
3459 3458 10179.7289817 0.754532037688 10179.9744496 0.754532037688
3460 3459 10183.1729461 0.733921487797 10183.4390246 0.733921487797
3461 3460 10186.6170551 0.700409080567 10186.916646 0.700409080567
3462 3461 10190.0613086 0.653896351532 10190.4074122 0.653896351532
3463 3462 10193.5057065 0.594340434116 10193.9113661 0.594340434116
3464 3463 10196.9502489 0.52175473138 10197.4284942 0.52175473138
3465 3464 10200.3949356 0.436209331908 10200.9587263 0.436209331908
3466 3465 10203.8397668 0.337831166511 10204.5019356 0.337831166511
3467 3466 10207.2847422 0.226803903658 10208.0579382 0.226803903658
3468 3467 10210.7298618 0.103367582801 10211.6264942 0.103367582801
3469 3468 10214.1751257 -0.03218201395 10215.2073077 0.03218201395
3470 3469 10217.6205337 -0.179494250096 10218.800028 0.179494250096
3471 3470 10221.0660859 -0.338164779987 10222.4042507 0.338164779987
3472 3471 10224.5117822 -0.507736946787 10226.0195192 0.507736946787
3473 3472 10227.9576225 -0.687703427717 10229.645326 0.687703427717
3474 3473 10231.4036069 -0.877508119873 10233.281115 0.877508119873
3475 3474 10234.8497352 -1.07654825879 10236.9262834 1.07654825879
3476 3475 10238.2960074 -1.2841767607 10240.5801842 1.2841767607
3477 3476 10241.7424235 -1.49970477848 10244.2421283 1.49970477848
3478 3477 10245.1889835 -1.72240445991 10247.911388 1.72240445991
3479 3478 10248.6356873 -1.95151189637 10251.5871992 1.95151189637
3480 3479 10252.0825348 -2.18623024857 10255.268765 2.18623024857
3481 3480 10255.529526 -2.42573303547 10258.9552591 2.42573303547
3482 3481 10258.9766609 -2.66916757157 10262.6458285 2.66916757157
3483 3482 10262.4239395 -2.91565853683 10266.339598 2.91565853683
3484 3483 10265.8713617 -3.16431166327 10270.0356733 3.16431166327
3485 3484 10269.3189274 -3.41421752104 10273.7331449 3.41421752104
3486 3485 10272.7666366 -3.66445538696 10277.431092 3.66445538696
3487 3486 10276.2144893 -3.91409717742 10281.1285865 3.91409717742
3488 3487 10279.6624854 -4.16221142777 10284.8246968 4.16221142777
3489 3488 10283.1106249 -4.40786729961 10288.5184922 4.40786729961
3490 3489 10286.5589078 -4.65013859751 10292.2090464 4.65013859751
3491 3490 10290.0073339 -4.88810777649 10295.8954417 4.88810777649
3492 3491 10293.4559034 -5.12086992156 10299.5767733 5.12086992156
3493 3492 10296.904616 -5.34753668097 10303.2521527 5.34753668097
3494 3493 10300.3534719 -5.56724013453 10306.920712 5.56724013453
3495 3494 10303.8024709 -5.77913657922 10310.5816075 5.77913657922
3496 3495 10307.251613 -5.98241021419 10314.2340232 5.98241021419
3497 3496 10310.7008981 -6.17627670799 10317.8771748 6.17627670799
3498 3497 10314.1503263 -6.35998663133 10321.5103129 6.35998663133
3499 3498 10317.5998975 -6.53282873914 10325.1327262 6.53282873914
3500 3499 10321.0496116 -6.69413308678 10328.7437446 6.69413308678
3501 3500 10324.4994685 -6.84327396552 10332.3427425 6.84327396552

E-021-sinf-sf-curve.json — 1.2 KB, updated 08-19-2026

JSON sidecar (click to expand)
{
  "experiment": "E-021",
  "task": "3.7: exact S_inf(n) + |S_f(n)| curve + D-036 constants",
  "script": "research/numerics/scripts/E-021-sinf-sf-curve.py",
  "parameters": {
    "n_max": 5000,
    "t_zeros": 5000.0
  },
  "checks": {
    "V1_lambda_vs_E015": true,
    "V2_R_bound_holds": true,
    "V3_Sinf_residual_bounded": true
  },
  "key_values": {
    "A_use": 0.9,
    "B0_use": 1.0,
    "R_max_sample": 4.7507714994958565,
    "C0_samples": {
      "1e2": 6.234438640727731,
      "1e4": 8.840233256550178,
      "1e6": 11.194201354663145
    },
    "eta_0": "-0.5772156649015328606065120900824024310",
    "Sinf_residual_fits": [
      [
        1000,
        -0.2500416666625
      ],
      [
        2000,
        -0.2500208333328125
      ],
      [
        3000,
        -0.25001388888873455
      ],
      [
        4000,
        -0.25001041666660156
      ],
      [
        5000,
        -0.2500083333333
      ]
    ],
    "V1_worst_rel": 4.79820218420929e-25,
    "S_f_max_abs": "13.5229134371",
    "S_f_max_abs_n": 3298
  },
  "elapsed_seconds": 2139.3,
  "timestamp_utc": "2026-08-19T06:48:55.463113+00:00"
}

Source code

Python script (click to expand)
"""E-021 — task 3.7: exact S_inf(n) to n=1e4, |S_f(n)| curve, tightened
D-036 constants. Feeds D-037 (finite-height Li theorem).

Components:
  P1. D-036 constants: C0(t) from Trudgian; |R(s)| = |zeta'/zeta(s) -
      sum_{|gamma-t|<1} 1/(s-rho)| sampled at ~30 contour points (flint
      acb zeta + fd derivative, zeros via mp.zetazero) -> fit A, B0.
  P2. eta_j — ALL FLINT (session 006 cont.10 root-cause: mpmath zeta,
      Hurwitz included, silently loses accuracy beyond ~58 digits on
      this stack [mpmath 1.3 + Py 3.14] -> eta_j errors ~1e-58 ->
      S_f binomial cancellation explodes ~(4/3)^n; V1 failed 1.4e143.
      The zero-side sigma route also has eta_0 wrong by 2.4e-4 from
      sigma_1 truncation at T=5000 — both defects removed here).
      j <= 23: Stieltjes series division (E-011 machinery, validated):
        -zeta'/zeta(1+u) = (1/u) N(u)/D(u), eta_k = [u^{k+1}] N/D.
      j >= 24: Lagarias (4.10) with flint arb zeta:
        eta_j = (-1)^{j+1} [(1-2^{-(j+1)}) zeta(j+1) - 1 + sigma_{j+1}]
        with sigma_m = (-1)^{m-1}(tau_{m-1} - eta_{m-1}) + 1 EXACT
        (arithmetic side) for m <= 24, and sigma_m = 2 Re sum
        rho^{-m} over the first 100 zeros (mp.zetazero, dps 100)
        for 25 <= m <= M_SIG; omitted beyond (boundary error
        C(n,M_SIG)*14^{-M_SIG} < 1e-40 by construction).
      NOTES (hard-won, session 006 cont.10):
      * sigma_m may NOT be omitted at any m <= M_SIG — the truncation
        boundary error ~ C(n,M)*14^{-M} PEAKS at M = n/15 with size
        ~(15/14)^n: with M=200, S_f exploded as 1e133 at n=5000
        (measured). M_SIG ~ 0.22*n_max.
      * the m=24 omission alone moved S_f(200) by ~0.4 (measured).
      * float64 zeros for sigma_m are NOT enough either (S_f(300) off
        by 7.8e-8 — measured); need mp.zetazero precision. Zeros
        k > 100 contribute < (14.13/236.5)^25 ~ 1e-31 relative for
        m >= 25, so the first 100 at dps 100 are effectively exact.
      * GAMMA_E must be a string (bare float -> 53-bit, 4.94e-21).
  P3. S_inf(n) EXACT for n <= N_MAX (Lagarias (4.11)):
        S_inf(n) = sum_{j=1}^n (-1)^j C(n,j) (1-2^{-j}) zeta*(j),
        zeta*(1) = log(4pi)+gamma, zeta*(j) = zeta(j) (flint.arb).
      Cancellation ~2^n -> dps = ceil(0.31*n) + 60.
  P4. S_f(n) = sum_{j=1}^n C(n,j) eta_{j-1} (plain binomial — the
      E-011/Lagarias-(4.13) convention after the (-1) absorbed into
      the series-eta definition; VALIDATED: S_f(200) = -2.14037668
      matches S_inf(200)+1-lambda_200(E-015)); lambda_n =
      S_inf - S_f + 1.
  P5. VALIDATION: lambda_n (n <= 3000) vs E-015 certified CSV (rel dev);
      eta_0 vs E-011 value; S_inf fit: S_inf - [(1/2)n log n + C1 n]
      -> c0 (+ c1/n...), C1 = (gamma-1-log(2pi))/2.

Checks:
  V1. lambda_n matches E-015 for n <= 3000 (rel dev < 1e-50 at dps used).
  V2. |R(s)| <= A log(t+2) + B0 at all sample points with the FITTED
      A, B0 (and fitted values reported vs D-036's 2.0/2.0).
  V3. S_inf fit residual -> constant c0 (|residual - c0| -> 0 trend).

Outputs: research/numerics/data/E-021-sinf-sf-curve.csv (+ .json)
"""
import json
import sys
import time
from datetime import datetime, timezone
from pathlib import Path

import flint
import mpmath as mp
import numpy as np

REPO = Path(__file__).resolve().parents[3]
DATA = REPO / "research" / "numerics" / "data"
CSV = DATA / "E-021-sinf-sf-curve.csv"
JSON = DATA / "E-021-sinf-sf-curve.json"
E015 = DATA / "E-015-li-coefficients-n3000.csv"

N_MAX = 5000            # 10000 costs ~2h (row cost ~ n^2 * dps);
                        # cached zeta/zeros make a later 1e4 rerun cheap
T_ZEROS = 5000.0        # zeros up to this height for sigma sums
N_ZMAX = 8000           # mp.zetazero count cap (N(5e3) ~ 7.9e3)
DPS_BIG = 3300
# NOTE: must be a STRING — a bare float literal collapses to 53-bit
# (measured error 4.94e-21 -> sigma_1/zeta*(1) wrong at digit 21).
GAMMA_E = "0.57721566490153286060651209008240243104215933593992337"


# ---------------------------------------------------------------- N(T)
def N_count(T):
    F = (T / (2 * np.pi)) * np.log(T / (2 * np.pi)) - T / (2 * np.pi) + 7 / 8
    return F


def S_bound(T):
    return 0.137 * np.log(T) + 0.443 * np.log(np.log(T)) + 1.588


def C0(t):
    """Upper bound for zeros in [t, t+1] (t >= 10)."""
    return (N_count(t + 1) - N_count(t)) + S_bound(t + 1) + S_bound(t)


# ------------------------------------------------------------- zeros
def compute_zeros():
    cache = DATA / "E-021-zeros-cache.npy"
    n_est = int(N_count(T_ZEROS) + S_bound(T_ZEROS)) + 100
    n_est = min(n_est, N_ZMAX)
    if cache.exists():
        zs = np.load(cache)
        if len(zs) >= n_est:
            print(f"  loaded {n_est} zeros from cache", flush=True)
            return zs[:n_est]
    print(f"  computing {n_est} zeros via mp.zetazero ...", flush=True)
    mp.mp.dps = 30
    zs = []
    for k in range(1, n_est + 1):
        zs.append(mp.zetazero(k).imag)
        if k % 1000 == 0:
            print(f"    {k}/{n_est}", flush=True)
    out = np.array([float(z) for z in zs])
    np.save(cache, out)
    return out


# ------------------------------------------------------- zeta strings
def get_zeta_strings(n_max):
    """zeta(j) decimal strings at full precision (flint arb), cached.
    full_digits = 0.31*n_max + 100 covers the ~2^n cancellation in
    BOTH S_inf and the (1-2^{-s})zeta(s)-1 eta formula (absolute
    error ~1e-1650 uniformly)."""
    full_digits = int(0.31 * n_max) + 100
    zcache = DATA / "E-021-zeta-cache.json"
    if zcache.exists():
        zeta_str = {int(k): v for k, v in
                    json.loads(zcache.read_text()).items()}
        print("  zeta strings loaded from cache", flush=True)
        # patch legacy zeta*(1) (built with double-precision GAMMA_E)
        mp.mp.dps = full_digits + 50
        z1 = mp.nstr(mp.log(4 * mp.pi) + mp.mpf(GAMMA_E), full_digits)
        if zeta_str.get(1) != z1:
            zeta_str[1] = z1
            zcache.write_text(json.dumps(zeta_str))
            print("  patched zeta*(1) in cache (GAMMA_E float fix)",
                  flush=True)
        return zeta_str, full_digits
    flint.ctx.prec = int(full_digits * 3.33) + 200
    mp.mp.dps = full_digits + 50
    zeta_str = {1: mp.nstr(mp.log(4 * mp.pi) + mp.mpf(GAMMA_E),
                           full_digits)}
    for j in range(2, n_max + 1):
        zeta_str[j] = flint.arb(j).zeta().str(full_digits,
                                              radius=False)
        if j % 2000 == 0:
            print(f"    zeta({j}) done", flush=True)
    zcache.write_text(json.dumps(zeta_str))
    return zeta_str, full_digits


# ---------------------------------------------------------------- eta
# K_SPLIT: eta_j for j < K_SPLIT from Stieltjes (exact, arithmetic);
# sigma_m exact for m <= K_SPLIT. Must be ~80: with K_SPLIT=24 the
# zero-tail (k>100) of sigma_25 entered at term j=24 with C(n,24)
# amplification — S_f(3000) was off by 1.06e3 growing ~n^24 (measured).
# With K_SPLIT=80 the zero-tail exposure (m>=81, k>100) is < 3e-11.
K_SPLIT = 80


def compute_eta(zeta_str, full_digits):
    """eta_j for j = 0..N_MAX-1, ALL flint-based (see header P2).
    Returns dict j -> decimal string at full_digits."""
    print(f"  eta_0..{K_SPLIT - 1}: flint Stieltjes + series division "
          "(E-011) ...", flush=True)
    flint.ctx.prec = int((full_digits + 100) * 3.33) + 200
    mp.mp.dps = full_digits + 100   # BEFORE mp.mpf(string) parses below!
    gam_s = [mp.mpf(flint.acb.stieltjes(k).real.str(
        full_digits + 100, radius=False)) for k in range(K_SPLIT + 2)]
    N_ = [mp.mpf(0)] * (K_SPLIT + 2)
    D_ = [mp.mpf(0)] * (K_SPLIT + 2)
    N_[0] = D_[0] = 1
    for m in range(0, K_SPLIT + 1):
        D_[m + 1] = (-1) ** m * gam_s[m] / mp.factorial(m)
    for m in range(1, K_SPLIT + 1):
        N_[m + 1] = -(-1) ** m * gam_s[m] / mp.factorial(m - 1)
    Ev = [mp.mpf(0)] * (K_SPLIT + 2)
    for k in range(0, K_SPLIT + 2):
        s = N_[k]
        for i in range(1, k + 1):
            s -= D_[i] * Ev[k - i]
        Ev[k] = s
    eta_str = {j: mp.nstr(Ev[j + 1], full_digits)
               for j in range(K_SPLIT)}
    print(f"    eta_0 = {mp.nstr(Ev[1], 15)} (should be -gamma)",
          flush=True)
    print(f"    eta_1 = {mp.nstr(Ev[2], 15)}", flush=True)

    # ---- sigma_m: exact (arithmetic) for m <= 24; zeros for 25..200
    print("  sigma_m: m<=24 exact (tau-eta), 25..200 from zeros ...",
          flush=True)
    mp.mp.dps = full_digits + 50
    tau = {0: mp.mpf(-0.5) * (mp.log(4 * mp.pi) + mp.mpf(GAMMA_E))}
    for j in range(1, K_SPLIT):
        z = mp.mpf(zeta_str[j + 1])
        tau[j] = (-1) ** (j + 1) * (1 - mp.mpf(2) ** (-(j + 1))) * z
    sigma = {}
    for m in range(1, K_SPLIT + 1):
        sigma[m] = ((-1) ** (m - 1)
                    * (tau[m - 1] - mp.mpf(eta_str[m - 1])) + 1)
    mp.mp.dps = 60
    sig1_known = 1 + mp.euler / 2 - mp.log(4 * mp.pi) / 2
    print(f"    sigma_1 = {mp.nstr(sigma[1], 20)} "
          f"(closed form {mp.nstr(sig1_known, 20)})", flush=True)
    # sigma_m, m = 25..M_SIG: first 100 zeros via mp.zetazero, dps 100.
    # M_SIG must be adaptive: truncating sigma at M leaves a boundary
    # error ~ C(n,M)*14.13^{-M} which PEAKS at M = n/15 (~(15/14)^n);
    # with M=200 the run exploded as 1e133 at n=5000 (measured). Need
    # C(n,M)*14^{-M} < 1e-40 on the decreasing side (M > n/15).
    # float64 zeros are NOT enough (S_f(300) off 7.8e-8 — measured);
    # zeros k>100 are suppressed by (14.13/236.5)^25 ~ 1e-31 relative.
    n_zeta = max(zeta_str)
    M_SIG = n_zeta
    for M in range(K_SPLIT + 1, n_zeta + 1):
        if M > n_zeta / 15:
            logC = (mp.loggamma(n_zeta + 1) - mp.loggamma(M + 1)
                    - mp.loggamma(n_zeta - M + 1))
            if float(logC - (M - 1) * mp.log(14.13)
                     + mp.log(0.05)) / np.log(10) < -40:
                M_SIG = M
                break
    print(f"    M_SIG = {M_SIG} (C(n,M)*14^{{-M}} < 1e-40)", flush=True)
    # sigma_m precision matters: dps-100 sums left eps_m ~ 14^{-m}e-100,
    # whose C(n,j)-amplified impact (peak term C(n,n/15)*14^{-n/15} ~
    # 1e105 at n=3000) showed up as S_f error ~1e3 (measured). Zeros
    # at 400 digits + sums at full_digits+50 kill it.
    # dps BEFORE any mp.mpf(string) parse! (Third instance of this bug
    # class: g100 parsed at leftover dps 60 corrupted sigma_m at
    # ~m*1e-60*14^{-m} -> S_f(3000) off by 1.7e7, growth ~n^80.)
    mp.mp.dps = full_digits + 50
    z100cache = DATA / "E-021-zeros100-hi-cache.json"
    if z100cache.exists():
        g100 = [mp.mpf(v) for v in
                json.loads(z100cache.read_text())]
    else:
        mp.mp.dps = 450
        g100 = [mp.zetazero(k).imag for k in range(1, 101)]
        z100cache.write_text(json.dumps([mp.nstr(g, 400)
                                         for g in g100]))
        mp.mp.dps = full_digits + 50
    rho = [mp.mpc(mp.mpf("0.5"), g) for g in g100]
    for m in range(K_SPLIT + 1, M_SIG + 1):
        sigma[m] = 2 * mp.re(sum(r ** (-m) for r in rho))
    mp.mp.dps = 60
    print(f"    sigma_2 = {mp.nstr(sigma[2], 20)}", flush=True)
    print(f"    sigma_25 (zeros) = {mp.nstr(sigma[25], 6)}; "
          f"sigma_{M_SIG} = {mp.nstr(sigma[M_SIG], 6)}", flush=True)

    print("  eta_j (j>=24): (-1)^{j+1}[(1-2^{-(j+1)})zeta(j+1) - 1 "
          "+ sigma_{j+1}] ...", flush=True)
    mp.mp.dps = full_digits + 50
    for j in range(K_SPLIT, n_zeta):
        z = mp.mpf(zeta_str[j + 1])
        sig = sigma[j + 1] if j + 1 <= M_SIG else mp.mpf(0)
        eta = (-1) ** (j + 1) * ((1 - mp.mpf(2) ** (-(j + 1))) * z - 1
                                 + sig)
        eta_str[j] = mp.nstr(eta, full_digits)
    # stitch check: eta_{K_SPLIT-1} via Stieltjes vs via full formula
    mp.mp.dps = full_digits + 50
    eta23_formula = ((-1) ** K_SPLIT
                     * ((1 - mp.mpf(2) ** (-K_SPLIT))
                        * mp.mpf(zeta_str[K_SPLIT])
                        - 1 + sigma[K_SPLIT]))
    stitch = abs(eta23_formula - mp.mpf(eta_str[K_SPLIT - 1]))
    mp.mp.dps = 60
    print(f"    stitch |eta_{K_SPLIT - 1} stieltjes - formula| = "
          f"{mp.nstr(stitch, 3)}", flush=True)
    return eta_str


# ----------------------------------------------------------- S_inf, Sf
def compute_S_inf(n_max, zeta_str, full_digits):
    """Exact S_inf(n) via zeta*(j) (flint arb), dps scaled by n.
    Cancellation ~2^n: every zeta(j) stored at FULL string precision
    (the Sigma(-1)^j C(n,j)*1 = 0 piece must cancel exactly)."""
    print("  parsing zeta strings once at full precision ...", flush=True)
    mp.mp.dps = full_digits + 50
    zeta_mpf = {j: mp.mpf(v) for j, v in zeta_str.items()}
    results = {}
    for n in range(1, n_max + 1):
        mp.mp.dps = int(0.31 * n) + 80
        s = mp.mpf(0)
        c = mp.mpf(1)
        for j in range(1, n + 1):
            c = c * (n - j + 1) / j          # C(n,j) by recurrence
            s += ((-1) ** j) * c * (1 - mp.mpf(2) ** (-j)) * zeta_mpf[j]
        results[n] = +s
        if n % 500 == 0:
            print(f"    S_inf row {n}/{n_max}", flush=True)
    return results


def compute_Sf(n_max, eta_str):
    """S_f(n) = sum_j C(n,j) eta_{j-1} — plain binomial (E-011/Lagarias
    (4.13) convention with series-eta; validated at n=200 vs E-015:
    S_f(200) = -2.14037668 = S_inf(200)+1-lambda_200). Requires eta_j
    absolute accuracy ~1e-1650 at n=5000 (terms C(n,j)*eta up to
    ~1e312 cancel to O(1)) — flint-only computation, see P2."""
    full_digits = int(0.31 * n_max) + 100
    mp.mp.dps = full_digits + 50
    eta_mpf = {j: mp.mpf(v) for j, v in eta_str.items()}
    results = {}
    for n in range(1, n_max + 1):
        mp.mp.dps = int(0.31 * n) + 80
        s = mp.mpf(0)
        c = mp.mpf(1)
        for j in range(1, n + 1):
            c = c * (n - j + 1) / j
            s += c * eta_mpf[j - 1]
        results[n] = +s
        if n % 500 == 0:
            print(f"    S_f row {n}/{n_max}", flush=True)
    return results


def main() -> int:
    if CSV.exists() and "--force" not in sys.argv:
        print(f"cached: {CSV} (use --force to recompute)")
        return 0
    t0 = time.time()

    # ---- P1: constants
    print("P1: D-036 constants ...", flush=True)
    print(f"  C0(100) = {C0(100):.3f}, C0(1e4) = {C0(1e4):.3f}, "
          f"C0(1e6) = {C0(1e6):.3f}", flush=True)
    gam_sample = compute_zeros()

    def xi_mp(s):
        return 0.5 * s * (s - 1) * mp.pi ** (-s / 2) * mp.gamma(s / 2) \
            * mp.zeta(s)

    def zeta_logder(s):
        """zeta'/zeta via xi'/xi minus explicit terms (mpmath dps 30;
        complex-zeta OK to ~1e-10 per E-018 C2)."""
        sm = mp.mpc(s.real, s.imag)
        xi_log = mp.diff(xi_mp, sm) / xi_mp(sm)
        return complex(xi_log - 1 / sm - 1 / (sm - 1)
                       + mp.mpf(0.5) * mp.log(mp.pi)
                       - mp.mpf(0.5) * mp.digamma(sm / 2))

    R_samples = []
    mp.mp.dps = 30
    for sig in (-2.5, 0.5, 3.0):
        for t in (10.0, 50.0, 100.0, 500.0, 1000.0):
            s = complex(sig, t)
            near = [g for g in gam_sample if abs(g - t) < 1.0]
            psum = sum(1.0 / (s - complex(0.5, g)) for g in near)
            R_samples.append((sig, t, abs(zeta_logder(s) - psum)))
    # fit |R| <= A log(t+2) + B0
    A_fit = max(v / np.log(t + 2) for _, t, v in R_samples)
    A_use = max(0.5, float(np.ceil(A_fit * 1.2 * 10) / 10))
    B0_need = max(v - A_use * np.log(t + 2) for _, t, v in R_samples)
    B0_use = max(1.0, float(np.ceil(B0_need * 1.3 * 10) / 10))
    print(f"  |R| max sample = {max(v for *_ , v in R_samples):.2f}; "
          f"A_use={A_use}, B0_use={B0_use}", flush=True)

    # ---- P2: zeta strings + eta (all flint)
    print("P2: zeta strings + eta_j (flint) ...", flush=True)
    zeta_str, full_digits = get_zeta_strings(N_MAX)
    eta_str = compute_eta(zeta_str, full_digits)

    # ---- P3/P4: S_inf, S_f
    print("P3: S_inf exact ...", flush=True)
    S_inf = compute_S_inf(N_MAX, zeta_str, full_digits)
    print("P4: S_f ...", flush=True)
    S_f = compute_Sf(N_MAX, eta_str)

    # ---- P5: validation + fit
    print("P5: validation vs E-015 ...", flush=True)
    e015 = {}
    with E015.open() as f:
        header = f.readline()
        for line in f:
            parts = line.strip().split(",")
            if len(parts) >= 2 and parts[0].isdigit():
                e015[int(parts[0])] = mp.mpf(parts[1])
    worst = 0.0
    mp.mp.dps = 100
    for n in sorted(e015):
        lam = S_inf[n] - S_f[n] + 1
        dev = abs(lam - e015[n]) / abs(e015[n])
        worst = max(worst, float(dev))
    print(f"  V1 worst rel dev vs E-015 (n<=3000): {worst:.2e}", flush=True)

    C1 = (mp.mpf(GAMMA_E) - 1 - mp.log(2 * mp.pi)) / 2
    fits = []
    for n in (1000, 2000, 3000, 4000, 5000, 6000, 8000, 10000):
        if n > N_MAX:
            continue
        mp.mp.dps = 100
        resid = S_inf[n] - (mp.mpf(n) / 2) * mp.log(n) - C1 * n
        fits.append((n, float(resid)))
    print(f"  S_inf residual (should -> c0): {fits}", flush=True)

    # ---- write CSV
    with CSV.open("w", encoding="utf-8", newline="") as f:
        f.write("n,S_inf,S_f,lambda_n,abs_Sf\n")
        for n in range(1, N_MAX + 1):
            lam = S_inf[n] - S_f[n] + 1
            f.write(f"{n},{mp.nstr(S_inf[n],12)},{mp.nstr(S_f[n],12)},"
                    f"{mp.nstr(lam,12)},{mp.nstr(abs(S_f[n]),12)}\n")

    checks = {
        # V1 floor is ~1e-24 (E-015 CSV holds 26 digits); 1e-15 still
        # kills any macroscopic (convention/precision) bug — the bugs
        # found in cont.10 produced 1e-8..1e143 deviations.
        "V1_lambda_vs_E015": bool(worst < 1e-15),
        "V2_R_bound_holds": bool(all(
            v <= A_use * np.log(t + 2) + B0_use for _, t, v in R_samples)),
        "V3_Sinf_residual_bounded": bool(
            abs(fits[-1][1] - fits[-2][1]) < abs(fits[0][1] - fits[1][1])),
    }
    meta = {
        "experiment": "E-021",
        "task": "3.7: exact S_inf(n) + |S_f(n)| curve + D-036 constants",
        "script": "research/numerics/scripts/E-021-sinf-sf-curve.py",
        "parameters": {"n_max": N_MAX, "t_zeros": T_ZEROS},
        "checks": checks,
        "key_values": {
            "A_use": A_use, "B0_use": B0_use,
            "R_max_sample": max(v for *_, v in R_samples),
            "C0_samples": {"1e2": C0(100), "1e4": C0(1e4), "1e6": C0(1e6)},
            "eta_0": eta_str[0][:40],
            "Sinf_residual_fits": fits,
            "V1_worst_rel": worst,
            "S_f_max_abs": mp.nstr(max(abs(S_f[n]) for n in S_f), 12),
            "S_f_max_abs_n": int(max(S_f, key=lambda k: abs(S_f[k]))),
        },
        "elapsed_seconds": round(time.time() - t0, 1),
        "timestamp_utc": datetime.now(timezone.utc).isoformat(),
    }
    JSON.write_text(json.dumps(meta, indent=2), encoding="utf-8")
    ok = all(checks.values())
    print(f"wrote {CSV.name}, {JSON.name} — "
          f"{'ALL CHECKS PASS' if ok else 'CHECK FAILURE: ' + str(checks)}")
    return 0 if ok else 1


if __name__ == "__main__":
    raise SystemExit(main())